diff options
author | Owen Taylor <otaylor@redhat.com> | 2004-07-10 21:41:37 +0000 |
---|---|---|
committer | Owen Taylor <otaylor@src.gnome.org> | 2004-07-10 21:41:37 +0000 |
commit | 0835f598fcfbf6667a4be9cd9e7f6f16663dcb6a (patch) | |
tree | ff38ab996514339ab0ad7b2be560b525a6537655 /pango/pangowin32-fontmap.c | |
parent | 5bf0c1d04b6ed75ad2c88fbed1e1eaecf0dcbfa2 (diff) | |
download | pango-0835f598fcfbf6667a4be9cd9e7f6f16663dcb6a.tar.gz |
Make PangoMatrix arguments const where appropriate.
Sat Jul 10 17:33:38 2004 Owen Taylor <otaylor@redhat.com>
* pango/pangoft2-private.h pango/pangoft2-render.c
pango/pango-context.[ch] pango/pangoft2.[ch] pango/pango-utils.
pango/pango-types.h pango/pangofc-fontmap.c: Make PangoMatrix
arguments const where appropriate.
* pango/pango-context.c pango/fonts.c pango/pangofc-font.c
pangofc-fontmap.c pango/pangoft2.c pango/pangoft2-fontmap.c
pango/pangoxft-font.c pango/pangoxft-fontmap.c
pango/pangowin32-fontmap.c: Use G_DEFINE_TYPE comprehensively.
* pango/pangoft2-private.h pangoft2.c: Un-staticify
pango_ft2_font_get_type.
Diffstat (limited to 'pango/pangowin32-fontmap.c')
-rw-r--r-- | pango/pangowin32-fontmap.c | 37 |
1 files changed, 2 insertions, 35 deletions
diff --git a/pango/pangowin32-fontmap.c b/pango/pangowin32-fontmap.c index ba93d30c..8d462ad0 100644 --- a/pango/pangowin32-fontmap.c +++ b/pango/pangowin32-fontmap.c @@ -99,9 +99,6 @@ static void pango_win32_face_list_sizes (PangoFontFace *face, int **sizes, int *n_sizes); -static void pango_win32_font_map_init (PangoWin32FontMap *fontmap); -static void pango_win32_font_map_class_init (PangoFontMapClass *class); - static void pango_win32_font_map_finalize (GObject *object); static PangoFont *pango_win32_font_map_load_font (PangoFontMap *fontmap, PangoContext *context, @@ -115,35 +112,7 @@ static void pango_win32_fontmap_cache_clear (PangoWin32FontMap static void pango_win32_insert_font (PangoWin32FontMap *fontmap, LOGFONT *lfp); -static PangoFontClass *font_map_parent_class; /* Parent class structure for PangoWin32FontMap */ - -static GType -pango_win32_font_map_get_type (void) -{ - static GType object_type = 0; - - if (!object_type) - { - static const GTypeInfo object_info = - { - sizeof (PangoFontMapClass), - (GBaseInitFunc) NULL, - (GBaseFinalizeFunc) NULL, - (GClassInitFunc) pango_win32_font_map_class_init, - NULL, /* class_finalize */ - NULL, /* class_data */ - sizeof (PangoWin32FontMap), - 0, /* n_preallocs */ - (GInstanceInitFunc) pango_win32_font_map_init, - }; - - object_type = g_type_register_static (PANGO_TYPE_FONT_MAP, - "PangoWin32FontMap", - &object_info, 0); - } - - return object_type; -} +G_DEFINE_TYPE (PangoWin32FontMap, pango_win32_font_map, PANGO_TYPE_FONT_MAP) /* A hash function for LOGFONTs that takes into consideration only * those fields that indicate a specific .ttf file is in use: @@ -188,8 +157,6 @@ pango_win32_font_map_class_init (PangoFontMapClass *class) { GObjectClass *object_class = G_OBJECT_CLASS (class); - font_map_parent_class = g_type_class_peek_parent (class); - object_class->finalize = pango_win32_font_map_finalize; class->load_font = pango_win32_font_map_load_font; class->list_families = pango_win32_font_map_list_families; @@ -293,7 +260,7 @@ pango_win32_font_map_finalize (GObject *object) pango_win32_font_cache_free (win32fontmap->font_cache); - G_OBJECT_CLASS (font_map_parent_class)->finalize (object); + G_OBJECT_CLASS (pango_win32_font_map_parent_class)->finalize (object); } /* |