Previous Next


                                CHAPTER 5


                                    5   Text

This chapter describes the special facilities in PDF for dealing with text— specifi-
cally, for representing characters with glyphs from fonts. A glyph is a graphical
shape and is subject to all graphical manipulations, such as coordinate transfor-
mation. Because of the importance of text in most page descriptions, PDF pro-
vides higher-level facilities that permit an application to describe, select, and
render glyphs conveniently and efficiently.

The first section is a general description of how glyphs from fonts are painted on
the page. Subsequent sections cover the following topics in detail:

• Text state. A subset of the graphics state parameters pertain to text, including
  parameters that select the font, scale the glyphs to an appropriate size, and
  accomplish other graphical effects.
• Text objects and operators. The text operators specify the glyphs to be painted,
  represented by string objects whose values are interpreted as sequences of char-
  acter codes. A text object encloses a sequence of text operators and associated
  parameters.
• Font data structures. Font dictionaries and associated data structures provide
  information that a consumer application needs to interpret the text and posi-
  tion the glyphs properly. The definitions of the glyphs themselves are contained
  in font programs, which may be embedded in the PDF file, built into the appli-
  cation, or obtained from an external font file.




                                         387

Previous Next