DynaPDF Manual - Page 237

Previous Page 236   Index   Next Page 238

Function Reference
Page 237 of 839
CreateAltFontList
Syntax:
SI32 pdfCreateAltFontList(
const PPDF* IPDF) // Instance pointer
The function creates an alternate font list, that can be filled with data by SetAltFonts(). It is possible
to create an arbitrary number of alternate font lists. Multiple lists can be created because different
fonts and languages require different fallback fonts. For example, one could create one list for
proportional fonts and another one for fixed pitch fonts, or different lists for different languages.
Each list can be activated or deactivated with ActivateAltFontList() arbitrary often. Changing the
active alternate font list is very fast and causes no overhead.
Once a font list was created it can be filled with data with SetAltFonts(). A font list that is no longer
needed can be deleted with DeleteAltFontList().
Please note that alternate font lists are used only, if complex text layout was enabled. This can be
done by setting the flag gfComplexText with SetGStateFlags().
Return values:
If the function succeeds the return value is the handle of the font list, a value greater or equal zero. If
the function fails the return value is a negative error code.
CreateAnnotAP
Syntax:
SI32 pdfCreateAnnotAP(
const PPDF* IPDF, // Instance pointer
UI32 Annot)
// Annotation handle
The function creates a user defined appearance stream for an annotation and activates it so that
arbitrary contents can be drawn into it, such as text, images, or vector graphics. An appearance
stream is a normal template in the size of the annotation. The template must be closed when finish
with EndTemplate().
Note that the template is reserved for the annotation and must not be used on pages or other
templates.
At time of publication user defined appearance streams can be created for Stamp and FreeText
annotations. However, the main application is the creation of user defined stamps. The appearance
stream of a FreeText annotation should correspond to the annotation's value.
It is allowed to insert an EMF file into a user defined appearance stream. If the contents should be
imported from an external PDF file then import the wished page with ImportPage() and place the
resulting template into this one with PlaceTemplate() or PlaceTemplateEx(). The latter version is
preferred because it considers the original page orientation and bounding boxes. See
PlaceTemplateEx() for further information.
 

Previous topic: Orthographic projection, Create3DView

Next topic: CreateArticleThread