Search packages, repositories and app categories

Package detailsv1.1.0

zxing_widget

A Barcode Generator Widget that can be embedded inside flutter. It uses zxing-dart for all platforms.

AndroidiOSWebmacOSWindowsLinux
30-day downloads
1.9K
Likes
6
Pub points
150

Install package

flutter pub add zxing_widget

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

zxing_widget is a Flutter package that provides a customizable barcode generator widget, leveraging zxing-dart for cross-platform compatibility. It enables developers to embed dynamic barcodes and QR codes directly into their Flutter applications across Android, iOS, Web, macOS, Windows, and Linux. The widget supports various barcode formats and integrates seamlessly with existing UIs. It's ideal for apps requiring on-the-fly barcode generation, such as ticketing systems, inventory management, or digital identity solutions.

Use cases

  • Generating QR codes for digital tickets
  • Creating product barcodes in inventory apps
  • Embedding scannable codes in user profiles
  • Supporting offline barcode generation
  • Enabling quick data sharing via QR codes

Key features

  • Cross-platform barcode generation
  • Integration with zxing-dart engine
  • Customizable barcode size and style
  • Support for multiple barcode formats
  • Lightweight and easy to embed

Suitable for

  • Mobile and web apps needing barcode output
  • Developers building inventory or ticketing systems
  • Apps requiring offline code generation
  • Flutter projects targeting multiple platforms

Considerations

  • Requires proper handling of permissions on mobile platforms
  • May need additional styling for optimal visual appearance
  • Limited to generating barcodes, not scanning them
  • Depends on zxing-dart for underlying functionality

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

ZXing Widget(Dart)

pub package

A Barcode Generator Widget that can be embedded inside flutter. It uses zxing-dart for all platforms.

ZXing Dart pub package
ZXing Widget pub package
ZXing Scanner pub package

Features

  • ✅ QRCode
  • ✅ PDF417 code
  • ✅ DataMatrix code
  • ✅ AZTec code
  • ✅ OneDemension code
  • ✅ Paint callback
  • ✅ Customize color
  • ✅ to image

Preview

Code Generator Preview

Getting started

flutter pub add zxing_widget

Usage

See /example folder.

Render a qrcode

BarcodeWidget(
    QrcodePainter(
        'qrcode data',
        errorCorrectionLevel: ErrorCorrectionLevel.H,
        foregroundColor: Colors.blue,
    ),
    size: const Size(200, 200),
),

Generate an image

import 'dart:ui' as ui;

final ui.Image image = QrcodePainter(
        'qrcode data',
        errorCorrectionLevel: ErrorCorrectionLevel.H,
        foregroundColor: Colors.blue,
    ).toImage(const Size(200, 200));

// binary png data
final binData = await image.toByteData(format: ui.ImageByteFormat.png);

Additional information

This package depends on zxing_lib witch is a pure dart port of ZXing.

Categories

Dependencies

Dependency list 1 items

Source repository

Projects using this package

No data available yet.