TIEPDFBuilder.AddPageWithLayers
Declaration
function AddPageWithLayers(LayersList: TList; IOParams: TIOParams; InsertIndex: Integer = -1): integer;
function AddPageWithLayers(LayersList: TList; IOParams: TIOParams; var Progress: TProgressRec; InsertIndex: Integer = -1): integer; overload;
function AddPageWithLayers(LayersList: TList; PageWidth, PageHeight: Integer; PageVertMargin, PageHorzMargin: Integer; var Progress: TProgressRec; InsertIndex: Integer = -1): integer; overload;
Description
Adds a new page and fills it with all the
layers of a TImageEnView.
You should pass
TImageEnView.LayersList to the method.
The size of the page will be specified by
PDF_PaperWidth and
PDF_PaperHeight. Margins are specified by
PDF_PageMargin.
IOParams will also be used to set image saving format, e.g. via
PDF_Compression.
If InsertIndex > -1, the new page will be inserted at the specified page index of the document. If -1, it will be appended to the end of the document.
Result will be the index of the new page (which will be the same as
CurrentPageIndex | Demos\PDF\PDFBuilder2\PDFBuilder2.dpr |
// Add using "US Letter" paper size
ImageEnView1.IO.Params.PDF_PaperSize := iepLetter;
pdf.AddPageWithLayers( ImageEnView1.LayersList, ImageEnView1.IO.Params );
// Which is the same as...
ImageEnView1.IO.Params.PDF_PaperWidth := 612;
ImageEnView1.IO.Params.PDF_PaperHeight := 792;
pdf.AddPageWithLayers( ImageEnView1.LayersList, ImageEnView1.IO.Params );
See Also
◼AddPage◼AddPageWithImage