Set Text Alignment

\i C T bits::mode word::width word::height

Parameter Type Range Description
mode bits Bit 0 ... 7 alignment properties
width word 0 ... display width (0 = full display) width of the alignment area
height word 0 ... display height (0 = full display) height of the alignment area

This powerful command helps you to align text on the screen automatically. The next invocation of command Write Text, Write Text Message or Get Text Extent will align, word-wrap and crop text corresponding to the mode set by this command in the specified area. A maximum of 1024 characters and 48 text lines can be aligned. The mode consists of the following bits, which can be binary ORed together:

Bit Description
0 center text horizontally
1 center text vertically
2 right justify text
3 bottom justify text
4 do not word wrap text
5 add horizontal space for border
6 add vertical space for border
7 turn alignment on

Note

Response: [ACK]

Example

\iCT\x83\D200\D100

This will set text alignment to center subsequently outputted text horizontally and vertically in an area of 200 pixels width and 100 pixels height.

See also:

Write Text
Write Text Message
Get Text Extent
Set Line Style
Set Fonts Scaling
ANSI Support