Sign in Join
Wiki copytemporary

TGraphicControl: what changed

Revision 0 to 1. Removed lines have a minus sign; added lines have a plus sign.

Title: TGraphicControl

OldNewLine
1+**TGraphicControl** is a base class for lightweight components like [[TBevel]].
2+
3+It supports simple lightweight controls that do not need the ability to accept keyboard input or contain other controls.
4+
5+Since lightweight controls do not wrap GUI widgets, they use fewer resources than controls based on TWinControl.
6+
7+TGraphicControl provides a Canvas property for access to the control's drawing surface and a virtual Paint method and an OnPaint handler, called in response to paint requests received by the parent control.
8+
9+Override the Paint method or supply your own OnPaint handler, to do the actual drawing of the control.
10+
11+If you want to accept keyboard input, or need to support child controls, use a [[TCustomControl]] instead.
12+
13+Most important members:
14+
15+- [[procedure Paint]];
16+- [[property OnPaint]]: [[TNotifyEvent]];
17+- [[property Canvas]]: [[TCanvas]];
18+
19+## See also
20+
21+- [[doc:lcl/controls/tgraphiccontrol.html|TGraphicControl doc]]
22+
23+---
24+*From the Free Pascal wiki, page "TGraphicControl", as it stood on 2019-12-30 after a change by Trev, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).*

Back to history