printTextFull method

  1. @override
Future<bool?> printTextFull({
  1. required String text,
  2. PrinterTextStyle? style,
})
override

Implementation

@override
Future<bool?> printTextFull(
    {required String text, PrinterTextStyle? style}) async {
  try {
    if (style == null) {
      return printText(text);
    }
    return await printingMethodChannel.invokeMethod<bool>('printTextFull', {
      "text": text,
      "textSize": style.textSize?.value,
      "textDirection": style.textDirection?.value,
      "textFont": style.textFont?.value,
      "alignment": style.alignment?.value,
      "isBold": style.isBold,
      "isUnderlined": style.isUnderlined,
    });
  } catch (_) {
    return null;
  }
}