ImageEn, unit imageenview

TImageEnView.CloneTool

TImageEnView.CloneTool


Declaration


property CloneTool: TIECloneToolInteraction;


Description


Provides access to the methods and properties of the TIECloneToolInteraction class, which is used when MouseInteractGeneral is miCloneTool.

The clone tool allows the user to copy content of one part of an image to apply elsewhere, e.g. to erase unwanted content.



The process is as follows:
1. User clicks the image to specify a clone source point
2. User clicks elsewhere on the image to copy the content from the source point to the destination
3. User can continue to click or drag to clone content, which will be copied with the same offset as the cloning in step 2

Note: You can hold the shift key to snap movement to the axes


Demo


  Demos\ImageEditing\CloneTool\CloneBrush.dpr



Example


// Enable Clone mode
ImageEnView1.MouseInteractGeneral := [miCloneTool];

// Cancel Clone tool (same as user clicking "Esc") so user will need to click again to select a clone source
ImageEnView1.CloneTool.Cancel();


See Also


- KeyboardShortcuts