Skip to content

atomhudson/qr_code_scanner_and_generator

Repository files navigation

📱 QR Code Scanner & Generator

A modern, fast, and fully featured QR Code Scanner + QR Generator built using Flutter. Includes live camera scanning, gallery image scanning, QR generation, flash control, and more.


🚀 Features

🔍 QR Code Scanner

  • Real-time camera scanning using mobile_scanner
  • MLKit-based QR detection from gallery images
  • Smooth scanning animation & detection frame
  • Duplicate scan prevention (no repeat results)
  • Handles multiple barcode types (QR, EAN, UPC, etc.)
  • Auto-pause when QR is detected & resume after closing dialog
  • Flashlight toggle while scanning
  • Camera lifecycle handling (pause/resume on app minimize)

🖼️ Scan From Gallery

  • Pick an image from the gallery
  • Extract QR code using Google ML Kit
  • Error handling for invalid / unreadable images

QR Code Generator

  • Generate QR codes from text or URLs
  • Beautiful, customizable QR display
  • Save QR code as PNG
  • Share QR image or text

🧭 Modern UI / UX

  • Clean scanning frame with animated corners
  • Selectable scanned text
  • Copy-to-clipboard support
  • Material 3 design with easy theming
  • Snackbars for feedback (errors, success, copy action)

🔐 Permissions Handling

  • Camera permission request using permission_handler
  • Safe fallback UI if permission is denied

🛠️ Technologies Used

  • Flutter (Material 3)
  • mobile_scanner for camera scanning
  • google_mlkit_barcode_scanning for image scanning
  • image_picker for gallery images
  • qr_flutter for QR generation
  • permission_handler for permissions

📦 Installation

Clone the repo:

git clone https://github.com/atomhudson/qr_code_generator.git
cd qr_code_generator

Install dependencies:

flutter pub get

Run the app:

flutter run

📂 Project Structure

lib/
 ├── generate_qr/
 ├── scan_qr/
 ├── widgets/
 ├── main.dart

▶️ Getting Started with Flutter

A few official resources to help you if you're new to Flutter:


About

A Flutter App

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages