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