Dermot Musgrove wrote:

> However I think that buttons should be GtkButton _or_ GnomeStockButton so
> that they can be seen to be different widgets (as they are).

Gnome uses a GtkButton for the stock buttons.

I think it would have been better if there was a GnomeButton widget, which
was similar to GtkButton but also had a "stock" property so you could pick
one of the stock buttons. We could then have removed GtkButton from the
palette in the Gnome version and just used GnomeButton instead.

I think that would be better than having GtkButton & GnomeStockButton, since
that would make it more awkward to switch from a stock button to an ordinary
one and vice versa.

The same goes for the menu items. I had to overload the GTK+ widgets to cope
with extra properties for Gnome. This made it difficult to split the Gnome
support into a separate library (as libglade does), which would be quite handy.
Having 2 versions of Glade is a bit awkward.

The moral is - if you want your widgets to work well in a GUI builder, make
sure they are object-oriented. Don't use utility functions to extend existing
widgets. Create subclasses with additional properties instead.

Damon


+---------------------------------------------------------------------+
To unsubscribe from this list, send a message to [EMAIL PROTECTED]
with the line "unsubscribe glade-devel" in the body of the message.

Reply via email to