summaryrefslogtreecommitdiff
path: root/pango/pangocairo-fcfont.c
diff options
context:
space:
mode:
authorBehdad Esfahbod <behdad@gnome.org>2006-08-21 03:05:46 +0000
committerBehdad Esfahbod <behdad@src.gnome.org>2006-08-21 03:05:46 +0000
commit3ae5159b3f64aa0b5a8119177ab1d765810bd3d8 (patch)
tree2d5db55240def5407997eecbb563273dd78062a5 /pango/pangocairo-fcfont.c
parenteb1c701a10dc70680326c1bf47d6ae5aea472c46 (diff)
downloadpango-3ae5159b3f64aa0b5a8119177ab1d765810bd3d8.tar.gz
Support per-item gravity.
2006-08-20 Behdad Esfahbod <behdad@gnome.org> Support per-item gravity. * pango/pango-context.c (update_attr_iterator), (itemize_state_init), (itemize_state_update_for_new_run), (itemize_state_process_run): Make per-item gravity work, by setting gravity into font description before loading fonts. Also, allow the context font description to override the gravity (but not centered_baseline.) * pango/pangocairo-fcfont.c (_pango_cairo_fc_font_new): Get gravity from font description, not context. * pango/pangofc-fontmap.c (fontset_hash_key_equal), (fontset_hash_key_hash), (fontset_hash_key_copy), (pango_fc_make_pattern), (pango_fc_font_map_get_patterns), (pango_fc_font_map_load_fontset), (pango_fc_font_description_from_pattern): Get gravity from font description, not context. Moreover, put it into pattern, and reconstruct it out of font patterns. * pango/pangofc-private.h: Define PANGO_FC_GRAVITY, which is the key we put PangoGravity into an FcPattern under.
Diffstat (limited to 'pango/pangocairo-fcfont.c')
-rw-r--r--pango/pangocairo-fcfont.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/pango/pangocairo-fcfont.c b/pango/pangocairo-fcfont.c
index f6ce1087..cb5d9598 100644
--- a/pango/pangocairo-fcfont.c
+++ b/pango/pangocairo-fcfont.c
@@ -507,8 +507,7 @@ _pango_cairo_fc_font_new (PangoCairoFcFontMap *cffontmap,
"pattern", pattern,
NULL);
- /* FIXME: support per-item gravity */
- cffont->gravity = pango_context_get_gravity (context);
+ cffont->gravity = pango_font_description_get_gravity (desc);
if (FcPatternGetMatrix (pattern,
FC_MATRIX, 0, &fc_matrix) == FcResultMatch)