diff options
Diffstat (limited to 'src/libnrtype')
| -rwxr-xr-x | src/libnrtype/Layout-TNG-Input.cpp | 4 | ||||
| -rwxr-xr-x | src/libnrtype/Layout-TNG-Output.cpp | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/libnrtype/Layout-TNG-Input.cpp b/src/libnrtype/Layout-TNG-Input.cpp index 49fc03607..b99107885 100755 --- a/src/libnrtype/Layout-TNG-Input.cpp +++ b/src/libnrtype/Layout-TNG-Input.cpp @@ -8,6 +8,8 @@ * * Released under GNU GPL, read the file 'COPYING' for more information */ + +#include <gtk/gtkversion.h> #include "Layout-TNG.h" #include "style.h" #include "svg/svg-length.h" @@ -229,7 +231,7 @@ static const Layout::EnumConversionItem enum_convert_spstyle_weight_to_pango_wei {SP_CSS_FONT_WEIGHT_200, PANGO_WEIGHT_ULTRALIGHT}, {SP_CSS_FONT_WEIGHT_300, PANGO_WEIGHT_LIGHT}, {SP_CSS_FONT_WEIGHT_400, PANGO_WEIGHT_NORMAL}, -#ifdef PANGO_WEIGHT_SEMIBOLD +#if GTK_CHECK_VERSION(2,6,0) {SP_CSS_FONT_WEIGHT_500, PANGO_WEIGHT_SEMIBOLD}, #else {SP_CSS_FONT_WEIGHT_500, PANGO_WEIGHT_NORMAL}, diff --git a/src/libnrtype/Layout-TNG-Output.cpp b/src/libnrtype/Layout-TNG-Output.cpp index ca25a24ff..97d98d3c4 100755 --- a/src/libnrtype/Layout-TNG-Output.cpp +++ b/src/libnrtype/Layout-TNG-Output.cpp @@ -9,6 +9,7 @@ * Released under GNU GPL, read the file 'COPYING' for more information */ #include <glib/gmem.h> +#include <gtk/gtkversion.h> #include "Layout-TNG.h" #include "display/nr-arena-glyphs.h" #include "style.h" @@ -219,7 +220,7 @@ static char const *weight_to_text(PangoWeight w) switch (w) { case PANGO_WEIGHT_ULTRALIGHT: return "ultralight"; case PANGO_WEIGHT_LIGHT : return "light"; -#ifdef PANGO_WEIGHT_SEMIBOLD +#if GTK_CHECK_VERSION(2,6,0) case PANGO_WEIGHT_SEMIBOLD : return "semibold"; #endif case PANGO_WEIGHT_NORMAL : return "normalweight"; |
