From: Stefan Csomor Date: Tue, 1 Jan 2002 09:56:37 +0000 (+0000) Subject: added stipple opaque mask detection X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/2b65eb68b852ee023101f2ed621e0679dfb80306 added stipple opaque mask detection git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@13298 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/mac/brush.cpp b/src/mac/brush.cpp index 36703d2cc7..5c87256763 100644 --- a/src/mac/brush.cpp +++ b/src/mac/brush.cpp @@ -65,8 +65,13 @@ wxBrush::wxBrush(const wxBitmap& stipple) { m_refData = new wxBrushRefData; - M_BRUSHDATA->m_style = wxSTIPPLE; + M_BRUSHDATA->m_colour = *wxBLACK; M_BRUSHDATA->m_stipple = stipple; + + if (M_BRUSHDATA->m_stipple.GetMask()) + M_BRUSHDATA->m_style = wxSTIPPLE_MASK_OPAQUE; + else + M_BRUSHDATA->m_style = wxSTIPPLE; RealizeResource(); } diff --git a/src/mac/carbon/brush.cpp b/src/mac/carbon/brush.cpp index 36703d2cc7..5c87256763 100644 --- a/src/mac/carbon/brush.cpp +++ b/src/mac/carbon/brush.cpp @@ -65,8 +65,13 @@ wxBrush::wxBrush(const wxBitmap& stipple) { m_refData = new wxBrushRefData; - M_BRUSHDATA->m_style = wxSTIPPLE; + M_BRUSHDATA->m_colour = *wxBLACK; M_BRUSHDATA->m_stipple = stipple; + + if (M_BRUSHDATA->m_stipple.GetMask()) + M_BRUSHDATA->m_style = wxSTIPPLE_MASK_OPAQUE; + else + M_BRUSHDATA->m_style = wxSTIPPLE; RealizeResource(); }