Ir al contenido principal

raygeo.barcode.qr

QR Code encoding.

The smallest QR version that fits the text is selected automatically; the requested error-correction level is kept exactly instead of being boosted to a higher level.

Functions​

encode()​

encode(
text: str,
error_correction: barcode.QrErrorCorrection = barcode.QrErrorCorrection.M,
) -> barcode.Encoded

Encodes text as a QR Code.

ParameterTypeDescription
textstr
error_correctionbarcode.QrErrorCorrection = barcode.QrErrorCorrection.M
Returnsbarcode.Encoded

The four QR error-correction levels for the same content

The four QR error-correction levels for the same content