RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TCustomControl.PaintWindow Method

Renders the image of the control on a specified device context.

Pascal
procedure PaintWindow(DC: HDC); override;
C++
virtual __fastcall PaintWindow(HDC DC);

PaintWindow is called automatically when a custom control receives a WM_PAINT message. PaintWindow assigns the device context specified by the DC parameter to the custom control's canvas, calls the Paint method, and finally removes the device context. Override PaintWindow to provide additional responses to the WM_PAINT message. To draw the image of the control, override the Paint method instead. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!