Vcl.Themes.TCustomStyleServices.GetTextExtent

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function GetTextExtent(DC: HDC; Details: TThemedElementDetails; const Text: string;
Flags: TTextFormat; out ExtentRect: TRect): Boolean; overload;
function GetTextExtent(DC: HDC; Details: TThemedElementDetails; const Text: string;
Flags: TTextFormat; const BoundingRect: TRect; out ExtentRect: TRect): Boolean; overload;

C++

bool __fastcall GetTextExtent(HDC DC, const TThemedElementDetails &Details, const System::UnicodeString Text, Vcl::Graphics::TTextFormat Flags, /* out */ System::Types::TRect &ExtentRect)/* overload */;
bool __fastcall GetTextExtent(HDC DC, const TThemedElementDetails &Details, const System::UnicodeString Text, Vcl::Graphics::TTextFormat Flags, const System::Types::TRect &BoundingRect, /* out */ System::Types::TRect &ExtentRect)/* overload */;

Properties

Type Visibility Source Unit Parent
function public
Vcl.Themes.pas
Vcl.Themes.hpp
Vcl.Themes TCustomStyleServices

Description

Returns the rectangle that contains the given text, drawn in the current style.

Call GetTextExtent to obtain the rectangle required to draw the given text with the specified formatting in the current style.

See Also