Makefont – AMT Datasouth PAL User Manual
Page 138

makefont
132
makefont
Description
Modifies a font dictionary to scale the characters with optional independent X and Y factors and
optional mirroring.
Usage
AnyFontDict TmArray
makefont
TmFontDict
AnyFontDict
Dictionary. Font dictionary returned by the findfont operator.
TmArray
Array. Transformation matrix to apply to scale the font's characters to the desired
X and Y dimensions. PAL modifies AnyFontDict. It does not create a new
dictionary.
Comments
Most users will find the scalefont simpler to use than the makefont operator. The makefont
operator requires additional complexity in relation to the scalefont operator in order to provide
additional capabilities. Users who simply wish to scale a font to a desired height should use the
scalefont operator.
The font dictionary returned by the findfont operator contains information designed to scale the
characters of the font to one user coordinate tall. The makefont operator modifies the font dic-
tionary to draw characters of any desired height and width. makefont also allows for drawing
characters as mirror images.
The font dictionary contains only relative character scaling information. PAL combines the font's
scaling information with the current user scaling factor to determine the true size of the characters.
PAL combines this information when it draws the characters.
Since fonts default to one user coordinate tall, and the user coordinate system defaults to one point
scaling, each character defaults to a height of one point. However, changing the user coordinate
scaling factor will accordingly change the default character height. For example, changing the user
coordinate system to inches changes the default character height to one inch.
The makefont operator allows the programmer to compensate for the current user coordinate sys-
tem scaling as well as establish any desired height and width for the characters. Under the default
coordinate scaling of points, the "AnyFontDict [12 0 0 12 0 0] makefont" operation will
configure the font information to draw 12 point characters. However, the same makefont
operation with a user coordinate system based on inches would produce 12 inch tall characters.
Therefore, with a user coordinate system based on inches, "AnyFontDict [12 72 div 0 0 12 72
div 0 0] makefont" will configure the font information to draw 12 point characters.
Although the scalefont operator requires less information, the makefont operator allows the user
to specify different scaling factors for the X and Y dimensions of the characters. The user can also
rotate the characters independent of rotating the coordinate system, as well as mirror the
characters. The following table summarizes the use of TmArray to produce various standard
character transformations.