DynaPDF Manual - Page 457

Previous Page 456   Index   Next Page 458

Function Reference
Page 457 of 839
The function can be used to access the optional metadata streams of pages, fonts, images, pages,
templates, as well as the global metadata stream that is associated with the Catalog object. Metadata
streams are in XMP format that is a superset of XML.
The global metadata stream will be created when this function is called. The returned stream is a
preview of the XMP stream that will be stored in the file when CloseFile() or CloseFileEx() is called.
Note that the creation and modification date will be updated when the file is closed (except if the
stream will be modified or replaced with SetMetadata()).
The original global XMP stream of external PDF files can be accessed with GetInMetadata().
Metadata streams are optional and maybe not present. The function returns true if no error occurs,
also if no metadata stream is present. The caller must also check whether the parameter BufSize was
set to a value greater zero to determine whether stream data was returned.
The parameter Buffer is assigned to the original stream buffer, if any. DynaPDF is the owner of this
data. Do not modify or free the returned memory block.
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
Usage (C++):
BYTE* buffer = NULL;
UI32 bufSize = 0;
// Get a preview of the global XMP stream
if (pdfGetMetadata(pdf, mdoCatalog, -1, &buffer, &bufSize))
if (bufSize > 0)
// Do something with the data
UI32* pdfGetMissingGlyphs(
const PPDF* IPDF, // Instance pointer
UI32 ADDR Count)
// Variable that holds the number of missing glyphs
The function returns the character codes that could not be found in the active font. If all characters
were found the return value is NULL.
Each character code is encoded as a 32 bit unsigned integer. The character codes which are stored in
this array correspond to the source string that was used in the function that outputs the text. For
example, if the active font was loaded with a 8 bit code page and if the Ansi version of WriteText()

Previous topic: GetMetaConvFlags, GetMetadata

Next topic: GetMiterLimit, GetMovieAction