diff options
author | Hans Breuer <hans@breuer.org> | 2001-02-19 20:53:56 +0000 |
---|---|---|
committer | Hans Breuer <hans@src.gnome.org> | 2001-02-19 20:53:56 +0000 |
commit | a7e7e50eea273f1b7f50da041bea1a53782b06f8 (patch) | |
tree | 815a65c866ac716200fe8d004631df0372be20ad /pango/pangowin32-fontmap.c | |
parent | f261f4ca89bade8bf24ef5a76dbb68bd113cc748 (diff) | |
download | pango-a7e7e50eea273f1b7f50da041bea1a53782b06f8.tar.gz |
added _pango_included_win32_modules[] to include modules with plain win32
2001-02-19 Hans Breuer <hans@breuer.org>
* pango/modules.h, pango/pangowin32.c (pango_win32_get_context) :
added _pango_included_win32_modules[] to include modules with plain
win32 build as well.
* pango/pango.def : added new exported functions
* pango/pangowin32-fontmap.c : add unspecified fonts for Monospace,
Sans and Serif to avoid crashes if no alias file is provided
* pango/*/makefile.msc : new files to build on windoze with msvc
Diffstat (limited to 'pango/pangowin32-fontmap.c')
-rw-r--r-- | pango/pangowin32-fontmap.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/pango/pangowin32-fontmap.c b/pango/pangowin32-fontmap.c index f32f92cb..a91510ad 100644 --- a/pango/pangowin32-fontmap.c +++ b/pango/pangowin32-fontmap.c @@ -239,6 +239,25 @@ pango_win32_font_map_for_display (void) logfont.lfCharSet = DEFAULT_CHARSET; EnumFontFamiliesEx (pango_win32_hdc, &logfont, (FONTENUMPROC) pango_win32_enum_proc, 0, 0); + /* There are fonts installed on every system, use these + * as fallback. Otherwise Really Bad Things (tm) would + * happen without an alias file ... + * (The names are required for Pango and may be resolved + * to different fonts on different systems) + */ + memset (&logfont, 0, sizeof (logfont)); + strcpy (logfont.lfFaceName, "monospace"); + logfont.lfPitchAndFamily = FF_MODERN; + pango_win32_insert_font (fontmap, &logfont); + + strcpy (logfont.lfFaceName, "sans"); + logfont.lfPitchAndFamily = FF_SWISS; + pango_win32_insert_font (fontmap, &logfont); + + strcpy (logfont.lfFaceName, "serif"); + logfont.lfPitchAndFamily = FF_ROMAN; + pango_win32_insert_font (fontmap, &logfont); + pango_win32_font_map_read_aliases (fontmap); SystemParametersInfo(SPI_GETWORKAREA, 0, &rect, 0); |