Previous Next


                                             441
     SECTION 5.6                                                         Composite Fonts



     In the first format, c is a starting CID and is followed by an array containing num-
     bers interpreted in groups of three. Each group consists of the vertical component
     of the vertical displacement vector w1 (whose horizontal component is always 0)
     followed by the horizontal and vertical components for the position vector v. Suc-
     cessive groups define the vertical metrics for consecutive CIDs starting with c.
     The second format defines a range of CIDs from cfirst to clast , followed by three
     numbers that define the vertical metrics for all CIDs in this range. For example:

       /W2 [ 120 [ −1000 250 772 ]
             7080 8032 −1000 500 900
           ]

     This W2 entry defines the vertical displacement vector for the glyph with CID
     120 as (0, −1000) and the position vector as (250, 772). It also defines the dis-
     placement vector for CIDs in the range 7080 through 8032 as (0, −1000) and the
     position vector as (500, 900).


5.6.4 CMaps

     A CMap specifies the mapping from character codes to character selectors. In
     PDF, the character selectors are always CIDs in a CIDFont (as mentioned earlier,
     PostScript CMaps may use names or codes as well). A CMap serves a function
     analogous to the Encoding dictionary for a simple font. The CMap does not refer
     directly to a specific CIDFont; instead, it is combined with it as part of a CID-
     keyed font, represented in PDF as a Type 0 font dictionary (see Section 5.6.5,
     “Type 0 Font Dictionaries”). Within the CMap, the character mappings refer to
     the associated CIDFont by font number, which in PDF is always 0.

     Note: PDF also uses a special type of CMap to map character codes to Unicode val-
     ues (see Section 5.9.2, “ToUnicode CMaps”).

     A CMap also specifies the writing mode—horizontal or vertical—for any
     CIDFont with which the CMap is combined. The writing mode determines
     which metrics are to be used when glyphs are painted from that font. (Writing
     mode is specified as part of the CMap because, in some cases, different shapes are
     used when writing horizontally and vertically. In such cases, the horizontal and
     vertical variants of a CMap specify different CIDs for a given character code.)

Previous Next