DynaPDF Manual - Page 156

Previous Page 155   Index   Next Page 157

Function Reference
Page 156 of 787
The parameter UseAutoTemplates specifies whether the list of auto templates should be drawn just as
if you would call Append() (see AutoTemplate() for further information).
The page template must be closed like a normal page with EndPage() when finish.
Remarks:
Page templates cannot be added to the document with Adobe's Reader. This functionality requires a
full version of Adobe's Acrobat.
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
BeginPattern
Syntax:
SI32 pdfBeginPattern(
const PPDF* IPDF,
// Instance pointer
TPatternType PatternType, // Pattern type
TTilingType TilingType,
// Tiling type
double Width,
// Cell width
double Height)
// Cell height
typedef enum
{
ptColored,
ptUnColored
}TPatternType;
typedef enum
{
ttConstSpacing,
ttNoDistortion,
ttFastConstSpacing
}TTilingType;
This function creates a new tiling pattern. The graphics state is initialized to its default state when
opening a pattern. See Append() for further information. The parameters Width and Height define
the bounding box of the pattern cell.
Colored Tiling Patterns
Colored tiling patterns can be created like a normal PDF page or template. The only difference is
that the pattern must be enclosed in BeginPattern() and EndPattern() calls. The objects inside the
pattern are drawn in the usual way. After all objects are drawn the pattern must be finished with
EndPattern().
Uncolored Tiling Patterns
Uncolored patterns are also painted in the usual way. That means all object types can be inserted
such as text, vector graphics or images. However, an uncolored tiling pattern must NOT include
any color information. Because of this inserting a color image into an uncolored tiling pattern is not
 

Previous topic: BeginPageTemplate

Next topic: BeginTemplate

Start Chat