mjafartp / flutter_esc_pos_utils

Flutter package of esc/pos utils
GNU General Public License v3.0
22 stars 45 forks source link

Impact printer POSColumn Spacing Issue #28

Open atish-pun opened 1 year ago

atish-pun commented 1 year ago

EPSON TM-U220D printer is unable to align right the text in poscolumn to get the output of spacebetween. How to resolve this issue? Instead of spacing, it prints random text.

chipcoiga commented 11 months ago

The same.

bytes += generator.row([
    PosColumn(
      text: 'MAT HANG',
      width: 5,
      styles: const PosStyles(align: PosAlign.left),
    ),
    PosColumn(
      text: 'SL',
      width: 1,
      styles: const PosStyles(align: PosAlign.center),
    ),
    PosColumn(
      text: 'D.Gia',
      width: 3,
      styles: const PosStyles(align: PosAlign.right),
    ),
    PosColumn(
      text: 'T.Tien',
      width: 3,
      styles: const PosStyles(align: PosAlign.right),
    ),
  ]);

395515432_2080647762275049_8980552944673749901_n

atish-pun commented 11 months ago

@chipcoiga, the issue mentioned by you may be due to incorrect paper width i.e. 58 or 80 mm. So, you can try adjusting the PaperSize given by this package with the paper size accepted by the respective printer. Hope it will fix your encountered issue.

I encountered an issue of another type while printing in a dot-matrix/impact printer instead of a thermal printer.

meetbrahmbhatt91 commented 3 months ago

@atish-pun We are getting similar errors. Have you found any solution to this?

atish-pun commented 3 months ago

@meetbrahmbhatt91, unfortunately, I have ignored it for impact printers as it's the issue from the package and it works well for thermal printers.