X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6c155d33875eb3641bf845fbac186c1b5470708e..93210c68cb8ad36a5b2d7f07e93735041657c534:/contrib/src/ogl/basic.cpp?ds=sidebyside diff --git a/contrib/src/ogl/basic.cpp b/contrib/src/ogl/basic.cpp index 3a7abc3fa1..f5f513f798 100644 --- a/contrib/src/ogl/basic.cpp +++ b/contrib/src/ogl/basic.cpp @@ -276,7 +276,7 @@ wxShape::wxShape(wxShapeCanvas *can) m_pen = g_oglBlackPen; m_brush = wxWHITE_BRUSH; m_font = g_oglNormalFont; - m_textColour = wxBLACK; + m_textColour = wxT("BLACK"); m_textColourName = wxT("BLACK"); m_visible = FALSE; m_selected = FALSE; @@ -753,8 +753,7 @@ int wxShape::GetFormatMode(int regionId) const void wxShape::SetTextColour(const wxString& the_colour, int regionId) { - wxColour *wxcolour = wxTheColourDatabase->FindColour(the_colour); - m_textColour = wxcolour; + m_textColour = wxTheColourDatabase->Find(the_colour); m_textColourName = the_colour; wxNode *node = m_regions.Item(regionId); @@ -920,7 +919,7 @@ void wxShape::OnDrawContents(wxDC& dc) wxShapeRegion *region = (wxShapeRegion *)m_regions.GetFirst()->GetData(); if (region->GetFont()) dc.SetFont(* region->GetFont()); - dc.SetTextForeground(* (region->GetActualColourObject())); + dc.SetTextForeground(region->GetActualColourObject()); dc.SetBackgroundMode(wxTRANSPARENT); if (!m_formatted) {