ImageEn, unit iexUserInteractions

TIEPdfViewer.AllowLayers

TIEPdfViewer.AllowLayers


Declaration

property AllowLayers: Boolean;


Description

Enable the use of layers within the PDF Viewer.

Note:
Layers added to a PDF document are not saved unless they are converted to a PDF object
To convert a layer to a PDF object, use AddLayer

Default: False


Demo

Demo  Demos\PDF\PDFPageObjects_FromLayers\PDFPageObjectsLayers.dpr


Example

// Allow user to add layers as objects to a PDF document
ImageEnView1.PdfViewer.Enabled := True;
ImageEnView1.PdfViewer.AllowLayers := True;
ImageEnView1.MouseInteractLayers := [ mlMoveLayers, mlResizeLayers, mlRotateLayers ];

// Also allow selection and editing of objects
ImageEnView1.MouseInteractGeneral := [miPdfSelectObject];
ImageEnView1.PdfViewer.AllowObjectEditing := True;
ImageEnView1.SelColor1 := clRed;
ImageEnView1.SelColor2 := clWhite;

// Remove buttons so they don't interfere with editing
ImageEnView1.PdfViewer.Options := ImageEnView1.PdfViewer.Options - [iepoAutoButtons];

ImageEnView1.IO.LoadFromFilePDF( 'C:\document.pdf' );


See Also

Objects
AddLayer
ApplyChanges
PageModified
MouseInteractGeneral
MouseInteractLayers


Loading contents...