Unit 'ComCtrls' Package
[Overview][Constants][Types][Classes][Procedures and functions][Index] [#lcl]

TTabControl.Paint

Paints the control to its Canvas using theme services.

Declaration

Source position: comctrls.pp line 842

protected procedure TTabControl.Paint; virtual;

Description

Paint is a method used to render the tab control to its canvas. It handles the background and tabs for the control excluding any button decorations. Buttons are handled in a differ component. Paint adjusts the display rectangle in ARect to reserved a single pixel on the edge indicated in the TabPosition property. This avoids drawing a border on the edge where the control is aligned.

Paint uses ThemeServices to get theme elements available for a tab control, and to draw the control to its Canvas using the theme details. A raised 3D frame is drawn around the control. At design-time, the Caption for the control is drawn centered in its display area.

See also

TTabControl.TabPosition

  

TabPosition - top, bottom, left or right.

TControl.Caption

  

The text displayed for the control.