2008-03-08 13:52:38 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: brush.h
|
2008-03-10 15:24:38 +00:00
|
|
|
// Purpose: interface of wxBrush
|
2008-03-08 13:52:38 +00:00
|
|
|
// Author: wxWidgets team
|
2010-07-13 13:29:13 +00:00
|
|
|
// Licence: wxWindows licence
|
2008-03-08 13:52:38 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
2008-03-17 00:47:38 +00:00
|
|
|
/**
|
|
|
|
The possible brush styles.
|
|
|
|
*/
|
|
|
|
enum wxBrushStyle
|
|
|
|
{
|
2008-03-25 22:06:48 +00:00
|
|
|
wxBRUSHSTYLE_INVALID = -1,
|
|
|
|
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBRUSHSTYLE_SOLID = wxSOLID,
|
|
|
|
/**< Solid. */
|
|
|
|
|
|
|
|
wxBRUSHSTYLE_TRANSPARENT = wxTRANSPARENT,
|
|
|
|
/**< Transparent (no fill). */
|
|
|
|
|
|
|
|
wxBRUSHSTYLE_STIPPLE_MASK_OPAQUE = wxSTIPPLE_MASK_OPAQUE,
|
2009-02-04 16:49:32 +00:00
|
|
|
/**< Uses a bitmap as a stipple; the mask is used for blitting monochrome
|
|
|
|
using text foreground and background colors. */
|
2008-03-17 00:47:38 +00:00
|
|
|
|
|
|
|
wxBRUSHSTYLE_STIPPLE_MASK = wxSTIPPLE_MASK,
|
2009-02-04 16:49:32 +00:00
|
|
|
/**< Uses a bitmap as a stipple; mask is used for masking areas in the
|
|
|
|
stipple bitmap. */
|
2008-03-17 00:47:38 +00:00
|
|
|
|
|
|
|
wxBRUSHSTYLE_STIPPLE = wxSTIPPLE,
|
|
|
|
/**< Uses a bitmap as a stipple. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_BDIAGONAL_HATCH,
|
2008-03-17 00:47:38 +00:00
|
|
|
/**< Backward diagonal hatch. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_CROSSDIAG_HATCH,
|
2008-03-17 00:47:38 +00:00
|
|
|
/**< Cross-diagonal hatch. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_FDIAGONAL_HATCH,
|
2008-03-17 00:47:38 +00:00
|
|
|
/**< Forward diagonal hatch. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_CROSS_HATCH,
|
2008-03-17 00:47:38 +00:00
|
|
|
/**< Cross hatch. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_HORIZONTAL_HATCH,
|
2008-03-17 00:47:38 +00:00
|
|
|
/**< Horizontal hatch. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_VERTICAL_HATCH,
|
2008-03-17 00:47:38 +00:00
|
|
|
/**< Vertical hatch. */
|
|
|
|
|
2012-06-30 23:41:15 +00:00
|
|
|
wxBRUSHSTYLE_FIRST_HATCH,
|
|
|
|
/**< First of the hatch styles (inclusive). */
|
|
|
|
|
|
|
|
wxBRUSHSTYLE_LAST_HATCH
|
|
|
|
/**< Last of the hatch styles (inclusive). */
|
2008-03-17 00:47:38 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-03-08 13:52:38 +00:00
|
|
|
/**
|
|
|
|
@class wxBrush
|
2008-03-08 14:43:31 +00:00
|
|
|
|
2008-03-08 13:52:38 +00:00
|
|
|
A brush is a drawing tool for filling in areas. It is used for painting
|
2008-03-17 00:47:38 +00:00
|
|
|
the background of rectangles, ellipses, etc. It has a colour and a style.
|
|
|
|
|
|
|
|
On a monochrome display, wxWidgets shows all brushes as white unless the
|
|
|
|
colour is really black.
|
|
|
|
|
|
|
|
Do not initialize objects on the stack before the program commences, since
|
|
|
|
other required structures may not have been set up yet. Instead, define
|
|
|
|
global pointers to objects and create them in wxApp::OnInit or when required.
|
|
|
|
|
|
|
|
An application may wish to create brushes with different characteristics
|
|
|
|
dynamically, and there is the consequent danger that a large number of
|
|
|
|
duplicate brushes will be created. Therefore an application may wish to
|
|
|
|
get a pointer to a brush by using the global list of brushes ::wxTheBrushList,
|
|
|
|
and calling the member function wxBrushList::FindOrCreateBrush().
|
|
|
|
|
|
|
|
This class uses reference counting and copy-on-write internally so that
|
|
|
|
assignments between two instances of this class are very cheap.
|
|
|
|
You can therefore use actual objects instead of pointers without efficiency problems.
|
|
|
|
If an instance of this class is changed it will create its own data internally
|
|
|
|
so that other instances, which previously shared the data using the reference
|
|
|
|
counting, are not affected.
|
2008-03-08 14:43:31 +00:00
|
|
|
|
2008-03-08 13:52:38 +00:00
|
|
|
@library{wxcore}
|
|
|
|
@category{gdi}
|
2008-03-08 14:43:31 +00:00
|
|
|
|
2008-03-08 13:52:38 +00:00
|
|
|
@stdobjects
|
2009-02-04 16:30:27 +00:00
|
|
|
@li ::wxNullBrush
|
|
|
|
@li ::wxBLACK_BRUSH
|
|
|
|
@li ::wxBLUE_BRUSH
|
|
|
|
@li ::wxCYAN_BRUSH
|
|
|
|
@li ::wxGREEN_BRUSH
|
2009-05-09 12:40:09 +00:00
|
|
|
@li ::wxYELLOW_BRUSH
|
2009-02-04 16:30:27 +00:00
|
|
|
@li ::wxGREY_BRUSH
|
|
|
|
@li ::wxLIGHT_GREY_BRUSH
|
|
|
|
@li ::wxMEDIUM_GREY_BRUSH
|
|
|
|
@li ::wxRED_BRUSH
|
|
|
|
@li ::wxTRANSPARENT_BRUSH
|
|
|
|
@li ::wxWHITE_BRUSH
|
2008-03-08 14:43:31 +00:00
|
|
|
|
2008-03-10 15:24:38 +00:00
|
|
|
@see wxBrushList, wxDC, wxDC::SetBrush
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
|
|
|
class wxBrush : public wxGDIObject
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Default constructor.
|
|
|
|
The brush will be uninitialised, and wxBrush:IsOk() will return @false.
|
|
|
|
*/
|
|
|
|
wxBrush();
|
|
|
|
|
|
|
|
/**
|
|
|
|
Constructs a brush from a colour object and @a style.
|
|
|
|
|
2008-03-08 14:43:31 +00:00
|
|
|
@param colour
|
2008-03-09 12:33:59 +00:00
|
|
|
Colour object.
|
2008-03-17 00:47:38 +00:00
|
|
|
@param style
|
|
|
|
One of the ::wxBrushStyle enumeration values.
|
|
|
|
*/
|
2008-03-25 22:06:48 +00:00
|
|
|
wxBrush(const wxColour& colour, wxBrushStyle style = wxBRUSHSTYLE_SOLID);
|
2008-03-17 00:47:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Constructs a stippled brush using a bitmap.
|
2009-02-04 16:49:32 +00:00
|
|
|
The brush style will be set to @c wxBRUSHSTYLE_STIPPLE.
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-08 14:43:31 +00:00
|
|
|
wxBrush(const wxBitmap& stippleBitmap);
|
2008-03-17 00:47:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Copy constructor, uses @ref overview_refcount "reference counting".
|
|
|
|
*/
|
2008-03-08 14:43:31 +00:00
|
|
|
wxBrush(const wxBrush& brush);
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Destructor.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
|
|
|
See @ref overview_refcount_destruct for more info.
|
|
|
|
|
2008-03-08 13:52:38 +00:00
|
|
|
@remarks Although all remaining brushes are deleted when the application
|
2008-03-17 00:47:38 +00:00
|
|
|
exits, the application should try to clean up all brushes itself.
|
|
|
|
This is because wxWidgets cannot know if a pointer to the brush
|
|
|
|
object is stored in an application data structure, and there is
|
|
|
|
a risk of double deletion.
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-24 22:17:25 +00:00
|
|
|
virtual ~wxBrush();
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns a reference to the brush colour.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see SetColour()
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-28 16:47:58 +00:00
|
|
|
virtual wxColour GetColour() const;
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
2009-02-04 16:49:32 +00:00
|
|
|
Gets a pointer to the stipple bitmap. If the brush does not have a @c wxBRUSHSTYLE_STIPPLE
|
2008-03-17 00:47:38 +00:00
|
|
|
style, this bitmap may be non-@NULL but uninitialised (i.e. wxBitmap:IsOk() returns @false).
|
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see SetStipple()
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-28 16:47:58 +00:00
|
|
|
virtual wxBitmap* GetStipple() const;
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Returns the brush style, one of the ::wxBrushStyle values.
|
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see SetStyle(), SetColour(), SetStipple()
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-25 22:06:48 +00:00
|
|
|
virtual wxBrushStyle GetStyle() const;
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns @true if the style of the brush is any of hatched fills.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see GetStyle()
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-24 22:17:25 +00:00
|
|
|
virtual bool IsHatch() const;
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
2010-10-15 23:46:46 +00:00
|
|
|
Returns @true if the brush is initialised.
|
|
|
|
|
|
|
|
Notice that an uninitialized brush object can't be queried for any
|
|
|
|
brush properties and all calls to the accessor methods on it will
|
|
|
|
result in an assert failure.
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-10-13 11:09:56 +00:00
|
|
|
virtual bool IsOk() const;
|
2008-03-08 13:52:38 +00:00
|
|
|
|
2010-10-15 23:46:46 +00:00
|
|
|
/**
|
|
|
|
Returns @true if the brush is a valid non-transparent brush.
|
|
|
|
|
|
|
|
This method returns @true if the brush object is initialized and has a
|
|
|
|
non-transparent style. Notice that this should be used instead of
|
|
|
|
simply testing whether GetStyle() returns a style different from
|
|
|
|
wxBRUSHSTYLE_TRANSPARENT if the brush may be invalid as GetStyle()
|
|
|
|
would assert in this case.
|
|
|
|
|
|
|
|
@see IsTransparent()
|
|
|
|
|
|
|
|
@since 2.9.2.
|
|
|
|
*/
|
|
|
|
bool IsNonTransparent() const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
Returns @true if the brush is transparent.
|
|
|
|
|
|
|
|
A transparent brush is simply a brush with wxBRUSHSTYLE_TRANSPARENT
|
|
|
|
style.
|
|
|
|
|
2011-04-03 20:31:32 +00:00
|
|
|
Notice that this function works even for non-initialized brushes (for
|
2010-10-15 23:46:46 +00:00
|
|
|
which it returns @false) unlike tests of the form <code>GetStyle() ==
|
|
|
|
wxBRUSHSTYLE_TRANSPARENT</code> which would assert if the brush is
|
|
|
|
invalid.
|
|
|
|
|
|
|
|
@see IsNonTransparent()
|
|
|
|
|
|
|
|
@since 2.9.2.
|
|
|
|
*/
|
|
|
|
bool IsTransparent() const;
|
|
|
|
|
|
|
|
|
2008-03-08 13:52:38 +00:00
|
|
|
//@{
|
|
|
|
/**
|
|
|
|
Sets the brush colour using red, green and blue values.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see GetColour()
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2009-01-10 23:44:44 +00:00
|
|
|
virtual void SetColour(const wxColour& colour);
|
2008-03-28 16:47:58 +00:00
|
|
|
virtual void SetColour(unsigned char red, unsigned char green, unsigned char blue);
|
2008-03-08 13:52:38 +00:00
|
|
|
//@}
|
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the stipple bitmap.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2008-03-08 14:43:31 +00:00
|
|
|
@param bitmap
|
2008-03-09 12:33:59 +00:00
|
|
|
The bitmap to use for stippling.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2009-02-04 16:49:32 +00:00
|
|
|
@remarks The style will be set to @c wxBRUSHSTYLE_STIPPLE, unless the bitmap
|
2008-03-17 00:47:38 +00:00
|
|
|
has a mask associated to it, in which case the style will be set
|
2009-02-04 16:49:32 +00:00
|
|
|
to @c wxBRUSHSTYLE_STIPPLE_MASK_OPAQUE.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see wxBitmap
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-28 16:47:58 +00:00
|
|
|
virtual void SetStipple(const wxBitmap& bitmap);
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the brush style.
|
2008-03-17 00:47:38 +00:00
|
|
|
|
2008-03-08 14:43:31 +00:00
|
|
|
@param style
|
2008-03-17 00:47:38 +00:00
|
|
|
One of the ::wxBrushStyle values.
|
|
|
|
|
2008-03-09 12:33:59 +00:00
|
|
|
@see GetStyle()
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-28 16:47:58 +00:00
|
|
|
virtual void SetStyle(wxBrushStyle style);
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Inequality operator.
|
2008-03-17 00:47:38 +00:00
|
|
|
See @ref overview_refcount_equality for more info.
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-25 22:06:48 +00:00
|
|
|
bool operator !=(const wxBrush& brush) const;
|
2008-03-08 13:52:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Equality operator.
|
2008-03-17 00:47:38 +00:00
|
|
|
See @ref overview_refcount_equality for more info.
|
2008-03-08 13:52:38 +00:00
|
|
|
*/
|
2008-03-25 22:06:48 +00:00
|
|
|
bool operator ==(const wxBrush& brush) const;
|
2008-03-08 13:52:38 +00:00
|
|
|
};
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
An empty brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
wxBrush::IsOk() always returns @false for this object.
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
|
|
|
wxBrush wxNullBrush;
|
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Blue brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxBLUE_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Green brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxGREEN_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
2009-05-09 12:40:09 +00:00
|
|
|
/**
|
|
|
|
Yellow brush.
|
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
|
|
|
*/
|
|
|
|
wxBrush* wxYELLOW_BRUSH;
|
|
|
|
|
2008-03-10 15:24:38 +00:00
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
White brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxWHITE_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Black brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxBLACK_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Grey brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxGREY_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Medium grey brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxMEDIUM_GREY_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Light grey brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxLIGHT_GREY_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Transparent brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxTRANSPARENT_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Cyan brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxCYAN_BRUSH;
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
Red brush.
|
2009-02-04 16:49:32 +00:00
|
|
|
Except for the color it has all standard attributes
|
|
|
|
(@c wxBRUSHSTYLE_SOLID, no stipple bitmap, etc...).
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2008-03-17 00:47:38 +00:00
|
|
|
wxBrush* wxRED_BRUSH;
|
|
|
|
|
|
|
|
|
2008-03-10 15:24:38 +00:00
|
|
|
|
|
|
|
/**
|
2008-03-17 00:47:38 +00:00
|
|
|
@class wxBrushList
|
|
|
|
|
|
|
|
A brush list is a list containing all brushes which have been created.
|
|
|
|
|
2008-03-25 22:06:48 +00:00
|
|
|
The application should not construct its own brush list: it should use the
|
|
|
|
object pointer ::wxTheBrushList.
|
|
|
|
|
2008-03-17 00:47:38 +00:00
|
|
|
@library{wxcore}
|
|
|
|
@category{gdi}
|
|
|
|
|
|
|
|
@see wxBrush
|
2008-03-10 15:24:38 +00:00
|
|
|
*/
|
2012-11-09 05:02:52 +00:00
|
|
|
class wxBrushList
|
2008-03-17 00:47:38 +00:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
/**
|
|
|
|
Finds a brush with the specified attributes and returns it, else creates a new
|
|
|
|
brush, adds it to the brush list, and returns it.
|
2008-03-10 15:24:38 +00:00
|
|
|
|
2008-03-17 00:47:38 +00:00
|
|
|
@param colour
|
|
|
|
Colour object.
|
|
|
|
@param style
|
|
|
|
Brush style. See ::wxBrushStyle for a list of styles.
|
|
|
|
*/
|
|
|
|
wxBrush* FindOrCreateBrush(const wxColour& colour,
|
|
|
|
wxBrushStyle style = wxBRUSHSTYLE_SOLID);
|
|
|
|
};
|
|
|
|
|
|
|
|
/**
|
|
|
|
The global wxBrushList instance.
|
|
|
|
*/
|
|
|
|
wxBrushList* wxTheBrushList;
|