DynaPDF Manual - Page 455

Previous Page 454   Index   Next Page 456

Function Reference
Page 455 of 860
The PDF file must be opened with OpenImportFile() or OpenImportBuffer() before this function can
be called.
Return values:
If the function succeeds it returns 0 or 1 depending on whether the file contains an XFA form. If the
function fails the return value is a negative error code.
GetInkList
Syntax:
LBOOL pdfGetInkList(
const ILST* List, // List pointer returned by GetAnnotEx()
float** Points,
// Address of a float* variable
UI32* Count)
// Address of a UI32 variable
The function returns a path or ink list of an Ink annotation. The array contains x/y coordinate pairs
(measured in bottom up coordinate system). The array length should be even but odd values can
occur if the annotation was imported from a malformed document.
The points of an ink list are usually drawn with bezier curves to achieve a smooth transition
between points.
Example (C++):
float* points = NULL;
TPDFAnnotationEx annot;
UI32 i, j, numAnnots, count = 0;
pdfEditPage(pdf, 1);
numAnnots = pdfGetPageAnnotCount(pdf);
for (i = 0; i < numAnnots; i++)
{
if (pdfGetPageAnnotEx(pdf, i, annot))
{
if (annot.Type == atInk)
{
for (j = 0; j < annot.InkListCount; j++)
{
if (pdfGetInkList(annot.InkList[j], &points, &count))
{
// Do something with the path
}
}
}
}
}
pdfEndPage(pdf);
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
 

Previous topic: GetInIsTaggedPDF, GetInIsTrapped, GetInIsXFAForm

Next topic: GetInMetadata, GetInNamedDest (obsolete)