Properties · Methods · Demos · Examples
Declaration
TIEImageLayer = class(TIELayer);
Description
TImageEnView supports multiple layers, allowing the creation of a single image from multiple source images (which can be resized, rotated, moved, etc).
TIEImageLayer is a descendent of
TIELayer which contains an image.
You can create image layers with code using
LayersAdd or by user action by setting
MouseInteractLayers to
mlCreateImageLayers.
Review the
Layer Documentation for a full description of layer support.
Demo | Description | Demo Project Folder | Compiled Demo |
Image Layer Editing | Usage of image layers | LayerEditing\Layers_Images\Layers.dpr | |
All Layer Editing | Usage of image, shape, text, polygon and line layers | LayerEditing\Layers_AllTypes\Layers.dpr | |
Stamp Layers | Add text, shapes, images and arrows directly to an image by clicking and dragging | LayerEditing\StampTextAndShapes\StampLayers.dpr | |
// Load an image layer and apply a pink border
ImageEnView1.LayersAdd( ielkImage ); // Append an image layer
ImageEnView1.IO.LoadFromFile('C:\New Zealand.jpg'); // Load image into the new/active layer
ImageEnView1.CurrentLayer.BorderColor := $008000FF;
ImageEnView1.CurrentLayer.BorderWidth := 3;
ImageEnView1.Update();
// Fix the aspect ratio of an image (that has been resized)
if ImageEnView1.CurrentLayer is TIEImageLayer then
ImageEnView1.CurrentLayer.RestoreAspectRatio();
ImageEnView1.Update();
// Allow users to create and edit image layers
ImageEnView1.LayerOptions := ImageEnView1.LayerOptions + [ loAutoPromptForImage ]; // Prompt user to browse for image
ImageEnView1.MouseInteractLayers := [ mlCreateImageLayers, mlMoveLayers, mlResizeLayers ];
GeneralImage AccessStyleSize and Position Unique to TIEImageLayerSee Also
◼Layer Editing Overview◼LayersAdd◼LayersInsert◼TIELayerKind◼MouseInteractLayers