ImageEn, unit iexLayers

TIETextLayer.VertMargin

TIETextLayer.VertMargin


Declaration

property VertMargin: Double;


Description

Increase the size of the border shape to the left and right of the text. VertMargin is a percentage value, so 0.10, sets 10% of the top and bottom as spacing.

Note: VertMargin has no effect if the border shape is not visible.

Default: 0


Examples

// Set shape to circular with 10% spacing on all sides (i.e. making ellipse taller and wider)
TIETextLayer( ImageEnView1.CurrentLayer ).BorderShape := iesEllipse;
TIETextLayer( ImageEnView1.CurrentLayer ).HorzMargin := 0.10;
TIETextLayer( ImageEnView1.CurrentLayer ).VertMargin := 0.10;
ImageEnView1.Update();

// 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 ).BorderShape  := iesExplosion;
TIETextLayer( ImageEnView1.CurrentLayer ).BorderColor  := clBlack;
TIETextLayer( ImageEnView1.CurrentLayer ).BorderWidth  := 1;
TIETextLayer( ImageEnView1.CurrentLayer ).FillColor    := clRed;
TIETextLayer( ImageEnView1.CurrentLayer ).FillColor2   := clYellow;
TIETextLayer( ImageEnView1.CurrentLayer ).FillGradient := gpgVertCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).Alignment    := iejCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).Layout       := ielCenter;
TIETextLayer( ImageEnView1.CurrentLayer ).HorzMargin   := 0.15;
TIETextLayer( ImageEnView1.CurrentLayer ).VertMargin   := 0.25;
TIETextLayer( ImageEnView1.CurrentLayer ).SizeToText();
ImageEnView1.Update();




See Also

HorzMargin
TextOffsetY
AutoSize