diff options
author | Behdad Esfahbod <behdad@gnome.org> | 2008-04-21 21:47:47 +0000 |
---|---|---|
committer | Behdad Esfahbod <behdad@src.gnome.org> | 2008-04-21 21:47:47 +0000 |
commit | 35699a667f6d28d843d6f6fb6d099415755f7401 (patch) | |
tree | 9f070cdf1b449f981a2cd789d99554f86d5673a0 /pango/pangocairo-font.c | |
parent | 451d5a70fe771cf19e570e9896ad566239974ece (diff) | |
download | pango-35699a667f6d28d843d6f6fb6d099415755f7401.tar.gz |
Bug 474706 – cairo hexbox looks ugly
2008-04-21 Behdad Esfahbod <behdad@gnome.org>
Bug 474706 – cairo hexbox looks ugly
* pango/pangocairo-font.c
(_pango_cairo_font_private_get_hex_box_info):
Tweak minifont size a bit. Also propagate font options correctly.
svn path=/trunk/; revision=2604
Diffstat (limited to 'pango/pangocairo-font.c')
-rw-r--r-- | pango/pangocairo-font.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/pango/pangocairo-font.c b/pango/pangocairo-font.c index 0c439284..18501252 100644 --- a/pango/pangocairo-font.c +++ b/pango/pangocairo-font.c @@ -320,6 +320,7 @@ _pango_cairo_font_private_get_hex_box_info (PangoCairoFontPrivate *cf_priv) gravity = pango_font_description_get_gravity (desc); cairo_scaled_font_get_ctm (scaled_font, &cairo_ctm); + cairo_scaled_font_get_font_options (scaled_font, font_options); /* I started adding support for vertical hexboxes here, but it's too much * work. Easier to do with cairo user fonts and vertical writing mode * support in cairo. @@ -371,15 +372,15 @@ _pango_cairo_font_private_get_hex_box_info (PangoCairoFontPrivate *cf_priv) pango_font_description_set_family_static (desc, "monospace"); rows = 2; - mini_size = size / 2.4; + mini_size = size / 2.2; if (is_hinted) { mini_size = HINT_Y (mini_size); - if (mini_size < 5.0) + if (mini_size < 6.0) { rows = 1; - mini_size = MIN (MAX (size - 1, 0), 5.0); + mini_size = MIN (MAX (size - 1, 0), 6.0); } } |