ImageEn, unit iexUserInteractions |
|
TIEBrushToolInteraction.BrushImage
Declaration
property BrushImage: TIEBitmap;
Description
Specifies an image to use as a brush if
BrushFill is
iebfImage.
If
BrushImageSizeLocked = True (Default) then the brush size will be locked to that of the brush image.
Here is an example brush (right-click to save and use it):
Note:
◼You are best to use an image that contains an alpha channel (transparency). PNG files work well
◼You can set
BrushShape to
iecsCircle to automatically round your brush image
// Enable painting with a custom brush
ImageEnView1.BrushTool.BrushImage.Read( 'Golden-Brush.png' );
ImageEnView1.BrushTool.BrushFill := iebfImage;
ImageEnView1.BrushTool.BrushShape := iecsRectangle;
ImageEnView1.MouseInteractGeneral := [ miBrushTool ];
// Enable stamping of a Snow Flake (with a transparent background)
ImageEnView1.BrushTool.BrushImage.Read( 'C:\SnowFlake.png' );
ImageEnView1.BrushTool.BrushFill := iebfImage;
ImageEnView1.BrushTool.BrushShape := iecsRectangle;
ImageEnView1.BrushTool.PaintMode := iepmStamp;
ImageEnView1.MouseInteractGeneral := [ miBrushTool ];
// Use an image as a source brush that can be sized (note cannot be made larger than the source image)
ImageEnView1.BrushTool.BrushImage.Read( 'C:\CustomBrush.png' );
ImageEnView1.BrushTool.BrushFill := iebfImage;
ImageEnView1.BrushTool.BrushImageSizeLocked := False;
ImageEnView1.BrushTool.BrushSize := 10;
ImageEnView1.MouseInteractGeneral := [ miBrushTool ];