EasyManua.ls Logo

Epson TM T88V - Print Document Creation

Epson TM T88V
122 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
29
Chapter 3 Programming Guide
3
Print Document Creation
Create a print document using the Builder class (p.39).
Create a Builder class using the constructor for it and create a print document using APIs of the Builder
class. Use the programming example below for your reference.
To create a text print document:
To create a text print document, using APIs for text, store the font settings in command buffers to create a
print document. Use the programming example below for your reference.
try {
//Initialize a Builder class instance
Builder builder = new Builder("TM-T88V", Builder.MODEL_ANK);
//Create a print document
builder.addTextLang(Builder.LANG_EN);
builder.addTextSmooth(Builder.TRUE);
builder.addTextFont(Builder.FONT_A);
builder.addTextSize(3, 3);
builder.addText("Hello,\t");
builder.addText("World!\n");
builder.addCut(Builder.CUT_FEED);
} catch (EposException e) {
int errStatus = e.getErrorStatus();
}
try {
//Initialize a Builder class instance
Builder builder = new Builder("TM-T88V", Builder.MODEL_ANK);
//Create a print document
//<Configure the print character settings>
builder.addTextLang(Builder.LANG_EN);
builder.addTextSmooth(Builder.TRUE);
builder.addTextFont(Builder.FONT_A);
builder.addTextSize(4, 4);
builder.addTextStyle(Builder.FALSE, Builder.FALSE, Builder.TRUE, Builder.PARAM_UNSPECIFIE
//<Specify the print data>
builder.addText("Hello,\t");
builder.addText("World!\n");
builder.addCut(Builder.CUT_FEED);
} catch (EposException e) {
int errStatus = e.getErrorStatus();
}
For the string "Hello, World!", to create a print document based on the following settings:
Font: FontA
Scale: x 4 (horizontal) and x 4 (vertical)
Style: Bold

Table of Contents

Other manuals for Epson TM T88V

Related product manuals