Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
4.8.3 Aligning Text
Simple alignment. Our next goal is to rotate text such that its original lower left corner
will be placed at a given reference point (see Figure 4.9). This may be useful, for example,
for placing a rotated column heading in a table header:
PDF_fit_textline(p, text, 5, 5, "orientate west");
This code fragment orientates the text to the west (90? counterclockwise) and then
translates it the lower left corner of the rotated text to the reference point (5, 5).
Aligning text at a vertical line. Positioning text along a vertical line (i.e., a box with
zero width) is a somewhat extreme case which may be useful nevertheless (see Figure
4.10):
PDF_fit_textline(p, text, 0, 0, "boxsize {0 600} position {0 50} orientate west");
This code fragment rotates the text, and places it at the center of the line from (0, 0) to
(0, 600).