From: Rudolf Polzer Date: Thu, 9 Dec 2010 05:54:14 +0000 (+0100) Subject: add an ifdeffed out font size workaround X-Git-Tag: xonotic-v0.5.0~133 X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fnetradiant.git;a=commitdiff_plain;h=d792d26da85801ac85c6f70059c3b6bab17ee57c;ds=sidebyside add an ifdeffed out font size workaround --- diff --git a/libs/gtkutil/glfont.cpp b/libs/gtkutil/glfont.cpp index bd514a7f..a3eac91d 100644 --- a/libs/gtkutil/glfont.cpp +++ b/libs/gtkutil/glfont.cpp @@ -220,6 +220,12 @@ class GLFontInternal: public GLFont // TODO fallback to fixed 8, courier new 8 layout = pango_layout_new(ft2_context); + +#ifdef FONT_SIZE_WORKAROUND + pango_layout_set_width(layout, -1); // -1 no wrapping. All text on one line. + pango_layout_set_text(layout, "The quick brown fox jumped over the lazy sleeping dog's back then sat on a tack.", -1); // -1 null-terminated string. +#endif + #if !PANGO_VERSION_CHECK(1,22,0) PangoLayoutIter *iter; iter = pango_layout_get_iter(layout);