diff options
Diffstat (limited to 'pango')
-rw-r--r-- | pango/pango-types.h | 9 | ||||
-rw-r--r-- | pango/pango-utils.c | 13 |
2 files changed, 22 insertions, 0 deletions
diff --git a/pango/pango-types.h b/pango/pango-types.h index cf41ab6f..a8d2f448 100644 --- a/pango/pango-types.h +++ b/pango/pango-types.h @@ -84,6 +84,13 @@ struct _PangoMatrix }; /** + * PANGO_TYPE_MATRIX + * + * The GObject type for #PangoMatrix + **/ +#define PANGO_TYPE_MATRIX (pango_matrix_get_type ()) + +/** * PANGO_MATRIX_INIT * * Constant that can be used to initialize a PangoMatrix to @@ -96,6 +103,8 @@ struct _PangoMatrix **/ #define PANGO_MATRIX_INIT { 1., 0., 0., 1., 0., 0. } +GType pango_matrix_get_type (void); + PangoMatrix *pango_matrix_copy (const PangoMatrix *matrix); void pango_matrix_free (PangoMatrix *matrix); diff --git a/pango/pango-utils.c b/pango/pango-utils.c index 7ff41fdb..2867e269 100644 --- a/pango/pango-utils.c +++ b/pango/pango-utils.c @@ -987,6 +987,19 @@ pango_parse_stretch (const char *str, return FALSE; } +GType +pango_matrix_get_type (void) +{ + static GType our_type = 0; + + if (our_type == 0) + our_type = g_boxed_type_register_static ("PangoMatrix", + (GBoxedCopyFunc) pango_matrix_copy, + (GBoxedFreeFunc) pango_matrix_free); + + return our_type; +} + /** * pango_matrix_copy: * @matrix: a #PangoMatrix |