1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Vaclav Slavik
6 // Copyright: (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
10 #ifndef __WX_DCMEMORY_H__
11 #define __WX_DCMEMORY_H__
14 #include "wx/dcclient.h"
16 //-----------------------------------------------------------------------------
18 //-----------------------------------------------------------------------------
20 class WXDLLIMPEXP_FWD_CORE wxMemoryDC
;
22 //-----------------------------------------------------------------------------
24 //-----------------------------------------------------------------------------
26 class WXDLLIMPEXP_CORE wxMemoryDC
: public wxDC
, public wxMemoryDCBase
29 wxMemoryDC() { Init(); }
30 wxMemoryDC(wxBitmap
& bitmap
) { Init(); SelectObject(bitmap
); }
31 wxMemoryDC(wxDC
*dc
); // Create compatible DC
32 virtual ~wxMemoryDC();
34 // these get reimplemented for mono-bitmaps to behave
35 // more like their Win32 couterparts. They now interpret
36 // wxWHITE, wxWHITE_BRUSH and wxWHITE_PEN as drawing 0
37 // and everything else as drawing 1.
38 virtual void SetPen(const wxPen
&pen
);
39 virtual void SetBrush(const wxBrush
&brush
);
40 virtual void SetTextForeground(const wxColour
&col
);
41 virtual void SetTextBackground(const wxColour
&col
);
46 wxBitmap
GetSelectedObject() const { return m_selected
; }
49 virtual void DoSelect(const wxBitmap
& bitmap
);
54 DECLARE_DYNAMIC_CLASS(wxMemoryDC
)