void wxGraphicsContext::SetBrush( const wxBrush& brush ) { if ( !brush.Ok() || brush.GetStyle() == wxTRANSPARENT ) SetBrush( wxNullGraphicsBrush ); else SetBrush( CreateBrush( brush ) ); }
bool wxGenericBrush::IsSameAs(const wxBrush& brush) const { wxCHECK_MSG(Ok() && brush.Ok(), 1, wxT("Invalid generic brush")); wxGenericBrush gB(brush); gB.GetGenericColour().SetAlpha(M_GBRUSHDATA->m_colour.GetAlpha()); return IsSameAs(gB); }
void wxDC::SetBackground(const wxBrush& brush) { wxCHECK_RET( Ok(), wxT("invalid dc") ); if (!brush.Ok()) return; m_backgroundBrush = brush; }
void wxGenericBrush::Set( const wxBrush &brush ) { wxCHECK_RET(Ok() && brush.Ok(), wxT("Invalid generic brush")); SetColour(brush.GetColour()); M_GBRUSHDATA->m_style = brush.GetStyle(); wxBitmap* stipple = brush.GetStipple(); if (stipple && stipple->Ok()) M_GBRUSHDATA->m_stipple = *stipple; }
void wxDC::SetBrush(const wxBrush& brush) { m_brush = brush.Ok() ? brush : DEFAULT_BRUSH; }