summaryrefslogtreecommitdiff
path: root/pango/pangowin32-fontcache.c
diff options
context:
space:
mode:
authorTor Lillqvist <tml@iki.fi>2002-01-01 23:08:39 +0000
committerTor Lillqvist <tml@src.gnome.org>2002-01-01 23:08:39 +0000
commit2210a8aa8286f7af2e1a17354e9b027a1f669867 (patch)
tree269a26077cc34747881cae90c50966b4090e2a38 /pango/pangowin32-fontcache.c
parentf7ae83fefadb78c237691112f217516bbf4e3eb5 (diff)
downloadpango-2210a8aa8286f7af2e1a17354e9b027a1f669867.tar.gz
Set lfCharSet to DEFAULT_CHARSET always. Conditional debugging output with
2002-01-02 Tor Lillqvist <tml@iki.fi> * pango/pangowin32-fontcache.c (pango_win32_font_cache_load): Set lfCharSet to DEFAULT_CHARSET always. Conditional debugging output with the PING() macro. * pango/pangowin32-fontmap.c: Make the size_infos hash table actually work like it is suppposed to, not that I know if it matters. I think that it's useless to store all the different charset views of the same actual ttf font in the list. Will have to do more testing. (logfont_nosize_hash): Lowercase face name before calculating hash. (logfont_nosize_equal): Compare face names ignoring case.
Diffstat (limited to 'pango/pangowin32-fontcache.c')
-rw-r--r--pango/pangowin32-fontcache.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/pango/pangowin32-fontcache.c b/pango/pangowin32-fontcache.c
index 613c3806..2986a33b 100644
--- a/pango/pangowin32-fontcache.c
+++ b/pango/pangowin32-fontcache.c
@@ -184,31 +184,31 @@ pango_win32_font_cache_load (PangoWin32FontCache *cache,
}
else
{
- BOOL aa = TRUE; /* turn on anti-aliasing */
+ BOOL aa;
lf = *lfp;
SystemParametersInfo (SPI_GETFONTSMOOTHING, 0, &aa, 0);
lf.lfQuality = (aa ? ANTIALIASED_QUALITY : DEFAULT_QUALITY);
+ lf.lfCharSet = DEFAULT_CHARSET;
for (tries = 0; ; tries++)
{
-#if 0
- PANGO_NOTE
- (g_print
- ("... trying CreateFontIndirect, "
- "height=%d,width=%d,escapement=%d,orientation=%d,"
- "weight=%d,%s%s%s"
- "charset=%d,outprecision=%d,clipprecision=%d,"
- "quality=%d,pitchandfamily=%#.02x,facename=\"%s\")\n",
- lf.lfHeight, lf.lfWidth, lf.lfEscapement, lf.lfOrientation,
- lf.lfWeight, (lf.lfItalic ? "italic," : ""),
- (lf.lfUnderline ? "underline," : ""),
- (lf.lfStrikeOut ? "strikeout," : ""),
- lf.lfCharSet, lf.lfOutPrecision, lf.lfClipPrecision,
- lf.lfQuality, lf.lfPitchAndFamily, lf.lfFaceName));
-#endif
+ PING (("... trying CreateFontIndirect "
+ "height=%ld,width=%ld,escapement=%ld,orientation=%ld,"
+ "weight=%ld,%s%s%s"
+ "charset=%d,outprecision=%d,clipprecision=%d,"
+ "quality=%d,pitchandfamily=%#.02x,facename=\"%s\")",
+ lf.lfHeight, lf.lfWidth, lf.lfEscapement, lf.lfOrientation,
+ lf.lfWeight, (lf.lfItalic ? "italic," : ""),
+ (lf.lfUnderline ? "underline," : ""),
+ (lf.lfStrikeOut ? "strikeout," : ""),
+ lf.lfCharSet, lf.lfOutPrecision, lf.lfClipPrecision,
+ lf.lfQuality, lf.lfPitchAndFamily, lf.lfFaceName));
hfont = CreateFontIndirect (&lf);
if (hfont != NULL)
- break;
+ {
+ PING (("Success!\n"));
+ break;
+ }
/* If we fail, try some similar fonts often found on Windows. */
if (tries == 0)