Closed daanggc closed 5 months ago
Thanks to reportingissue I found more improvements for the vertical scaling, it looks even better now.
I also added a PDF417 barcode test in the list, here it is with the real print and the overlay:
As long as the rows and columns are defined, it's very good. The visible differences are basically always related to the ZXing library having to guess the row/column combination.
Hardened the Code128 drawer code a bit more and improved GS1 support, added an example and this is the generated and printed result of that:
You can preview it here: https://binarykits.dvdg.nu/
A DHL label that I use crashed on the PDF417 barcode and the Code128 barcodes are too long to fit on the page.
DHL uses
^BY2^B7N,6.7,5,,30,N
that has the following issues PDF417:^BY2
defines a width of2
but the code was hard set to3
.6.7
defines a rowHeight but as that is not an int, we default to 10.,,30
definesno
columns for30
rows, which is hard for the library used.DHL uses
>5
in the Code128 barcode. They do that to select the limited Code128C charset for that part of the barcode to have a shorter result, but we don't support that. A good fallback is theTYPE.CODE128
option, which automatically optimizes the charset usage and comes very close to the expected result.(Left: after with Labelary overlay, right: before)
EDIT 05-04-2024: After the last vertical scaling changes this is the result compared to the real print: