-
Notifications
You must be signed in to change notification settings - Fork 249
Description
Hello,
I want to display an image in center of page, but not getting it displayed on center.
Kindly provide if someone got this working.
Thanks in advance.
Below is my code snippet.
void printOrder(queryParameters) async {
Map<String, dynamic> config = {};
List list = [];
list.add(LineText(type: LineText.TYPE_IMAGE, content: base64Image, align: LineText.ALIGN_CENTER, width: 200, height: 100, linefeed: 1));
list.add(LineText(linefeed: 1));
list.add(LineText(type: LineText.TYPE_TEXT, content: 'Token No.${tokenNo.text}', weight: 1, align: LineText.ALIGN_CENTER, linefeed: 1));
list.add(LineText(linefeed: 1));
list.add(LineText(type: LineText.TYPE_TEXT, content: 'Name: ${accountName.text} ${dateInput.text} ${queryParameters['orderTime']}', weight: 1, align: LineText.ALIGN_LEFT, linefeed: 1));
list.add(LineText(type: LineText.TYPE_TEXT, content: '--------------------------------', align: LineText.ALIGN_LEFT, linefeed: 1));
list.add(LineText(type: LineText.TYPE_TEXT, content: 'Item Qty Rate Amt', weight: 1, align: LineText.ALIGN_LEFT, linefeed: 1));
list.add(LineText(type: LineText.TYPE_TEXT, content: '--------------------------------', align: LineText.ALIGN_LEFT, linefeed: 1));
await bluetoothPrint.printReceipt(config, list);
}
Thanks!
