Drawbitmap Method - Citizen CL-S700 Programming Manual

Android label print sdk
Hide thumbs Also See for CL-S700:
Table of Contents

Advertisement

2.3.6 drawBitmap method

Syntax
1) int drawBitmap (String filePath, int rotation, int width, int height, int x, int y)
2) int drawBitmap (String filePath, int rotation, int width, int height, int x, int y,
Parameters
Parameter
filePath
rotation
width
height
x
y
resolution
measurementUnit
Description
Draws a graphic image stored in the local computer, with specifying options such as rotation, size and
coordinates.
What this method does internally is to store a graphic image into the printer and to print the stored
graphic image. This doesn't check the availability or validity of the stored file. When specifying
image rotation, it is necessary to specify the resolution and unit selection settings according to the
printer for reference position correction.
Supported graphic file formats are BMP/GIF/EXIF/JPG/PNG/TIFF.
The graphic will be resized based on the width/height parameters with keeping the aspect ratio and
taking the maximum available size to fit.
Example: The sizes will be "200x50" in the case below.
Original sizes: 400x100 pixels
Width parameter: 200
Height parameter: 200
When 0 is set to either width or height, the sizes will be calculated based on another (non-zero)
parameter. When both parameters are zero, the original sizes will be used.
Example:The sizes will be "800x200" in the case below.
Original sizes: 400x100 pixels
Width parameter: 0
Height parameter: 200
Return value
Returns CLS_SUCCESS(0) on success, an error code otherwise. See
codes.
int resolution, int measurementUnit)
[IN/OUT] Description
[IN]
Path to a local graphic file
[IN]
Direction of rotation
[IN]
Drawing width [Pixel]
[IN]
Drawing height [Pixel]
[IN]
X-coordinate
[IN]
Y-coordinate
[IN]
Resolution [dpi]
[IN]
Printer Metric / Inch setting
CITIZEN Android Label Print SDK — Programming Manual
Setting range
CLS_RT_NORMAL: No rotation
CLS_RT_RIGHT90: Rotate CW 90
CLS_RT_ROTATE180: Rotate CW 180
CLS_RT_LEFT90: Rotate CCW 90
0000-9999
* The origin is at bottom-left.(0, 0)
CLS_PRT_RES_203(203dpi)
CLS_PRT_RES_300(300dpi)
* 203 dpi by default.
CLS_UNIT_MILLI
CLS_UNIT_INCH
* CLS_UNIT_INCH by default.
64
"2.1 Return
value" for the error

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents