summaryrefslogtreecommitdiff
path: root/pango/pangoxft-private.h
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2002-08-06 03:43:16 +0000
committerOwen Taylor <otaylor@src.gnome.org>2002-08-06 03:43:16 +0000
commit9629e9e1ffa2f76989c877a2c2e4c0324716100d (patch)
treefebf99a1e4bc4601aed073b4ac5d41fe02036c46 /pango/pangoxft-private.h
parent4b1d623ea4e751b2038588c894a19c0589840f4b (diff)
downloadpango-9629e9e1ffa2f76989c877a2c2e4c0324716100d.tar.gz
Patch from Keith Packard:
Mon Aug 5 23:12:13 2002 Owen Taylor <otaylor@redhat.com> Patch from Keith Packard: * pango/pangoxft-private.h (struct _PangoXftFont): Add some comments. * pango/pangoxft-private.h pango/pangoxft-font.c pango/pangoxft-fontmap.c: Identify coverage by a pair of filename and index within the filename instead of just a filename, to handle TrueType Collection (TTC) fonts. * pango/pangoxft-fontmap.c (pango_xft_make_pattern): Remove some leftover comments.
Diffstat (limited to 'pango/pangoxft-private.h')
-rw-r--r--pango/pangoxft-private.h21
1 files changed, 14 insertions, 7 deletions
diff --git a/pango/pangoxft-private.h b/pango/pangoxft-private.h
index ffc5a3c5..07dbad44 100644
--- a/pango/pangoxft-private.h
+++ b/pango/pangoxft-private.h
@@ -28,26 +28,33 @@
G_BEGIN_DECLS
typedef struct _PangoXftFont PangoXftFont;
+typedef struct _PangoXftCoverageKey PangoXftCoverageKey;
struct _PangoXftFont
{
PangoFont parent_instance;
- FcPattern *font_pattern;
- XftFont *xft_font;
- PangoFont *mini_font;
- PangoFontMap *fontmap;
+ FcPattern *font_pattern; /* fully resolved pattern */
+ XftFont *xft_font; /* created on demand */
+ PangoFont *mini_font; /* font used to display missing glyphs */
+ PangoFontMap *fontmap; /* associated map */
PangoFontDescription *description;
GSList *metrics_by_lang;
- guint16 mini_width;
+ guint16 mini_width; /* metrics for missing glyph drawing */
guint16 mini_height;
guint16 mini_pad;
gboolean in_cache;
};
+struct _PangoXftCoverageKey
+{
+ char *filename;
+ int id; /* needed to handle TTC files with multiple faces */
+};
+
PangoXftFont * _pango_xft_font_new (PangoFontMap *font,
FcPattern *pattern);
void _pango_xft_font_map_cache_add (PangoFontMap *fontmap,
@@ -57,10 +64,10 @@ void _pango_xft_font_map_add (PangoFontMap *fo
void _pango_xft_font_map_remove (PangoFontMap *fontmap,
PangoXftFont *xfont);
void _pango_xft_font_map_set_coverage (PangoFontMap *fontmap,
- const char *name,
+ const PangoXftCoverageKey *key,
PangoCoverage *coverage);
PangoCoverage *_pango_xft_font_map_get_coverage (PangoFontMap *fontmap,
- const char *name);
+ const PangoXftCoverageKey *key);
void _pango_xft_font_map_get_info (PangoFontMap *fontmap,
Display **display,
int *screen);