|
|
il y a 8 mois | |
|---|---|---|
| .. | ||
| Readme.markdown | il y a 8 mois | |
| qrcodegen-demo.py | il y a 8 mois | |
| qrcodegen.py | il y a 8 mois | |
| setup.py | il y a 8 mois | |
This project aims to be the best, clearest QR Code generator library. The primary goals are flexible options and absolute correctness. Secondary goals are compact implementation size and good documentation comments.
Home page with live JavaScript demo, extensive descriptions, and competitor comparisons: https://www.nayuki.io/page/qr-code-generator-library
Core features:
Manual parameters:
More information about QR Code technology and this library's design can be found on the project home page.
from qrcodegen import *
# Simple operation
qr0 = QrCode.encode_text("Hello, world!", QrCode.Ecc.MEDIUM)
svg = to_svg_str(qr0, 4) # See qrcodegen-demo
# Manual operation
segs = QrSegment.make_segments("3141592653589793238462643383")
qr1 = QrCode.encode_segments(segs, QrCode.Ecc.HIGH, 5, 5, 2, False)
for y in range(qr1.get_size()):
for x in range(qr1.get_size()):
(... paint qr1.get_module(x, y) ...)
More complete set of examples: https://github.com/nayuki/QR-Code-generator/blob/master/python/qrcodegen-demo.py .