22.03.2015 Views

DLI Implementation and Reference Guide - Datalogics

DLI Implementation and Reference Guide - Datalogics

DLI Implementation and Reference Guide - Datalogics

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.

Fonts 4.7<br />

dlpdffontcreate<br />

This is the basic font access method. It accepts a font name <strong>and</strong> optionally a font type,<br />

both as strings. When the font type is present, the method will attempt to find a font<br />

which matches both that type <strong>and</strong> name. If none is found, it will attempt to match the<br />

specified name in any type of font.<br />

Font Searching Sequence<br />

The specific dlpdffontcreate search procedure follows this sequence, in order,<br />

until a font fitting the search parameters is identified. For each test below, the order of<br />

preference when searching for a match is for Type 1 fonts first, then TrueType fonts,<br />

<strong>and</strong> finally CID fonts. If no match occurs, the next test in the sequence below is<br />

attempted.<br />

1 The current DLPDFDOC is searched for fonts with the same name <strong>and</strong> type as<br />

requested. If one was already created, it is returned.<br />

2 If a Base 14 font is requested <strong>and</strong> is not to be embedded, it is created <strong>and</strong> returned.<br />

3 If the name is matched in the DLPDFINSTANCE font cache, the font is copied to<br />

the current DLPDFDOC <strong>and</strong> returned. (This is where fonts loaded via<br />

dlpdfttload are processed.)<br />

4 The system is searched for a font of explicit name <strong>and</strong> type requested by the user. If<br />

found, it is created <strong>and</strong> returned.<br />

5 The system is searched for a font of explicit name (without regard to type)<br />

requested by the user. If found, it is created <strong>and</strong> returned.<br />

6 If any font of the same family <strong>and</strong> typeface style is found, it is created <strong>and</strong><br />

returned.<br />

If a font using a one-byte encoding is found for this name, its width table in the<br />

document’s encoding will be loaded into the DLPDFFONT->WidthTable. If the<br />

document indicates that all fonts are to be embedded, this font will be embedded <strong>and</strong><br />

subset if possible. The font structure created will carry all of the metrics of this font,<br />

so that if it is not embedded <strong>and</strong> is not present on the imaging platform, a Multiple<br />

Master (or "multi-master") font can be used to provide imaging of the document.<br />

The encoding used in this font will be the encoding specified in<br />

dlpdfdocsetencoding, if that call has been used; otherwise it will default<br />

depending on the system in use: WinAnsiEncoding will be used on Windows

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

Saved successfully!

Ooh no, something went wrong!