GDDM-PGF V2R1.3 OPS User's Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF | BOOK


Transforming the text string

GDDM-PGF V2R1.3 OPS User's Guide
SC33-1776-00



TEXT lets you write text upside-down or mirrored, by using negative values for the character box width or height. See Figure 23 for an illustration of how to achieve the various effects. All examples have the form:


          text 'Size x y' 50 50% size x y

where x and y vary.


    __________________________________________________________________________________ 
   |                                                                                  |
   |                                                                                  |
   |                                                                                  |
   |                                                                                  |
   | PICTURE 20                                                                                 |
   |                                                                                  |
   |                                                                                  |
   |                                                                                  |
   |__________________________________________________________________________________|

Figure 23. How to mirror text and turn it upside down


Using the TEXT command, you can rotate a text, as shown in Figure 24. Use TURN, followed by the angle in degrees, to specify the rotation. Positive angles give counterclockwise rotation, as in:


          text 'Rotated' 40 10 turn 45

You can only really rotate vector symbols; image symbols appear as if written on a ramp, but the individual characters are not rotated.

TURN goes well with centering, as in:


          text 'OPS' cc 50% 50% turn 180

which writes the word OPS upside down in the middle of the screen.

You can also shear a text with the keyword SHEAR followed by an angle in degrees. The angle is counted from the y-axis towards the x-axis, so a small positive angle will result in a text which tilts slightly to the right:


          text 'Very important' 10 20, shear 20

You can combine TURN and SHEAR, as in:


          text 'Words on a ramp' 2 2, turn 45, shear 45

This rotates the entire text 45 degrees counterclockwise while tilting the letters 45 degrees clockwise. The result is a text line pointing up towards the right, with all letters normal. See Figure 24.


    __________________________________________________________________________________ 
   |                                                                                  |
   |                                                                                  |
   |                                                                                  |
   |                                                                                  |
   | PICTURE 21                                                                                 |
   |                                                                                  |
   |                                                                                  |
   |                                                                                  |
   |__________________________________________________________________________________|

Figure 24. Rotating and shearing text


Go to the previous page Go to the next page



Copyright IBM Corporation 1990, 2012