fqreader 0.1.6

fqreader pub package

一个可以自定义的扫描控件,

Usage Add this to your package's pubspec.yaml file:

dependencies:
  fqreader: "^0.1.6"

Fqreader #

decodeImg #

解析图片

ParamTypeDefaultDescription
[file]File图片文件
[scanType]ListScanType.ALL扫描的类型,默认全部类型

返回

ScanView #

ParamTypeDefaultDescription
[onScan]ScanEvent扫描事件
[scanRect]Rect扫描区域位置大小, scanRect和scanSize 只能用一个
[scanSize]Size扫描区域大小, scanRect和scanSize 只能用一个
[viewSize]SizeScanView控件大小
[scanAilgn]Alignment扫描框的位置(位于图片)
[viewAilgn]Alignmentview的位置(位于图片)
[autoScan]booltrue是否立即扫描
[continuityScan]boolfalse是否连续扫描
[scanInterval]Duration0.5s连续扫描间隔
[scanType]ListScanType.ALL扫描的条码类型
[devicePixelRatio]double屏幕分辨率

ScanViewState #

startScan #

开始扫描

stopScan #

暂停扫描

turnOn #

开灯

turnOff #

关灯

ScanType #

EnumDescription
[ALL]所有条形码
[QR_CODE]普通二维码
[AZTEC]二维码 主要用于航空。比如坐飞机行李箱上贴的便签
[CODABAR]条形码
[CODE_39]CODE 39 条形码
[CODE_93]CODE 92 条形码
[CODE_128]CODE 128 条形码
[EAN8]商品用条形码 EAN8
[EAN13]商品用条形码 EAN13
[ITF]全球贸易货号。主要用于运输方面的条形码
[DATA_MATRIX]一种二维码
[PDF_417]PDF417条码是一种高密度、高信息含量的便携式数据文件

0.0.1 #

  • TODO: Describe initial release.

0.0.3 #

  • 修复释放时闪退问题

0.0.4 #

  • 修复释放时闪退问题

0.1.3 #

  • 优化了选择拍照尺寸的规则

0.1.4 #

  • 修复了扫描框在某些手机扫描不了的问题

0.1.5 #

  • 添加了条码的竖扫描

example/README.md

fqreader_example #

Demonstrates how to use the fqreader plugin.

Getting Started #

For help getting started with Flutter, view our online documentation.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  fqreader: ^0.1.6

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:fqreader/fqreader.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
34
Health:
Code health derived from static analysis. [more]
87
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
80
Overall:
Weighted score of the above. [more]
59
Learn more about scoring.

We analyzed this package on Aug 18, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.4.0
  • pana: 0.12.19
  • Flutter: 1.7.8+hotfix.4

Platforms

Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health suggestions

Fix lib/scan_view.dart. (-7.24 points)

Analysis of lib/scan_view.dart reported 15 hints, including:

line 4 col 3: Prefer using /// for doc comments.

line 9 col 3: Prefer using /// for doc comments.

line 13 col 3: Prefer using /// for doc comments.

line 17 col 3: Prefer using /// for doc comments.

line 22 col 3: Prefer using /// for doc comments.

Fix lib/fqreader.dart. (-6.31 points)

Analysis of lib/fqreader.dart reported 13 hints, including:

line 8 col 8: Unused import: 'dart:ui'.

line 107 col 3: Prefer using /// for doc comments.

line 111 col 3: Prefer using /// for doc comments.

line 115 col 3: Prefer using /// for doc comments.

line 119 col 3: Prefer using /// for doc comments.

Maintenance suggestions

The package description is too short. (-20 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0-dev.68.0 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11 1.14.12
meta 1.1.6 1.1.7
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8