Generate well-formatted, production-ready Barcodes.
By default, existing Python barcode libraries like python-barcode generate good barcodes, but any and all formatting of the text is left up to the user. beautiful_barcode generates a nicely formatted barcode with interleaved text out of the box:
Depending on your renderer (and true by default), text in the barcode is not an SVG
<text> element, as such an elment may render differently on different machines depending on font availability.
This library is currently limited to UPC-A and SVG – that's all we (the original authors) needed. Patches welcome!
$ pip install beautiful_barcode
>>> from beautiful_barcode import UPCA >>> UPCA('012345678905').write('output.svg')
$ python -m beautiful_barcode 012345678905 -o output.svg
Install Python 3 (3.7 or upwards), pipenv (
pip install pipenv) and
Then you can install the dependencies with
$ make install
Run tests and linting with
$ make test $ make lint