printLabelBitmap method

  1. @override
Future<void> printLabelBitmap(
  1. dynamic img, {
  2. LabelPrintBitmapStyle? printBitmapStyle,
})
override

Implementation

@override
Future<void> printLabelBitmap(dynamic img,{LabelPrintBitmapStyle? printBitmapStyle}) async {
  Map<String, dynamic> arguments = <String, dynamic>{
    "printBitmapStyle": printBitmapStyle?.toMap(),
  };
  if (img is Uint8List) {
    arguments.putIfAbsent("bitmap", () => img);
  }else{
    arguments.putIfAbsent("bitmapUrl", () => img);
  }
  await methodChannel.invokeMethod<void>('printLabelBitmap', arguments);
}