www.gnostice.com 

 

BeginStamp procedure (TgtCustomDocumentEngine)

TgtCustomDocumentEngine

Top 

 

procedure BeginStamp; override;

 

Description

Specify the text and graphic elements that should be drawn on top of the content of each page of the document within a BeginStamp, EndStamp block. You may use stamping to indicate that a particular document is a draft copy by including a text element and setting its text to 'DRAFT'. The BeginStamp, EndStamp block needs to be coded only once for each document regardless of the number of pages it contains. You can code the block immediately after calling BeginDoc. You can also change the stamping from a particular page of a document: just handle the OnAfterBeginPage event and use the CurrentPage property for coding the new stamping at the required page. From that point on in the document all pages will contain the new stamping.

 

Example:

 

Delphi:

 

with gtPDFEngine do

begin

BeginStamp;

//...Set Font and Brush as required

TextOut(3, 4, 'DRAFT');

//...Set image properties as required

DrawImage(0, 0, Image1.Picture.Graphic);

EndStamp;

end;

 

C++Builder:

 

gtPDFEngine1->BeginStamp();

gtPDFEngine1->TextOut(3, 4, "DRAFT");

gtPDFEngine1->DrawImage(0, 0, Image1->Picture->Graphic);

gtPDFEngine1->EndStamp();