[prev in list] [next in list] [prev in thread] [next in thread]
List: gtk-devel
Subject: Re: Extended Layout Summary
From: Sven Herzberg <herzi () gnome-de ! org>
Date: 2008-01-10 16:19:48
Message-ID: 1199981988.12543.122.camel () wendolene
[Download RAW message or body]
Am Freitag, den 21.12.2007, 11:05 +0100 schrieb Mathias Hasselmann:
> Am Donnerstag, den 20.12.2007, 11:46 -0500 schrieb Havoc Pennington:
> > Third, since implementing an interface requires extra boilerplate
> > GObject stuff, it would be convenient for authors of a custom widget if
> > GtkWidget already did the boilerplate for them. Since for newly-written
> > custom widgets, the recommendation would be to always support extended
> > layout.
>
> I don't see the boilerplate savings you talk about? As far as I
> understand GObject interfaces, you always need this this single-line
> boilerplate for overriding interface methods:
>
> G_DEFINE_TYPE_WITH_CODE (MamanBar, maman, GTK_TYPE_WIDGET,
> G_IMPLEMENT_INTERFACE (GTK_TYPE_IFACE, maman_bar_iface_init))
Not if GtkWidget already implements GtkExtendedLayout->get_min_size()
like this: GTK_WIDGET_GET_CLASS(instance)->get_min_size. Then you could
easily override the implementation in class_init(). I think this was
what Havoc meant.
Regards,
Sven
_______________________________________________
gtk-devel-list mailing list
gtk-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-devel-list
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic