X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e6f1ad222c5c1597a896dd29e69e1c7aa6459be4..7e256c24fbe8c432b4c122d0fa2b60a59aba94f2:/src/msw/dc.cpp diff --git a/src/msw/dc.cpp b/src/msw/dc.cpp index fa53cd8b6e..d693d7a278 100644 --- a/src/msw/dc.cpp +++ b/src/msw/dc.cpp @@ -638,6 +638,10 @@ void wxDC::DoDrawText(const wxString& text, long x, long y) if (m_textBackgroundColour.Ok()) (void)SetBkColor(GetHdc(), old_background); + // background colour is used only for DrawText, otherwise + // always TRANSPARENT, RR + SetBkMode(GetHdc(), TRANSPARENT); + CalcBoundingBox(x, y); long w, h; @@ -821,10 +825,15 @@ void wxDC::SetBackgroundMode(int mode) { m_backgroundMode = mode; + // SetBackgroundColour now only refers to text background + // and m_backgroundMode is used there + +/* if (m_backgroundMode == wxTRANSPARENT) ::SetBkMode(GetHdc(), TRANSPARENT); else - ::SetBkMode(GetHdc(), OPAQUE); + ::SetBkMode(GetHdc(), OPAQUE); +*/ } void wxDC::SetLogicalFunction(int function)