summaryrefslogtreecommitdiff
path: root/pango
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2002-03-15 01:05:16 +0000
committerOwen Taylor <otaylor@src.gnome.org>2002-03-15 01:05:16 +0000
commitca30a4175066d693135eb035c4546e9a519054c4 (patch)
tree35751008e65e5188250884f4777efa62fcdadb13 /pango
parentd2f0b1f48367bc526f1d32270f1f98799389c2af (diff)
downloadpango-ca30a4175066d693135eb035c4546e9a519054c4.tar.gz
Remove moc_view-qt.cc. (#74725)
Thu Mar 14 20:02:58 2002 Owen Taylor <otaylor@redhat.com> * examples/Makefile.am (EXTRA_DIST): Remove moc_view-qt.cc. (#74725)
Diffstat (limited to 'pango')
-rw-r--r--pango/pangoxft-font.c38
1 files changed, 27 insertions, 11 deletions
diff --git a/pango/pangoxft-font.c b/pango/pangoxft-font.c
index 30246d39..6600bd78 100644
--- a/pango/pangoxft-font.c
+++ b/pango/pangoxft-font.c
@@ -456,7 +456,6 @@ pango_xft_font_get_coverage (PangoFont *font,
FT_Face face;
PangoCoverage *coverage;
Display *display;
- int i;
_pango_xft_font_map_get_info (xfont->fontmap, &display, NULL);
@@ -467,21 +466,38 @@ pango_xft_font_get_coverage (PangoFont *font,
if (coverage)
return pango_coverage_ref (coverage);
- /* Ugh, this is going to be SLOW */
-
face = pango_xft_font_get_face (font);
coverage = pango_coverage_new ();
- for (i = 0; i < G_MAXUSHORT; i++)
- {
- FT_UInt glyph = FT_Get_Char_Index (face, i);
-
- if (glyph && glyph < face->num_glyphs)
- pango_coverage_set (coverage, i, PANGO_COVERAGE_EXACT);
- }
+#ifdef HAVE_FT_GET_FIRST_CHAR
+ {
+ FT_ULong gindex;
+ FT_Ulong charcode;
+
+ charcode = FT_Get_First_Char (face, &gindex);
+ while (gindex)
+ {
+ pango_coverage_set (coverage, charcode, PANGO_COVERAGE_EXACT);
+ charcode = FT_Get_Next_Char (face, charcode, &gindex);
+ }
+ }
+#else
+ /* Ugh, this is going to be SLOW */
+ {
+ int i;
+
+ for (i = 0; i < G_MAXUSHORT; i++)
+ {
+ FT_UInt glyph = FT_Get_Char_Index (face, i);
+
+ if (glyph && glyph < face->num_glyphs)
+ pango_coverage_set (coverage, i, PANGO_COVERAGE_EXACT);
+ }
+ }
+#endif
_pango_xft_font_map_set_coverage (xfont->fontmap, filename, coverage);
-
+
return coverage;
}