]>
git.saurik.com Git - wxWidgets.git/blob - interface/wx/dcclient.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: interface of wxClientDC and wxPaintDC
4 // Author: wxWidgets team
5 // Licence: wxWindows licence
6 /////////////////////////////////////////////////////////////////////////////
11 A wxPaintDC must be constructed if an application wishes to paint on the
12 client area of a window from within an EVT_PAINT() event handler. This
13 should normally be constructed as a temporary stack object; don't store a
14 wxPaintDC object. If you have an EVT_PAINT() handler, you @e must create a
15 wxPaintDC object within it even if you don't actually use it.
17 Using wxPaintDC within your EVT_PAINT() handler is important because it
18 automatically sets the clipping area to the damaged area of the window.
19 Attempts to draw outside this area do not appear.
21 To draw on a window from outside your EVT_PAINT() handler, construct a
24 To draw on the whole window including decorations, construct a wxWindowDC
25 object (Windows only).
27 A wxPaintDC object is initialized to use the same font and colours as the
28 window it is associated with.
33 @see wxDC, wxClientDC, wxMemoryDC, wxWindowDC, wxScreenDC
35 class wxPaintDC
: public wxClientDC
39 Constructor. Pass a pointer to the window on which you wish to paint.
41 wxPaintDC(wxWindow
* window
);
49 A wxClientDC must be constructed if an application wishes to paint on the
50 client area of a window from outside an EVT_PAINT() handler. This should
51 normally be constructed as a temporary stack object; don't store a
54 To draw on a window from within an EVT_PAINT() handler, construct a
55 wxPaintDC object instead.
57 To draw on the whole window including decorations, construct a wxWindowDC
58 object (Windows only).
60 A wxClientDC object is initialized to use the same font and colours as the
61 window it is associated with.
66 @see wxDC, wxMemoryDC, wxPaintDC, wxWindowDC, wxScreenDC
68 class wxClientDC
: public wxWindowDC
72 Constructor. Pass a pointer to the window on which you wish to paint.
74 wxClientDC(wxWindow
* window
);
82 A wxWindowDC must be constructed if an application wishes to paint on the
83 whole area of a window (client and decorations). This should normally be
84 constructed as a temporary stack object; don't store a wxWindowDC object.
86 To draw on a window from inside an EVT_PAINT() handler, construct a
87 wxPaintDC object instead.
89 To draw on the client area of a window from outside an EVT_PAINT() handler,
90 construct a wxClientDC object.
92 A wxWindowDC object is initialized to use the same font and colours as the
93 window it is associated with.
98 @see wxDC, wxMemoryDC, wxPaintDC, wxClientDC, wxScreenDC
100 class wxWindowDC
: public wxDC
104 Constructor. Pass a pointer to the window on which you wish to paint.
106 wxWindowDC(wxWindow
* window
);