DavBfr / dart_barcode

Barcode generation library
https://pub.dev/packages/barcode
Apache License 2.0
132 stars 41 forks source link

drawBarcode y doesn't work #10

Closed sgehrman closed 4 years ago

sgehrman commented 4 years ago

Trying to center the barcode with 10 pixels on all sides.

The y parameter is not working. The barcode is drawn at the top of the image, not 10 pixels down.

I'll try to fix it and add it to my last PR.

   final image = img.Image(320, 320);
      img.fill(image, img.getColor(255, 255, 255));

      drawBarcode(image, Barcode.qrCode(), jsonStr,
          width: 300, height: 300, x: 10, y: 10);
sgehrman commented 4 years ago

https://github.com/DavBfr/dart_barcode/pull/11

DavBfr commented 4 years ago

Fixed in barcode_image 1.0.3, thanks.