]> git.saurik.com Git - wxWidgets.git/blame_incremental - include/wx/x11/brush.h
Updated Scintilla to 1.52 (on the trunk this time too)
[wxWidgets.git] / include / wx / x11 / brush.h
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: brush.h
3// Purpose: wxBrush class
4// Author: Julian Smart, Robert Roebling
5// Modified by:
6// Created: 17/09/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart, Robert Roebling
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_BRUSH_H_
13#define _WX_BRUSH_H_
14
15#ifdef __GNUG__
16#pragma interface "brush.h"
17#endif
18
19#include "wx/gdiobj.h"
20
21//-----------------------------------------------------------------------------
22// classes
23//-----------------------------------------------------------------------------
24
25class wxBrush;
26class wxColour;
27class wxBitmap;
28
29//-----------------------------------------------------------------------------
30// wxBrush
31//-----------------------------------------------------------------------------
32
33class wxBrush: public wxGDIObject
34{
35public:
36 wxBrush() { }
37
38 wxBrush( const wxColour &colour, int style );
39 wxBrush( const wxBitmap &stippleBitmap );
40 ~wxBrush();
41
42 wxBrush( const wxBrush &brush ) { Ref(brush); }
43 wxBrush& operator = ( const wxBrush& brush ) { Ref(brush); return *this; }
44
45 bool Ok() const { return m_refData != NULL; }
46
47 bool operator == ( const wxBrush& brush ) const;
48 bool operator != (const wxBrush& brush) const { return !(*this == brush); }
49
50 int GetStyle() const;
51 wxColour &GetColour() const;
52 wxBitmap *GetStipple() const;
53
54 void SetColour( const wxColour& col );
55 void SetColour( unsigned char r, unsigned char g, unsigned char b );
56 void SetStyle( int style );
57 void SetStipple( const wxBitmap& stipple );
58
59private:
60 // ref counting code
61 virtual wxObjectRefData *CreateRefData() const;
62 virtual wxObjectRefData *CloneRefData(const wxObjectRefData *data) const;
63
64 DECLARE_DYNAMIC_CLASS(wxBrush)
65};
66
67#endif
68// _WX_BRUSH_H_