FMX.Controls.TTextControl.TextAlign

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property TextAlign: TTextAlign read GetTextAlign write SetTextAlign default TTextAlign.Leading;

C++

__property Fmx::Types::TTextAlign TextAlign = {read=GetTextAlign, write=SetTextAlign, default=1};

Properties

Type Visibility Source Unit Parent
property public
FMX.Controls.pas
FMX.Controls.hpp
FMX.Controls TTextControl

Description

Specifies how the text will be displayed in terms of horizontal alignment.

The TextAlign property specifies how the TTextControl object will display the text in terms of horizontal alignment. TextAlign can have one of the following values (defined in TTextAlign):

  • Center (default)--aligns the text on a horizontal axis, at the middle of the TTextControl object.
  • Leading--aligns the text on a horizontal axis, at the leftmost position inside the TTextControl object.
  • Trailing--aligns the text on a horizontal axis, at the rightmost position inside the TTextControl object.

When you use text representation properties stored in ITextSettings.TextSettings, remember that TextAlign corresponds to HorzAlign.

See Also