| OnCalcPageNr Event |
Applies to
TWPRichText
Declaration
TWPOnCalcPageNr = Procedure(Sender: TWPRTFEnginePaint; TextObject: TWPTextObj; RTFPageNr, PaintPageNr: Integer; var PrintedPageNr: Integer) of object;
Description
This event can be used to overwrite the page numbers which are internally calculated. You can check for the name of the TextObject. It can have the following values: PAGE, NUMPAGES, NEXTPAGE, PRIORPAGE and SECTIONPAGES. The passed RTFPageNr is 0 based. The passed PaintPageNr can be -1 if the event is not executed from painting code, othewise it is the 0 based number of the current page page (see ExternalPages demo).
Note, if the var PrintedPageNr is set to 0 nothing will be printed!
|
Copyright (C) by WP |