FreeType-backend procudes wrong unicode special characters on some systems (because of localization settings?)
- From: "Jan Stühmer" <jstuehmer gmx net>
- To: gtk-i18n-list gnome org
- Subject: FreeType-backend procudes wrong unicode special characters on some systems (because of localization settings?)
- Date: Sat, 12 Sep 2009 11:48:18 +0200
Hi all,
after I switched the pango-cairo backend to freetype, I get very nice Font rendering output under win32. Thanks to everyone developing Pango!
But since I switched to the FT backend I'm experiencing problems when rendering unicode special characters.
Special characters in the text, that should be rendered, are represented like #xE4; with UTF8-encoding.
Before I switched to Freetype the text encoding was fine, but now some single special characters (not the standard ASCII set) are represented with wrong single characters.
However, I don't experience this problem on all systems. Could it depend on the localization-settings of the windows system?
I don't have problems on a US-English system, but get wrong special character substitution on a German system. However this is just a guess and I couldn't ty yet to change the settings of that machine.
To switch to FT I use the following code snippet (was originally postetd by Behdad Esfahbod)
PangoFontMap* fontmap = pango_cairo_font_map_get_default ();
if (pango_cairo_font_map_get_font_type ((PangoCairoFontMap*)(fontmap)) != CAIRO_FONT_TYPE_FT)
{
PangoFontMap* ftfontmap = pango_cairo_font_map_new_for_font_type (CAIRO_FONT_TYPE_FT);
if (ftfontmap)
fontmap = ftfontmap;
else
fontmap = static_cast<PangoFontMap*>(g_object_ref (fontmap));
}
else
fontmap = static_cast<PangoFontMap*>(g_object_ref (fontmap));
pango_cairo_font_map_set_default ((PangoCairoFontMap*)(fontmap));
I'm using Pango 1.24.5 with Cairo 1.8.8 binaries from the GTK+2.0 win32 binary package with MSYS/MinGW.
Thank you for your advice,
Jan Stühmer
--
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]