Vcl.StdActnMenus.TStandardMenuItem.DrawText

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure DrawText(var Rect: TRect; var Flags: Cardinal; Text: String); override;

C++

virtual void __fastcall DrawText(System::Types::TRect &Rect, unsigned &Flags, System::UnicodeString Text);

Properties

Type Visibility Source Unit Parent
procedure
function
protected
Vcl.StdActnMenus.pas
Vcl.StdActnMenus.hpp
Vcl.StdActnMenus TStandardMenuItem

Description

Draws the menu item's text.

DrawText is called automatically when the menu item needs to render its text.

ARect indicates the rectangle on the menu item's canvas where the text label should appear.

Flags supplies the value to use for the TextFlags property of the canvas.

Text is the text of the menu item.

DrawText checks whether the menu item should display underlines on accelerator keys, and draws the text accordingly, using a font color that reflects whether the menu item is selected and whether it is enabled.

See Also