66
addTextAlign method
Adds the text alignment setting to the command buffer.
Syntax
addTextAlign
(align);
Parameter
align
:
(
Required
parameter,
Object
type
:
String)
Specifies
the
text
alignment.
Return value
Exception
Example
• This
API
setting
is
applied
to
raster
image/NV
logo/barcode/two
‐
dimensional
symbol.
• When
using
the
standard
mode,
specify
addTextAlign
in
ʺ
Position
at
the
beginning
of
lines
ʺ
.
• In
the
page
mode,
addTextAlign
method
specification
cannot
be
used.
In
the
page
mode,
use
the
addTextPosition
method
to
designate
the
horizontal
position.
• When
the
page
mode
is
selected
for
the
mode,
to
set
text
rotation,
use
the
addPageDirection
method
(
instead
of
this
API
function.
Constant(align)
Description
ALIGN_LEFT (default)
Alignment to the left
ALIGN_CENTER
Alignment to the center
ALIGN_RIGHT
Alignment to the right
Return value
Object type
ePOS-Print Builder Object
ePOS Builder
Exception
Object type
Parameter " ... " is invalid
Error
<script type="text/javascript" src="epos-print-3.x.x.js"></script>
<script type="text/javascript">
<!--
function buildMessage() {
var builder = new epson.ePOSBuilder();
builder.addTextAlign(builder.ALIGN_CENTER);
}
//-->
</script>
To set alignment to the center:
Summary of Contents for TM-T88V-i
Page 10: ...10 ...
Page 14: ...14 ePOS Print Canvas API Monochrome or Grayscale Monochrome ...
Page 160: ...160 ...
Page 258: ...258 ...