lincolnloop / python-qrcode

Python QR Code image generator
https://pypi.python.org/pypi/qrcode
Other
4.36k stars 666 forks source link

Add shapes #178

Closed StanTheMan132 closed 1 year ago

StanTheMan132 commented 5 years ago

I added functionality for qrcode's to be made out of diamonds. Similar to how you can choose different shapes on www.qrcode-monkey.com.
qr Try it out yourself by passing the shape="diamond" in the qrcode.make function. If no shape argument is passed it will default to square.

maribedran commented 3 years ago

@StanTheMan132 we recently merged #168 that adds a new image factory to allow adding color masks and different shapes. It introduces module drawers, responsible for drawing the shapes of the individual modules. Do you think this could be refactored into one of those module drawers? This approach allows a more flexible way of styling the QRs as the modules are pluggable and the main code doesn't have to be changed for each new format.