1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxMemoryDC class
4 // Author: Stefan Csomor
8 // Copyright: (c) Stefan Csomor
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_DCMEMORY_H_
13 #define _WX_DCMEMORY_H_
15 #include "wx/osx/dcclient.h"
17 class WXDLLIMPEXP_CORE wxMemoryDCImpl
: public wxPaintDCImpl
20 wxMemoryDCImpl( wxMemoryDC
*owner
);
21 wxMemoryDCImpl( wxMemoryDC
*owner
, wxBitmap
& bitmap
);
22 wxMemoryDCImpl( wxMemoryDC
*owner
, wxDC
*dc
);
24 virtual ~wxMemoryDCImpl();
26 virtual void DoGetSize( int *width
, int *height
) const;
27 virtual wxBitmap
DoGetAsBitmap(const wxRect
*subrect
) const
28 { return subrect
== NULL
? GetSelectedBitmap() : GetSelectedBitmap().GetSubBitmap(*subrect
); }
29 virtual void DoSelect(const wxBitmap
& bitmap
);
31 virtual const wxBitmap
& GetSelectedBitmap() const
32 { return m_selected
; }
33 virtual wxBitmap
& GetSelectedBitmap()
34 { return m_selected
; }
41 DECLARE_CLASS(wxMemoryDCImpl
)
42 DECLARE_NO_COPY_CLASS(wxMemoryDCImpl
)