Commit b8c6ebb4 authored by Andrey's avatar Andrey

readme, changelog, pubspec

parent bb37fa2d
## [2.0.0]
* Bluetooth printers support (beta version, iOS-only)
## [1.5.0] ## [1.5.0]
* printlnMixedKanji merged to println * printlnMixedKanji merged to println
* Can print rows/cols with mixed chinese/non-chinese texts * Can print rows/cols with mixed chinese/non-chinese texts
......
...@@ -2,19 +2,21 @@ ...@@ -2,19 +2,21 @@
![Pub](https://img.shields.io/pub/v/esc_pos_printer.svg) ![Pub](https://img.shields.io/pub/v/esc_pos_printer.svg)
The library allows to print receipts using a ESC/POS (usually thermal) network printer. The library allows to print receipts using an ESC/POS thermal WiFi/Bluetooth printer.
[[pub.dev page]](https://pub.dev/packages/esc_pos_printer) [[pub.dev page]](https://pub.dev/packages/esc_pos_printer)
| [[Documentation]](https://pub.dev/documentation/esc_pos_printer/latest/) | [[Documentation]](https://pub.dev/documentation/esc_pos_printer/latest/)
It can be used in [Flutter](https://flutter.dev/) or [Dart](https://dart.dev/) projects. In Flutter, both Android and iOS are supported. WiFi printing can be used in [Flutter](https://flutter.dev/) or pure [Dart](https://dart.dev/) projects. For Flutter projects, both Android and iOS are supported.
Bluetooth printing can be used only for iOS. Android support will come soon.
To discover existing printers in your subnet, consider using [ping_discover_network](https://pub.dev/packages/ping_discover_network) package. Note that most of the ESC/POS printers by default listen on port 9100. To discover existing printers in your subnet, consider using [ping_discover_network](https://pub.dev/packages/ping_discover_network) package. Note that most of the ESC/POS printers by default listen on port 9100.
## Main Features ## Main Features
* Connect to Wi-Fi printers * Connect to Wi-Fi / Bluetooth printers
* Simple text printing using *println* method * Simple text printing using *text* method
* Tables printing using *printRow* method * Tables printing using *printRow* method
* Text styling: * Text styling:
* size, align, bold, reverse, underline, different fonts, turn 90° * size, align, bold, reverse, underline, different fonts, turn 90°
...@@ -27,7 +29,7 @@ To discover existing printers in your subnet, consider using [ping_discover_netw ...@@ -27,7 +29,7 @@ To discover existing printers in your subnet, consider using [ping_discover_netw
**Note**: Your printer may not support some of the presented features (especially for underline styles, partial/full paper cutting, reverse feed, ...). **Note**: Your printer may not support some of the presented features (especially for underline styles, partial/full paper cutting, reverse feed, ...).
## Getting Started ## Getting Started (WiFi printer)
```dart ```dart
import 'package:esc_pos_printer/esc_pos_printer.dart'; import 'package:esc_pos_printer/esc_pos_printer.dart';
...@@ -103,15 +105,14 @@ final List<int> barData = [1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 4]; ...@@ -103,15 +105,14 @@ final List<int> barData = [1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 4];
printer.printBarcode(Barcode.upcA(barData)); printer.printBarcode(Barcode.upcA(barData));
``` ```
## Getting Started (Bluetooth printer)
See example project *blue*.
## TODO ## TODO
* ~~Add raw print function~~ * Bluetooth print / add Android support
* ~~Print images~~ * WiFi print / use Ticket class to make both, WiFi and Bluetooth interfaces more uniform
* ~~Print barcodes~~
* Print QR codes * Print QR codes
* ~~Turn 90° clockwise rotation mode on/off~~
* ~~Flutter example: discover active Wi-Fi printers~~
* USB printers support * USB printers support
* ~~Add encoding commands~~
## Test print ## Test print
<img src="https://github.com/andrey-ushakov/esc_pos_printer/blob/master/example/receipt.jpg?raw=true" alt="test receipt" height="500"/> <img src="https://github.com/andrey-ushakov/esc_pos_printer/blob/master/example/receipt.jpg?raw=true" alt="test receipt" height="500"/>
name: esc_pos_printer name: esc_pos_printer
description: The library allows to print receipts using a ESC/POS (usually thermal) network printer. It can be used in Flutter or Dart projects. In Flutter, both Android and iOS are supported. description: The library allows to print receipts using an ESC/POS thermal WiFi/Bluetooth printer.
version: 1.5.0 version: 2.0.0
author: Andrey Ushakov <flutter@tablemi.com>
homepage: https://github.com/andrey-ushakov/esc_pos_printer homepage: https://github.com/andrey-ushakov/esc_pos_printer
environment: environment:
...@@ -14,10 +13,11 @@ dependencies: ...@@ -14,10 +13,11 @@ dependencies:
image: ^2.1.4 image: ^2.1.4
gbk_codec: ^0.3.1+3 gbk_codec: ^0.3.1+3
rxdart: ^0.23.1 rxdart: ^0.23.1
flutter_bluetooth_basic: flutter_bluetooth_basic: ^0.0.1
git: # flutter_bluetooth_basic:
url: git://github.com/andrey-ushakov/flutter_bluetooth_basic # git:
ref: master # url: git://github.com/andrey-ushakov/flutter_bluetooth_basic
# ref: master
dev_dependencies: dev_dependencies:
flutter_test: flutter_test:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment