diff options
author | Tor Lillqvist <tml@iki.fi> | 2002-09-28 12:00:26 +0000 |
---|---|---|
committer | Tor Lillqvist <tml@src.gnome.org> | 2002-09-28 12:00:26 +0000 |
commit | 12d0958d835e729540cdffc4f9b7ef8f012d493b (patch) | |
tree | f227c23a67214e1fb06520ef922447c45e51a035 /pango/pangowin32-fontmap.c | |
parent | a031b12aacf2a586447b39f25a8f0e6ae5944c4d (diff) | |
download | pango-12d0958d835e729540cdffc4f9b7ef8f012d493b.tar.gz |
Revert change from 2002-09-21: Don't bypass the code that automatically
2002-09-28 Tor Lillqvist <tml@iki.fi>
* pango/pangowin32-fontmap.c (pango_win32_insert_font): Revert
change from 2002-09-21: Don't bypass the code that automatically
adds fonts to the families "monospace", "serif" and "sans". I
thought it would be unnecessary if you have a pango.aliases that
sets up aliases for these family names, but apparently
not. Without this code, pango_layout_line_get_empty_extents()
thinks empty lines have zero height, as it tries to use a font
called "sans" for instance, and no aliases get used.
Diffstat (limited to 'pango/pangowin32-fontmap.c')
-rw-r--r-- | pango/pangowin32-fontmap.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/pango/pangowin32-fontmap.c b/pango/pangowin32-fontmap.c index 5f70f5d2..f919717a 100644 --- a/pango/pangowin32-fontmap.c +++ b/pango/pangowin32-fontmap.c @@ -442,6 +442,7 @@ pango_win32_font_map_load_font (PangoFontMap *fontmap, { PangoWin32Face *best_match = NULL; + PING (("got win32family")); tmp_list = win32family->font_entries; while (tmp_list) { @@ -460,13 +461,14 @@ pango_win32_font_map_load_font (PangoFontMap *fontmap, GSList *tmp_list = best_match->cached_fonts; gint size = pango_font_description_get_size (description); - PING(("got best match:%s",best_match->logfont.lfFaceName)); + PING(("got best match:%s size=%d",best_match->logfont.lfFaceName,size)); while (tmp_list) { PangoWin32Font *win32font = tmp_list->data; if (win32font->size == size) { + PING (("size matches")); result = (PangoFont *)win32font; g_object_ref (G_OBJECT (result)); @@ -771,7 +773,7 @@ pango_win32_insert_font (PangoWin32FontMap *win32fontmap, font_family->font_entries = g_slist_append (font_family->font_entries, win32face); win32fontmap->n_fonts++; -#if 0 /* Use pango.aliases instead */ +#if 1 /* Thought pango.aliases would make this code unnecessary, but no. */ /* * There are magic family names coming from the X implementation. * They can be simply mapped to lfPitchAndFamily flag of the logfont |