mirror of
https://github.com/TTimo/GtkRadiant.git
synced 2024-11-10 07:11:54 +00:00
* merged r22231 from uforadiant: 'use gtk default font instead of defined ones for linux/windows (which could happen to be not installed)'
git-svn-id: svn://svn.icculus.org/gtkradiant/GtkRadiant/branches/1.5@327 8a3a26a2-13c4-0310-b231-cf6edde360e5
This commit is contained in:
parent
2abefddf8a
commit
0176733736
1 changed files with 6 additions and 5 deletions
|
@ -3311,11 +3311,12 @@ void GlobalGL_sharedContextCreated()
|
||||||
GlobalShaderCache().realise();
|
GlobalShaderCache().realise();
|
||||||
Textures_Realise();
|
Textures_Realise();
|
||||||
|
|
||||||
#ifdef __linux__
|
/* use default font here (Sans 10 is gtk default) */
|
||||||
g_font = glfont_create("fixed 8");
|
GtkSettings *settings = gtk_settings_get_default();
|
||||||
#else
|
gchar *fontname;
|
||||||
g_font = glfont_create("courier 8");
|
g_object_get(settings, "gtk-font-name", &fontname, NULL);
|
||||||
#endif
|
g_font = glfont_create(fontname);
|
||||||
|
|
||||||
GlobalOpenGL().m_font = g_font.getDisplayList();
|
GlobalOpenGL().m_font = g_font.getDisplayList();
|
||||||
GlobalOpenGL().m_fontHeight = g_font.getPixelHeight();
|
GlobalOpenGL().m_fontHeight = g_font.getPixelHeight();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue