fixed endless recursion for loading of default font

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4525 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Karsten Ballüder
1999-11-12 16:31:33 +00:00
parent 23a8562d7a
commit a4bacadeb2

View File

@@ -61,7 +61,17 @@
#elif defined(__WXGTK__)
static inline wxNativeFont wxLoadFont(const wxString& fontSpec)
{
return gdk_font_load( wxConvertWX2MB(fontSpec) );
wxNativeFont font = gdk_font_load( wxConvertWX2MB(fontSpec) );
if(fontSpec == "-*-*-*-*-*-*-*-*-*-*-*-*-*-*")
{
if(font == NULL)
font = gdk_font_load (wxConvertWX2MB("-*-*-*-*-*-*-*-*-75-*-*-*-*-*"));
if(font == NULL)
font = gdk_font_load (wxConvertWX2MB("-*-*-*-*-*-*-*-*-100-*-*-*-*-*"));
if(font == NULL)
font = gdk_font_load (wxConvertWX2MB("-*-fixed-*-*-*-*-*-*-*-*-*-*-*-*"));
}
return font;
}
static inline void wxFreeFont(wxNativeFont font)