int m_currentStyle ;
int m_currentFill ;
int m_autoSetting ; // See comment in dcclient.cpp
+
+ // this is useless and should be removed, kept for now just for backwards
+ // compatibility
+#if wxCHECK_VERSION(2, 7, 0)
+ #error "Remove wxClientDC::m_oldFont"
+#endif
WXFont m_oldFont;
};
m_backgroundPixel = (int) gcvalues.background;
- // Get the current Font so we can set it back later
- XGCValues valReturn;
- XGetGCValues((Display*) m_display, (GC) m_gc, GCFont, &valReturn);
- m_oldFont = (WXFont) valReturn.font;
-
SetBackground(wxBrush(m_window->GetBackgroundColour(), wxSOLID));
}
wxWindowDC::~wxWindowDC()
{
- if (m_gc && m_oldFont)
- {
- XSetFont ((Display*) m_display, (GC) m_gc, (Font) m_oldFont);
-
- if (m_window && m_window->GetBackingPixmap())
- XSetFont ((Display*) m_display,(GC) m_gcBacking, (Font) m_oldFont);
- }
-
if (m_gc)
XFreeGC ((Display*) m_display, (GC) m_gc);
m_gc = (WXGC) 0;
if (!m_font.Ok())
{
- if (m_oldFont)
- {
- XSetFont ((Display*) m_display, (GC) m_gc, (Font) m_oldFont);
-
- if (m_window && m_window->GetBackingPixmap())
- XSetFont ((Display*) m_display,(GC) m_gcBacking, (Font) m_oldFont);
- }
return;
}
m_backgroundPixel = (int) gcvalues.background;
- // Get the current Font so we can set it back later
- XGCValues valReturn;
- XGetGCValues((Display*) m_display, (GC) m_gc, GCFont, &valReturn);
- m_oldFont = (WXFont) valReturn.font;
SetBrush (* wxWHITE_BRUSH);
SetPen (* wxBLACK_PEN);
SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT));
m_backgroundPixel = (int) gcvalues.background;
- // Get the current Font so we can set it back later
- XGCValues valReturn;
- XGetGCValues((Display*) m_display, (GC) m_gc, GCFont, &valReturn);
- m_oldFont = (WXFont) valReturn.font;
SetBrush (* wxWHITE_BRUSH);
SetPen (* wxBLACK_PEN);
};
m_backgroundPixel = (int) gcvalues.background;
m_ok = true;
- // Get the current Font so we can set it back later
- XGCValues valReturn;
- XGetGCValues((Display*) m_display, (GC) m_gc, GCFont, &valReturn);
- m_oldFont = (WXFont) valReturn.font;
-
SetBrush (* wxWHITE_BRUSH);
SetPen (* wxBLACK_PEN);
}