Declaration
property FillColor: TColor;
Description
Provides generic access to the fill color of the layer. Set to clNone for no fill (i.e. transparent background)
FillColor accesses the following properties:
// Set fill color for a shape to yellow
ImageEnView1.CurrentLayer.FillColor := clYellow;
ImageEnView1.Update();
// Remove fill color from shape
ImageEnView1.CurrentLayer.FillColor := clNone;
ImageEnView1.Update();
// Prompt user to specify a fill color for the current layer
var
aColor: TColor;
begin
aColor := ImageEnView1.CurrentLayer.FillColor;
if IEPromptForColor( aColor ) then
ImageEnView1.CurrentLayer.FillColor := aColor;
ImageEnView1.Update();
end;
// Add a "Shape" layer with margins around text
ImageEnView1.LayersAdd( ielkText );
TIETextLayer( ImageEnView1.CurrentLayer ).Text := 'EXPLOSION!';
TIETextLayer( ImageEnView1.CurrentLayer ).Font.Style := [fsBold];
TIETextLayer( ImageEnView1.CurrentLayer ).Alignment := iejCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).Layout := ielCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).HorzMargin := 0.15;
TIETextLayer( ImageEnView1.CurrentLayer ).VertMargin := 0.25;
ImageEnView1.CurrentLayer.BorderColor := clBlack;
ImageEnView1.CurrentLayer.BorderWidth := 1;
ImageEnView1.CurrentLayer.FillColor := clRed;
ImageEnView1.CurrentLayer.FillColor2 := clYellow;
ImageEnView1.CurrentLayer.FillGradient := gpgVertCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).SizeToText();
ImageEnView1.Update();
// Add a "Shape" layer with vertically offset text
ImageEnView1.LayersAdd( ielkText, 200, 200, 230, 200 );
ImageEnView1.CurrentLayer.AspectRatioLocked := True;
TIETextLayer( ImageEnView1.CurrentLayer ).BorderShape := iesHeart;
TIETextLayer( ImageEnView1.CurrentLayer ).Font.Style := [fsBold];
TIETextLayer( ImageEnView1.CurrentLayer ).Alignment := iejCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).Layout := ielCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).WordWrap := False;
TIETextLayer( ImageEnView1.CurrentLayer ).Text := 'I Heart Delphi';
TIETextLayer( ImageEnView1.CurrentLayer ).Font.Size := 22;
TIETextLayer( ImageEnView1.CurrentLayer ).TextOverflow := ieoShrink;
TIETextLayer( ImageEnView1.CurrentLayer ).TextOffsetY := -0.15;
ImageEnView1.CurrentLayer.BorderWidth := 0;
ImageEnView1.CurrentLayer.FillColor := $004646FF;
ImageEnView1.Update();
See Also
◼TIELayer.FillColor2
◼TIELayer.FillGradient
◼TIELayer.FillOpacity