ImageEn, unit IEVect

TImageEnVect.CopyAllLayersFrom

TImageEnVect.CopyAllLayersFrom


Declaration

procedure CopyAllLayersFrom(Src: TImageEnView; IncludeLayer0: Boolean = True; IncludeImageLayers: Boolean = True);


Description

Reads all of the layers from a TImageEnView and adds them as standard TImageEnVect Vectorial objects.
If IncludeLayer0 is set to false, then the background layer will not be copied.
If IncludeImageLayers is set to false, then image layers will not be copied.

Conversion is as follows:
Layer Kind Converted To Notes
TIEImageLayer iekBITMAP -
TIEShapeLayer iekBOX or iekELLIPSE Only rectangles and ellipses are supported
TIELineLayer iekLINE, iekLINELABEL or iekRULER Circle line end shapes will be converted to arrows
TIEPolylineLayer iekPOLYLINE -
TIEAngleLayer iekANGLE -
TIETextLayer iekTEXT -


Example

// Clone the content of a TImageEnView (with layers) in a TImageEnVect (as Objects)

// Clear existing content
ImageEnVect1.RemoveAllObjects();
ImageEnVect1.ClearAll();

// Copy background image
ImageEnVect1.IEBitmap.Assign( ImageEnView1.Layers[0].Bitmap );

// Add layers as objects
ImageEnVect1.CopyAllLayersFrom( ImageEnView1, False );


See Also

CopyAllObjectsTo