X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/23324ae1c7938ba904770fc456d3c07764b9c5e9..cde80c9284b64d611e8cf4a7565de40aa0acce81:/interface/dcclient.h?ds=sidebyside diff --git a/interface/dcclient.h b/interface/dcclient.h index d88e6dd62e..17f39ca1a8 100644 --- a/interface/dcclient.h +++ b/interface/dcclient.h @@ -1,6 +1,6 @@ ///////////////////////////////////////////////////////////////////////////// // Name: dcclient.h -// Purpose: documentation for wxPaintDC class +// Purpose: interface of wxClientDC and wxPaintDC // Author: wxWidgets team // RCS-ID: $Id$ // Licence: wxWindows license @@ -9,28 +9,30 @@ /** @class wxPaintDC @wxheader{dcclient.h} - + A wxPaintDC must be constructed if an application wishes to paint on the - client area of a window from within an @b OnPaint event. - This should normally be constructed as a temporary stack object; don't store - a wxPaintDC object. If you have an OnPaint handler, you @e must create a - wxPaintDC - object within it even if you don't actually use it. - - Using wxPaintDC within OnPaint is important because it automatically - sets the clipping area to the damaged area of the window. Attempts to draw - outside this area do not appear. - - To draw on a window from outside @b OnPaint, construct a wxClientDC object. - - To draw on the whole window including decorations, construct a wxWindowDC object - (Windows only). - + client area of a window from within an EVT_PAINT() event handler. This + should normally be constructed as a temporary stack object; don't store a + wxPaintDC object. If you have an EVT_PAINT() handler, you @e must create a + wxPaintDC object within it even if you don't actually use it. + + Using wxPaintDC within your EVT_PAINT() handler is important because it + automatically sets the clipping area to the damaged area of the window. + Attempts to draw outside this area do not appear. + + To draw on a window from outside your EVT_PAINT() handler, construct a + wxClientDC object. + + To draw on the whole window including decorations, construct a wxWindowDC + object (Windows only). + + A wxPaintDC object is initialized to use the same font and colours as the + window it is associated with. + @library{wxcore} @category{dc} - - @seealso - wxDC, wxMemoryDC, wxPaintDC, wxWindowDC, wxScreenDC + + @see wxDC, wxClientDC, wxMemoryDC, wxWindowDC, wxScreenDC */ class wxPaintDC : public wxWindowDC { @@ -42,25 +44,29 @@ public: }; + /** @class wxClientDC @wxheader{dcclient.h} - + A wxClientDC must be constructed if an application wishes to paint on the - client area of a window from outside an @b OnPaint event. - This should normally be constructed as a temporary stack object; don't store - a wxClientDC object. - - To draw on a window from within @b OnPaint, construct a wxPaintDC object. - - To draw on the whole window including decorations, construct a wxWindowDC object - (Windows only). - + client area of a window from outside an EVT_PAINT() handler. This should + normally be constructed as a temporary stack object; don't store a + wxClientDC object. + + To draw on a window from within an EVT_PAINT() handler, construct a + wxPaintDC object instead. + + To draw on the whole window including decorations, construct a wxWindowDC + object (Windows only). + + A wxClientDC object is initialized to use the same font and colours as the + window it is associated with. + @library{wxcore} @category{dc} - - @seealso - wxDC, wxMemoryDC, wxPaintDC, wxWindowDC, wxScreenDC + + @see wxDC, wxMemoryDC, wxPaintDC, wxWindowDC, wxScreenDC */ class wxClientDC : public wxWindowDC { @@ -72,28 +78,28 @@ public: }; + /** @class wxWindowDC @wxheader{dcclient.h} - + A wxWindowDC must be constructed if an application wishes to paint on the - whole area of a window (client and decorations). - This should normally be constructed as a temporary stack object; don't store - a wxWindowDC object. - - To draw on a window from inside @b OnPaint, construct a wxPaintDC object. - - To draw on the client area of a window from outside @b OnPaint, construct a - wxClientDC object. - - To draw on the whole window including decorations, construct a wxWindowDC object - (Windows only). - + whole area of a window (client and decorations). This should normally be + constructed as a temporary stack object; don't store a wxWindowDC object. + + To draw on a window from inside an EVT_PAINT() handler, construct a + wxPaintDC object instead. + + To draw on the client area of a window from outside an EVT_PAINT() handler, + construct a wxClientDC object. + + A wxWindowDC object is initialized to use the same font and colours as the + window it is associated with. + @library{wxcore} @category{dc} - - @seealso - wxDC, wxMemoryDC, wxPaintDC, wxClientDC, wxScreenDC + + @see wxDC, wxMemoryDC, wxPaintDC, wxClientDC, wxScreenDC */ class wxWindowDC : public wxDC { @@ -103,3 +109,4 @@ public: */ wxWindowDC(wxWindow* window); }; +