summaryrefslogtreecommitdiff
path: root/font-viewer/sushi-font-widget.c
diff options
context:
space:
mode:
Diffstat (limited to 'font-viewer/sushi-font-widget.c')
-rw-r--r--font-viewer/sushi-font-widget.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/font-viewer/sushi-font-widget.c b/font-viewer/sushi-font-widget.c
index bad2ffee..cffd8776 100644
--- a/font-viewer/sushi-font-widget.c
+++ b/font-viewer/sushi-font-widget.c
@@ -62,7 +62,7 @@ struct _SushiFontWidgetPrivate {
static GParamSpec *properties[NUM_PROPERTIES] = { NULL, };
static guint signals[NUM_SIGNALS] = { 0, };
-G_DEFINE_TYPE (SushiFontWidget, sushi_font_widget, GTK_TYPE_DRAWING_AREA);
+G_DEFINE_TYPE_WITH_PRIVATE (SushiFontWidget, sushi_font_widget, GTK_TYPE_DRAWING_AREA);
#define SURFACE_SIZE 4
#define SECTION_SPACING 16
@@ -586,8 +586,7 @@ sushi_font_widget_init (SushiFontWidget *self)
{
FT_Error err;
- self->priv = G_TYPE_INSTANCE_GET_PRIVATE (self, SUSHI_TYPE_FONT_WIDGET,
- SushiFontWidgetPrivate);
+ self->priv = sushi_font_widget_get_instance_private (self);
self->priv->face = NULL;
err = FT_Init_FreeType (&self->priv->library);
@@ -716,7 +715,6 @@ sushi_font_widget_class_init (SushiFontWidgetClass *klass)
G_TYPE_NONE, 1, G_TYPE_STRING);
g_object_class_install_properties (oclass, NUM_PROPERTIES, properties);
- g_type_class_add_private (klass, sizeof (SushiFontWidgetPrivate));
}
SushiFontWidget *