17.05.2014 Views

PDFlib 8 Windows COM/.NET Tutorial

PDFlib 8 Windows COM/.NET Tutorial

PDFlib 8 Windows COM/.NET Tutorial

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

In addition to the internal table, the fullwidth characters U+FF01 to U+FF5E will be replaced<br />

with the corresponding ISO 8859-1 characters (i.e. U+0021 to U+007E) if the<br />

fullwidth variants are not available in the font.<br />

> Decompose Unicode ligatures into their constituent glyphs (e.g. replace U+FB00<br />

Latin small ligature ff with the sequence U+0066 f, U+0066 f).<br />

> Select glyphs with the same Unicode semantics according to their glyph name. In<br />

particular, all glyph name suffixes separated with a period will be removed if the corresponding<br />

glyph is not available (e.g. replace A.swash with A; replace g.alt with g).<br />

If none of these methods delivers a glyph for the Unicode value, the character specified<br />

in the replacementchar option will be used. If the corresponding glyph itself is not available<br />

in the font (or the replacementchar option was not specified), U+00A0 (NO-BREAK<br />

SPACE) and U+0020 (SPACE) will be tried. If these are still unavailable, glyph ID 0 (the<br />

missing glyph symbol) will be used.<br />

For PDF/A-1, PDF/X-4 and PDF/X-5 input codes which map to glyph ID 0 will be<br />

skipped.<br />

Cookbook A full code sample can be found in the Cookbook topic fonts/glyph_replacement.<br />

5.3.3 Transforming Glyph IDs<br />

The determined glyph IDs are not yet final since several transformations may have to<br />

be applied before final output can be created. The details of these transformations depend<br />

on the font and several options. The steps below will be performed for all encodings<br />

except non-Unicode CMaps with keepnative=true.<br />

Vertical glyphs. For fonts in vertical writing mode some glyphs may be replaced by<br />

their vertical counterparts. This substitution requires a vert OpenType layout feature table<br />

in the font.<br />

OpenType layout features. OpenType features can create ligatures, swash characters,<br />

small caps, and many other typographic variations by replacing one or more glyph IDs<br />

with other values. OpenType features are discussed in Section 6.3, »OpenType Layout<br />

Features«, page 158. OpenType layout features are relevant only for suitable fonts (see<br />

»Requirements for OpenType layout features«, page 160), and are applied according to<br />

the features option.<br />

Complex script shaping. Shaping reorders the text and determines the appropriate<br />

variant glyph according to the position of a character (e.g. initial, middle, final, or isolated<br />

form of Arabic characters). Shaping is discussed in Section 6.4, »Complex Script Output«,<br />

page 164. It is relevant only for suitable fonts (see »Requirements for shaping«,<br />

page 166, and is applied according to the shaping option.<br />

126 Chapter 5: Font Handling (Edition for <strong>COM</strong>, .<strong>NET</strong>, and REALbasic)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!