cute_qr_code 1.1.1
cute_qr_code: ^1.1.1 copied to clipboard
Aesthetic QR code generation for Flutter, ported from qrcode-kotlin.
1.1.1 #
Fixed #
- QR content not centered in widget preview when container size is not divisible by module count (
paintOntoCanvasremainder pixels) - QR content not centered when
canvasSizeis larger than the module grid or whenbackgroundColorexposes uneven padding - Logo clear/draw area misaligned with module coordinates when canvas padding exists
marginno longer double-applied via bothxOffset/yOffsetand canvas resize; quiet zone is centered via_resolveDrawOffsets
Added #
- Centering regression tests in
test/centering_test.dart(fixed canvas, margin,paintOntoCanvas, quiet-zone boundary)
Changed #
QrCodeConfig.xOffset/yOffsetare applied as extra offset from auto-centered layout, not as absolute top-left when canvas exceeds content size
1.1.0 #
Added #
CuteQrCode.data(),errorBuilder,CuteQrDataView,CuteQrCodeView,CuteQrRenderViewQrCode.paintOntoCanvas(),QrCodeProcessor.minTypeForData(),resolveTypeNumber()QrCodeConfig.strictTypeNumber,typeNumberalias- Encoding, layout, and error-handling tests
- Reorganized
lib/src/intoconfig/,core/,encoding/,painting/,rendering/,widgets/ - Bilingual (English + Chinese) documentation comments across public API
Changed #
CuteQrCodeconstraint-aware layout (LayoutBuilder+RenderBox)- Explicit
informationDensityauto-upgrades when too small (debug warning);0= auto QrCodePainterusespaintOntoCanvas- Internal import paths:
raw/+internals/→encoding/;render/→rendering/;color/+shape/→painting/
Fixed #
- Data-type regex ported incorrectly from kotlin
- Bit-accurate auto version selection
CuteQrRenderViewsizing under non-square tight constraints
Deprecated #
QrCode.fitIntoArea()— usepaintOntoCanvasorCuteQrRenderView
Migration #
- Remove hardcoded
informationDensity: 3; usenullor0for auto version selection - Place widgets in a bounded parent (
SizedBox,Expanded); fixedsizeis optional - Deep imports
package:cute_qr_code/src/internals/...→package:cute_qr_code/src/encoding/...
1.0.0 #
- Initial release — pure Dart/Flutter port of qrcode-kotlin
QrCodeConfigconfiguration API withQrCode.create(data, config)entry point- Shape factories:
squares,circles,roundedSquares,custom - Flutter
Color+ MaterialColors;QrColorUtils.css()for hex strings - Center logo via
ImageProvider(AssetImage,NetworkImage, etc.) - PNG export via
renderToBytes()andcuteQrCodeToPng() CuteQrCodewidget,QrCodePainter, and example app- Low-level
QrCodeProcessorencoding API