]> git.saurik.com Git - wxWidgets.git/blob - include/wx/msw/dcclient.h
Unicode fix.
[wxWidgets.git] / include / wx / msw / dcclient.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: dcclient.h
3 // Purpose: wxClientDC class
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 01/02/97
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart and Markus Holzem
9 // Licence: wxWindows license
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_DCCLIENT_H_
13 #define _WX_DCCLIENT_H_
14
15 // ----------------------------------------------------------------------------
16 // headers
17 // ----------------------------------------------------------------------------
18
19 #ifdef __GNUG__
20 #pragma interface "dcclient.h"
21 #endif
22
23 #include "wx/dc.h"
24 #include "wx/dynarray.h"
25
26 // ----------------------------------------------------------------------------
27 // array types
28 // ----------------------------------------------------------------------------
29
30 // this one if used by wxPaintDC only
31 struct WXDLLEXPORT wxPaintDCInfo;
32 WX_DECLARE_OBJARRAY(wxPaintDCInfo, wxArrayDCInfo);
33
34 // ----------------------------------------------------------------------------
35 // DC classes
36 // ----------------------------------------------------------------------------
37
38 class WXDLLEXPORT wxWindowDC : public wxDC
39 {
40 DECLARE_DYNAMIC_CLASS(wxWindowDC)
41
42 public:
43 wxWindowDC();
44
45 // Create a DC corresponding to the whole window
46 wxWindowDC(wxWindow *win);
47
48 virtual ~wxWindowDC();
49 };
50
51 class WXDLLEXPORT wxClientDC : public wxWindowDC
52 {
53 DECLARE_DYNAMIC_CLASS(wxClientDC)
54
55 public:
56 wxClientDC();
57
58 // Create a DC corresponding to the client area of the window
59 wxClientDC(wxWindow *win);
60
61 virtual ~wxClientDC();
62 };
63
64 class WXDLLEXPORT wxPaintDC : public wxWindowDC
65 {
66 DECLARE_DYNAMIC_CLASS(wxPaintDC)
67
68 public:
69 wxPaintDC();
70
71 // Create a DC corresponding for painting the window in OnPaint()
72 wxPaintDC(wxWindow *win);
73
74 virtual ~wxPaintDC();
75
76 protected:
77 static wxArrayDCInfo ms_cache;
78
79 // find the entry for this DC in the cache (keyed by the window)
80 wxPaintDCInfo *FindInCache(size_t *index = NULL) const;
81 };
82
83 #endif
84 // _WX_DCCLIENT_H_