From RAD Studio API Documentation
Jump to: navigation, search


property TextFlags: Longint read FTextFlags write FTextFlags;


__property int TextFlags = {read=FTextFlags, write=FTextFlags, nodefault};


Type Visibility Source Unit Parent
property public
Vcl.Graphics TCustomCanvas


Specifies how text is written to the canvas.

Use TextFlags to influence the way text is drawn when calling the TextOut or TextRect method. TextFlags is an integer made by combining any of the following constants:

Constant Meaning


Only the text that fits within a specified rectangle is displayed. This flag is automatically added when calling the TextRect method. When writing text using the TextOut method, this flag has no effect because the drawing boundaries are determined by the TextExtent property.


The text is drawn with an opaque background color. Using this flag improves performance but does not allow images behind the text rectangle to display.


Text strings are displayed from right to left. This is available only with Mideast versions of Windows, where text is written from right to left. Often this is used in combination with a CanvasOrientation property of coRightToLeft.


The text is an array of character placement codes that are parsed directly by the Windows GDI. Glyph indexing only applies to TrueType fonts, but the flag can be used with other fonts to indicate that the GDI should process the text string directly without language processing. See the Windows GDI documentation for more details.


This is an undocumented Microsoft flag. Check the updates of the Microsoft documentation, where the information will be provided.


All numbers in the text are displayed using digits specific to the current locale.


All numbers in the text are displayed using European digits.


This flag is only relevant when using the Windows API ExtTextOut. When this is set, the array pointed to by lpDx contains pairs of values. The first value of each pair is, as usual, the distance between origins of adjacent character cells, but the second value is the displacement along the vertical direction of the font.

See Also