ImageGear Professional > API Reference Guide > PDF Component API Reference > PDF Component Objects Reference > Page Editing Objects and Elements > HIG_PDE_FONT > IG_PDE_font_create |
Creates a new PDE Font from the specified parameters.
Copy Code
|
|
---|---|
AT_ERRCOUNT ACCUAPI IG_PDE_font_create( LPAT_PDE_FONTATTRS lpAttrs, LONG nFirstCharIndex, LONG nLastCharIndex, LPSHORT lpWidths, LPSTR* lpEncoding, HIG_PDF_ATOM hEncodingBaseName, HIG_PDF_STREAM hFontStm, LONG nLen1, LONG nLen2, LONG nLen3, LPHIG_PDE_FONT lphFont ); |
Name | Type | Description |
lpAttrs | LPAT_PDE_FONTATTRS | Pointer to AT_PDE_FONTATTRS for the font attributes. |
nFirstCharIndex | LONG | First character index for the widths array, lpWidths. |
nLastCharIndex | LONG | Last character index for the widths array, lpWidths. |
lpWidths | LPSHORT | Widths array. |
lpEncoding | LPSTR* | Array of 256 glyph names specifying the custom encoding. If any pointer is NULL, no encoding information is written for that entry. |
hEncodingBaseName | HIG_PDF_ATOM | Encoding base name if the encoding is a custom encoding. If encoding is NULL, encodingBaseName is used as the value of the encoding, and must be one of WinAnsiEncoding, MacRomanEncoding, or MacExpertEncoding. If no encoding value is desired, use IG_PDF_ATOM_NULL. |
hFontStm | HIG_PDF_STREAM | Stream with font information. |
nLen1 | LONG | Length in bytes of the ASCII portion of the Type 1 font file after it has been decoded. For other font formats, such as TrueType or CFF, only Len1 is used, and it is the size of the font. |
nLen2 | LONG | Length in bytes of the encrypted portion of the Type 1 font file after it has been decoded. |
nLen3 | LONG | Length in bytes of the portion of the Type 1 font file that contains the 512 zeros, plus the clear-to-mark operator, plus any following data. |
lphFont | LPHIG_PDE_FONT | The specified PDE font. |
Error count.
This function does not process image pixels.
The PDE Font may be represented as an embedded font (a FontFile entry in the font descriptor of the PDF file). To create a PDE Font that is stored as an embedded font, the FontFile stream may be passed in hFontStm, and the nLen1, nLen2, and nLen3 parameters contain the Length1, Length2, and Length3 values of the FontFile stream attributes dictionary. See Section 5.8 in the PDF Reference for more information about embedded fonts.
Call IG_PDE_font_release to dispose of the returned font object when finished with it.