ImageEn, unit iexUserInteractions

TIEUserInteraction


Declaration

TIEUserInteraction = class;


Description

Ancestor class of interactive tools of TImageEnView.
Descendent Property MouseInteractGeneral/MouseInteractLayers
TIEBrushToolInteraction BrushTool miBrushTool
TIERetouchToolInteraction RetouchTool miRetouchTool
TIECloneToolInteraction CloneTool miCloneTool
TIECropToolInteraction CropTool miCropTool
TIEFillToolInteraction FillTool miColorFill, miAlphaFill, miColorPicker
TIELayerCreateInteraction Not Exposed mlCreateImageLayers, mlCreateShapeLayers, mlCreateLineLayers, mlCreatePolylineLayers, mlCreateAngleLayers, mlCreateTextLayers
TIELayerPointsInteraction Not Exposed mlClickCreateLineLayers, mlClickCreatePolylineLayers, mlDrawCreatePolylineLayers, mlClickCreateAngleLayers, mlEditLayerPoints
TIEPdfViewer PdfViewer N/A
TIERotateToolInteraction RotateTool miRotateTool
TIEButtonInteraction ShowButtons N/A
TIETransformToolInteraction TransformTool miTransformTool

You can also create your own descendents of TIEUserInteraction to provide custom user functionality to TImageEnView.


Demos

Demo  Demos\Other\CustomUserInteraction_Compare\UserInteraction.dpr
Demo  Demos\Other\CustomUserInteraction_Stamping\UserInteraction.dpr
Demo  Demos\ImageEditing\CloneTool\CloneBrush.dpr
Demo  Demos\ImageEditing\FillTool\FillTool.dpr
Demo  Demos\ImageEditing\BrushTool\PaintBrush.dpr
Demo  Demos\PDF\PDFViewer\PdfViewer.dpr
Demo  Demos\ImageEditing\RetouchTool\RetouchTool.dpr
Demo  Demos\ImageEditing\RotateTool\RotateTool.dpr
Demo  Demos\ImageEditing\WarpBrush\WarpBrush.dpr
Demo  Demos\Multi\MViewPreview\MViewPreview.dpr


Example

// Add a custom User Interaction to TImageEnView
// From the demo: Demos\Other\CustomUserInteraction\UserInteraction.dpr

type
  THeartStampInteraction = class(TIEUserInteraction)
  private
  public
    constructor Create(Parent: TIEView);
    destructor Destroy(); override;

    function MouseDownExclusive(Button: TMouseButton; Shift: TShiftState; X, Y: Integer): boolean; override;
    function MouseMoveExclusive(Shift: TShiftState; X, Y: Integer; Captured: boolean): boolean; override;
    function MouseUpExclusive(Button: TMouseButton; Shift: TShiftState; X, Y: Integer): boolean; override;
  end;

// Create our Heart Stamp UI tool and add to the ImageEnView
fHeartStampInteraction := THeartStampInteraction.Create( ImageEnView1 );
ImageEnView1.UserInteractions.Add( fHeartStampInteraction );
fHeartStampInteraction.Enabled := true;


See Also

ImageEn Interactive Tools
MouseInteractGeneral
MouseInteractLayers
OnUserInteraction