Re: GdkColormap -> GObject

On Tue, 16 May 2000, Karl Nelson wrote:

> > One idea is to have a G_TYPE_NO_DERIVATION flag, which would allow
> > glib to issue a warning if you try to subclass these types.
> > This might be a stupid hack, I don't know.

we can specify that for fundamental branches as outlined in one
of my earlier type system emails, e.g. we allow
- non-derivable fundamentals
- flat-derivable fundamentals (for enums, so you got:
   +--- GtkArrowType
   +--- GtkCurveType
   +--- etc...
- deep derivabele types, i.e. GObject

i tend to agree here, that cutting off derivation abilities is
a bad hack (though, iirc, java has something like that).
but normally, putting a comment that people shouldn't derive
here should be good enough.

> This is a bad idea.  Gtk-- currently has to derive things once
> to install hooks if it needs it.  If you add flags like that
> then we would not be able to use that same mechanism on all
> types.

yeah, good point.

> --Karl


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]