]> git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/dcmemory.h
Don't define __STRICT_ANSI__, we should build both with and without it.
[wxWidgets.git] / include / wx / gtk1 / dcmemory.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/gtk1/dcmemory.h
3 // Purpose:
4 // Author: Robert Roebling
5 // Copyright: (c) 1998 Robert Roebling
6 // Licence: wxWindows licence
7 /////////////////////////////////////////////////////////////////////////////
8
9 #ifndef __GTKDCMEMORYH__
10 #define __GTKDCMEMORYH__
11
12 #include "wx/dcmemory.h"
13 #include "wx/gtk1/dcclient.h"
14
15 //-----------------------------------------------------------------------------
16 // classes
17 //-----------------------------------------------------------------------------
18
19 class WXDLLIMPEXP_FWD_CORE wxMemoryDCImpl;
20
21 //-----------------------------------------------------------------------------
22 // wxMemoryDCImpl
23 //-----------------------------------------------------------------------------
24
25 class WXDLLIMPEXP_CORE wxMemoryDCImpl : public wxWindowDCImpl
26 {
27 public:
28 wxMemoryDCImpl(wxMemoryDC *owner)
29 : wxWindowDCImpl(owner)
30 {
31 Init();
32 }
33
34 wxMemoryDCImpl(wxMemoryDC *owner, wxBitmap& bitmap)
35 : wxWindowDCImpl(owner)
36 {
37 Init();
38
39 DoSelect(bitmap);
40 }
41
42 wxMemoryDCImpl(wxMemoryDC *owner, wxDC *dc);
43 virtual ~wxMemoryDCImpl();
44
45 virtual void DoSelect(const wxBitmap& bitmap);
46 virtual void DoGetSize( int *width, int *height ) const;
47
48 // these get reimplemented for mono-bitmaps to behave
49 // more like their Win32 couterparts. They now interpret
50 // wxWHITE, wxWHITE_BRUSH and wxWHITE_PEN as drawing 0
51 // and everything else as drawing 1.
52 virtual void SetPen( const wxPen &pen );
53 virtual void SetBrush( const wxBrush &brush );
54 virtual void SetBackground( const wxBrush &brush );
55 virtual void SetTextForeground( const wxColour &col );
56 virtual void SetTextBackground( const wxColour &col );
57
58 // implementation
59 wxBitmap m_selected;
60
61 private:
62 void Init();
63
64 DECLARE_DYNAMIC_CLASS(wxMemoryDCImpl)
65 };
66
67 #endif // __GTKDCMEMORYH__
68