Author: silene
Date: Sat Apr 25 22:32:41 2009
New Revision: 35215

URL: http://svn.gna.org/viewcvs/wesnoth?rev=35215&view=rev
Log:
Backport of revision 35214.
Enabled hinting for texts displayed by Pango/Cairo. (Bug #13399)

Modified:
    branches/1.6/changelog
    branches/1.6/src/text.cpp

Modified: branches/1.6/changelog
URL: 
http://svn.gna.org/viewcvs/wesnoth/branches/1.6/changelog?rev=35215&r1=35214&r2=35215&view=diff
==============================================================================
--- branches/1.6/changelog (original)
+++ branches/1.6/changelog Sat Apr 25 22:32:41 2009
@@ -30,6 +30,7 @@
    * Fixed missing unit graphics when loading a start-of-scenario savegame
    * Improved the sorting of the XP and traits columns in the unit list dialog
      (part of bug #13360)
+   * Enabled hinting for texts displayed by Pango/Cairo (bug #13399)
 
 Version 1.6.1:
   * Campaigns:

Modified: branches/1.6/src/text.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/branches/1.6/src/text.cpp?rev=35215&r1=35214&r2=35215&view=diff
==============================================================================
--- branches/1.6/src/text.cpp (original)
+++ branches/1.6/src/text.cpp Sat Apr 25 22:32:41 2009
@@ -82,6 +82,12 @@
        pango_cairo_context_set_resolution(context_, 72.0);
 
        pango_layout_set_ellipsize(layout_, ellipse_mode_);
+
+       cairo_font_options_t *fo = cairo_font_options_create();
+       cairo_font_options_set_hint_style(fo, CAIRO_HINT_STYLE_FULL);
+       cairo_font_options_set_hint_metrics(fo, CAIRO_HINT_METRICS_ON);
+       pango_cairo_context_set_font_options(context_, fo);
+       cairo_font_options_destroy(fo);
 }
 
 ttext::~ttext()


_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits

Reply via email to