String is output at X,Y position.
There are other attributes associated with text:
Character height real in w.c. (height/width ratio is set by font)
Character up vector X,Y direction in w.c.
Text path UP, DOWN, LEFT, RIGHT.
Text alignment: Horizontal, left, centre, right.
Vertical, TOP, CAP, BASE, HALF, BOTTOM.
Text primitive is most complex of all and requires many attributes.
Note that not all devices are capable of high quality (STROKE) output
and therefore will default to a lower quality.
i.e. T4010 cannot angle text => need software character generator.
i.e. set character up vector (1,1) both give 45 degrees
set character up vector (15,15)
Fig. 18.5 : Character Up Vector example
Default is right. Note that left does NOT reverse characters. Characters follow direction of Character Up Vector.
Fig. 18.6 : Text Path example
Horizontal alignment: Left, centre, right - like justification. Vertical alignment: Top, Bottom, Cap, Base, Half. These are alignment boundaries within the character font.
NOTE: horiz and vert are set by character up vector.
BASE is usually very important since it is line on which letters sit.
Text defaults: When the text path is set to right, the normal or default alignment should be left and when the text path is left, the alignment should be right. This implies that a normal alignment exists: GKS recognises this and allows another value of NORMAL.
Set text alignment (NORMAL,TOP) Set text alignment (NORMAL, NORMAL)
Real text: It is silly to assume that a device such as the T4010 can produce characters at any UP vector and at different aspect ratios. The text representation indicates what should happen if it can.
STROKE uses all attributes of TEXT CHAR uses fewer attributes STRING may use no attributes
Transforming of window to viewport may not shrink the text small enough (or at all) and hence a decision has to be made for char or string type devices as to whether the text should appear at all within the viewport.
Clipping of text now also depends upon the type of text. (Again T4010 cannot be expected to clip halfway through the character).