-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathREADME
59 lines (50 loc) · 1.84 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
PYQR - A pure Python QR-Code Generator
--------------------------------------------------------------------------------
Author : Hans Christian von Stockhausen [hc at vst dot io]
Date : 2010-08-09
Web : http://QR-CODE.co.za
http://twitter.com/photocode
http://github.com/hcvst/pyqr
--------------------------------------------------------------------------------
This is a pre alpha release /!\
One can generate the following codes: 1-M, 1-H, 2-L, 3-L
Alphanumeric and binary encoding are supported. Note, that alphanumeric mode is
NOT casesensitive.
EXAMPLES
========
To save a qr code to file.
>>> import qrcode
>>> qrc = qrcode.QRCode()
>>> qrc.encode("HTTP://QR-CODE.CO.ZA")
>>> img = qrc.to_image()
>>> img.save('./code.png')
To display a qr code as text.
>>> import qrcode
>>> qrc = qrcode.QRCode()
>>> qrc.encode("HTTP://QR-CODE.CO.ZA")
>>> s = qrc.to_string(on='g') # g rendered as black box when font set to Webdings
>>> print(s)
TODO
====
* update testcases
* clean up, refactor rewrite
* validate input lengths
* encapsule the various specification tables
* look into the bitlist helper
* use appends instead of concats with lists
* make code more robust or at least crash rather than producing garbage
* optimal mask selection (currently 011 is used)
* add support for version > 3
* automatically select version that best fits data if none specified
* add support for microqr
LIMITATIONS
===========
Too many to list
KNOWN ISSUES
============
Generating a 1-M for too long input results in a code that crashes the Android barcode
scanner. Probably due to some incorrect padding (0000 and 236,17) on my side.
COPYRIGHT & LICENSE
===================
The file ffield.py is copyright Emin Martinian, 2002. See ffield.py for license terms.
All other files are copyright Hans Christian von Stockhausen, 2010. See LICENSE file for terms.