38
CITIZEN UWP POS Print SDK - Programming Manual
2.3.9. PrintBitmapAsync method
Syntax
1)
Task<int> PrintBitmapAsync (string fileName, int alignment)
2)
Task<int> PrintBitmapAsync (string fileName, int width, int alignment)
3)
Task<int> PrintBitmapAsync (string fileName, int width, int alignment, int mode)
4)
Task<int> PrintBitmapAsync (BitmapDecoder bitmap, int alignment)
5)
Task<int> PrintBitmapAsync (BitmapDecoder bitmap, int width, int alignment)
6)
Task<int> PrintBitmapAsync (BitmapDecoder bitmap, int width, int alignment, int mode)
7)
Task<int> PrintBitmapAsync (byte[] bytes, int alignment)
8)
Task<int> PrintBitmapAsync (byte[] bytes, int width, int alignment)
9)
Task<int> PrintBitmapAsync (byte[] bytes, int width, int alignment, int mode)
Parameter
The meaning and the setting range of the parameters are as follows.
Value
[IN/OUT]
Meaning
Setting range
fileName
[IN]
Bitmap file name
bitmap
[IN]
BitmapDecoder type
data
bytes
[IN]
Byte array
representation of the
bitmap
width
[IN]
Bitmap width
CMP_BM_ASIS:
Print the bitmap with one bitmap pixel per
printer dot.
Other Values:
Bitmap width expressed. Expressed in the
unit of measure given by
dots).
alignment
[IN]
Bitmap alignment
CMP_ALIGNMENT_LEFT: Left alignment
CMP_ALIGNMENT_CENTER: Center alignment
CMP_ALIGNMENT_RIGHT: Right alignment
Other Values:
Distance from the left-most print column to
the start of the bitmap. Expressed in the unit
of measure given by
mode
[IN]
Bitmap mode
CMP_BM_MODE_HT_THRESHOLD:
Halftone threshold
CMP_BM_MODE_HT_DITHER:
Halftone dither
CMP_BM_MODE_CMD_RASTER:
Raster command output
CMP_BM_MODE_CMD_BITIMAGE:
Bitimage command output
CMP_BM_MODE_CMD_GRAY16:
Grayscale (4bpp) output
Description
This method is used to print bitmap which specifies file name or bitmap and width and alignment and
mode. File must be located in the local folder (Windows.Storage.ApplicationData.Current.LocalFolder).
Printable bitmap formats are BMP / JPG / PNG / GIF.
If the bitmap width is omitted, printing in CMP_BM_ASIS.