void XRotDrawAlignedImageString(dpy, rotfont, drawable, gc, x,
y, text, align)
Display *dpy;
XRotFontStruct *rotfont;
Drawable drawable;
GC gc;
int x, y;
char *text;
int align
The XRotDrawAlignedString and XRotDrawAlignedImageString functions are both used to paint the character string text in the rotated font described by rotfont.
These functions are capable of drawing strings containing newline characters, by treating these newlines as delimiters to substrings. A substring is painted above, below, left or right of the previous substring depending on the font direction.
The alignment argument
align
describes how to position the block of substrings in relation to the point
(x, y).
Align
can take one of the values:
TLEFT, TCENTRE, TRIGHT, MLEFT, MCENTRE, MRIGHT,
BLEFT, BCENTRE, BRIGHT.
Note that alignment refers to a
rotated set of axes;
e.g. for a font rotated at 90 degrees, the `vertical' direction
actually runs East-West on the screen.
The first character describes how the block is positioned `vertically'
with respect to the reference point;
T=Top, M=Middle, B=Bottom. The remaining phrase describes 'horizontal'
positioning;
LEFT, CENTRE or RIGHT. The value
MCENTRE
centres the block at the
reference point. See the manual page for
xvertext
for more details of alignment.
The two functions differ in that XRotDrawAlignedString leaves the background pixels untouched, drawing the text in the foreground colours of gc. XRotDrawAlignedImageString fills the background in with the background colour of gc before painting the text. Note that only the foreground and background attributes of gc are used by these functions.