1998-05-20 14:12:05 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
2002-02-04 01:35:30 +00:00
|
|
|
// Name: wx/msw/brush.h
|
1998-05-20 14:12:05 +00:00
|
|
|
// Purpose: wxBrush class
|
|
|
|
// Author: Julian Smart
|
|
|
|
// Modified by:
|
|
|
|
// Created: 01/02/97
|
1998-08-07 23:52:45 +00:00
|
|
|
// Copyright: (c) Julian Smart
|
2004-05-23 20:53:33 +00:00
|
|
|
// Licence: wxWindows licence
|
1998-05-20 14:12:05 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
1998-08-07 23:52:45 +00:00
|
|
|
#ifndef _WX_BRUSH_H_
|
|
|
|
#define _WX_BRUSH_H_
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2007-07-09 10:09:52 +00:00
|
|
|
class WXDLLIMPEXP_FWD_CORE wxBrush;
|
2008-03-16 17:00:39 +00:00
|
|
|
class WXDLLIMPEXP_FWD_CORE wxColour;
|
|
|
|
class WXDLLIMPEXP_FWD_CORE wxBitmap;
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2002-02-04 01:35:30 +00:00
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
// wxBrush
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
|
2008-03-26 15:06:00 +00:00
|
|
|
class WXDLLIMPEXP_CORE wxBrush : public wxBrushBase
|
1998-05-20 14:12:05 +00:00
|
|
|
{
|
|
|
|
public:
|
2002-02-04 01:35:30 +00:00
|
|
|
wxBrush();
|
2008-03-16 16:47:57 +00:00
|
|
|
wxBrush(const wxColour& col, wxBrushStyle style = wxBRUSHSTYLE_SOLID);
|
2002-02-04 01:35:30 +00:00
|
|
|
wxBrush(const wxBitmap& stipple);
|
|
|
|
virtual ~wxBrush();
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2002-02-04 01:35:30 +00:00
|
|
|
virtual void SetColour(const wxColour& col);
|
2005-10-04 18:14:41 +00:00
|
|
|
virtual void SetColour(unsigned char r, unsigned char g, unsigned char b);
|
2008-03-16 16:47:57 +00:00
|
|
|
virtual void SetStyle(wxBrushStyle style);
|
2002-02-04 01:35:30 +00:00
|
|
|
virtual void SetStipple(const wxBitmap& stipple);
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2002-02-04 01:35:30 +00:00
|
|
|
bool operator==(const wxBrush& brush) const;
|
|
|
|
bool operator!=(const wxBrush& brush) const { return !(*this == brush); }
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2002-02-04 01:35:30 +00:00
|
|
|
wxColour GetColour() const;
|
2008-03-28 16:47:58 +00:00
|
|
|
wxBrushStyle GetStyle() const;
|
2002-02-04 01:35:30 +00:00
|
|
|
wxBitmap *GetStipple() const;
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2014-01-06 12:42:37 +00:00
|
|
|
|
|
|
|
wxDEPRECATED_MSG("use wxBRUSHSTYLE_XXX constants")
|
|
|
|
wxBrush(const wxColour& col, int style);
|
|
|
|
|
|
|
|
wxDEPRECATED_MSG("use wxBRUSHSTYLE_XXX constants")
|
|
|
|
void SetStyle(int style) { SetStyle((wxBrushStyle)style); }
|
2008-06-17 17:28:26 +00:00
|
|
|
|
2002-12-04 14:11:26 +00:00
|
|
|
// return the HBRUSH for this brush
|
|
|
|
virtual WXHANDLE GetResourceHandle() const;
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2002-02-04 01:35:30 +00:00
|
|
|
protected:
|
2007-12-15 17:54:20 +00:00
|
|
|
virtual wxGDIRefData *CreateGDIRefData() const;
|
|
|
|
virtual wxGDIRefData *CloneGDIRefData(const wxGDIRefData *data) const;
|
1998-05-20 14:12:05 +00:00
|
|
|
|
2002-02-04 01:35:30 +00:00
|
|
|
private:
|
2015-04-23 11:49:01 +00:00
|
|
|
wxDECLARE_DYNAMIC_CLASS(wxBrush);
|
1998-05-20 14:12:05 +00:00
|
|
|
};
|
|
|
|
|
2007-12-15 17:54:20 +00:00
|
|
|
#endif // _WX_BRUSH_H_
|