diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2016-12-23 15:40:25 +0000 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2016-12-23 15:40:25 +0000 |
| commit | 3145e065850b258fe065b5c8df27db0426417275 (patch) | |
| tree | 10a3f937f81dc3c1471b797f6f506330aaa9ae7d | |
| parent | 60a9eee30d3546c0574a894cc71085cb155c2b5d (diff) | |
Fix CMake config.h and compiler warnings.
Fixed warnings: -Wsign-compare, -Wunused-but-set-variable.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12155 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
| -rw-r--r-- | configh.cmake.in | 14 | ||||
| -rw-r--r-- | src/drivers/Xlib/Fl_Xlib_Graphics_Driver_font_xft.cxx | 8 |
2 files changed, 9 insertions, 13 deletions
diff --git a/configh.cmake.in b/configh.cmake.in index e91c31cd5..d9fb49d14 100644 --- a/configh.cmake.in +++ b/configh.cmake.in @@ -86,18 +86,18 @@ /* * USE_XFT * - * Use the new Xft library to draw anti-aliased text. + * Use the Xft library to draw anti-aliased text. */ #cmakedefine01 USE_XFT /* -* USE_PANGO: -* -* Use the pango library to draw UTF8 text. -*/ + * USE_PANGO + * + * Use the pango library to draw UTF-8 text. + */ -#cmakedefine USE_PANGO 1 +#cmakedefine01 USE_PANGO /* * HAVE_XDBE: @@ -183,7 +183,7 @@ * to be ported to the core driver setup. */ -#cmakedefine FL_PORTING 0 +#cmakedefine FL_PORTING 1 /* * HAVE_OVERLAY: diff --git a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_font_xft.cxx b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_font_xft.cxx index 5b39b0e6b..167e2abe2 100644 --- a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_font_xft.cxx +++ b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_font_xft.cxx @@ -1223,14 +1223,10 @@ void Fl_Xlib_Graphics_Driver::do_draw(int from_right, const char *str, int n, in } const char *old = 0; if (!str2) old = pango_layout_get_text(playout_); - if (!old || strlen(old) != n || memcmp(str, old, n)) // do not re-set text if equal to text already in layout + if (!old || (int)strlen(old) != n || memcmp(str, old, n)) // do not re-set text if equal to text already in layout pango_layout_set_text(playout_, str, n); if (str2) free(str2); - int found=0; - if(strstr(str, "α")) { - found=1; - } - + XftColor color; Fl_Color c = this->color(); color.pixel = fl_xpixel(c); |
