]> git.saurik.com Git - wxWidgets.git/blob - include/wx/mgl/brush.h
include wx/defs.h to get wxSTRINGIZE
[wxWidgets.git] / include / wx / mgl / brush.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/mgl/brush.h
3 // Purpose:
4 // Author: Vaclav Slavik
5 // Id: $Id$
6 // Copyright: (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
9
10 #ifndef __WX_BRUSH_H__
11 #define __WX_BRUSH_H__
12
13 #include "wx/defs.h"
14 #include "wx/object.h"
15 #include "wx/string.h"
16 #include "wx/gdiobj.h"
17 #include "wx/bitmap.h"
18
19 //-----------------------------------------------------------------------------
20 // classes
21 //-----------------------------------------------------------------------------
22
23 class WXDLLEXPORT wxBitmap;
24 class WXDLLEXPORT wxBrush;
25
26 //-----------------------------------------------------------------------------
27 // wxBrush
28 //-----------------------------------------------------------------------------
29
30 class WXDLLEXPORT wxBrush: public wxBrushBase
31 {
32 public:
33 wxBrush() {}
34 wxBrush(const wxColour &colour, int style = wxSOLID);
35 wxBrush(const wxBitmap &stippleBitmap);
36 virtual ~wxBrush() {}
37 bool operator == (const wxBrush& brush) const;
38 bool operator != (const wxBrush& brush) const;
39 bool Ok() const;
40
41 virtual int GetStyle() const;
42 wxColour &GetColour() const;
43 wxBitmap *GetStipple() const;
44
45 void SetColour(const wxColour& col);
46 void SetColour(unsigned char r, unsigned char g, unsigned char b);
47 void SetStyle(int style);
48 void SetStipple(const wxBitmap& stipple);
49
50 // implementation:
51
52 void* GetMaskPattern() const;
53 void* GetPixPattern() const;
54
55 protected:
56 // ref counting code
57 virtual wxObjectRefData *CreateRefData() const;
58 virtual wxObjectRefData *CloneRefData(const wxObjectRefData *data) const;
59
60 private:
61 DECLARE_DYNAMIC_CLASS(wxBrush)
62 };
63
64 #endif // __WX_BRUSH_H__