Printer constructor

Printer({
  1. required String name,
  2. required PrinterStatus status,
  3. required String hot,
  4. required String version,
  5. required String id,
  6. required String cutter,
  7. required String density,
  8. required String distance,
  9. required String gray,
  10. required String paper,
  11. required String type,
  12. required Future<PrinterStatus> getStatus(),
  13. required Future<void> openCashDrawer(),
  14. required Future<bool> isCashDrawerOpen(),
  15. required Future<void> printEscPosCommands(
    1. Uint8List commands
    ),
  16. required Future<void> waitForCashDrawerClose(),
  17. required Future<void> setAlign(
    1. Align align
    ),
  18. required Future<void> printText(
    1. String text, {
    2. Align align,
    3. bool bold,
    4. bool italic,
    5. bool strikethrough,
    6. int textHeightRatio,
    7. int textSpace,
    8. int textWidthRatio,
    9. bool underline,
    }),
  19. required Future<void> autoOut(),
  20. required Future<void> printQrCode(
    1. String data, {
    2. Align align,
    3. int dot,
    }),
  21. required Future<void> printTexts(
    1. List<String> texts, {
    2. List<Align> columnAligns,
    3. List<int> columnWidths,
    }),
  22. required Future<void> addText(
    1. String text, {
    2. Align align,
    3. bool bold,
    4. bool italic,
    5. bool strikethrough,
    6. int textHeightRatio,
    7. int textSpace,
    8. int textWidthRatio,
    9. bool underline,
    }),
})

Implementation

Printer({
  required this.name,
  required this.status,
  required this.hot,
  required this.version,
  required this.id,
  required this.cutter,
  required this.density,
  required this.distance,
  required this.gray,
  required this.paper,
  required this.type,
  required this.getStatus,
  required this.openCashDrawer,
  required this.isCashDrawerOpen,
  required this.printEscPosCommands,
  required this.waitForCashDrawerClose,
  required this.setAlign,
  required this.printText,
  required this.autoOut,
  required this.printQrCode,
  required this.printTexts,
  required this.addText,
});