Re: object model
- From: Lars Clausen <lrclause cs uiuc edu>
- To: dia-list gnome org
- Subject: Re: object model
- Date: Wed, 29 Oct 2003 12:39:14 -0600
On 28 Oct 2003, saintiss gmx net wrote:
Hi,
I've got a quite general question here:
I've noticed that inheritance is simulated by having an instance of the
superclass as the first member... But is there something like a checked
type cast? i.e. where you'd get NULL if the pointer isn't of the right
type or something? (an equivalent of dynamic_cast in C++ I mean)...
There's the standard GLib type operations.
Also, I'm guessing there's something like polymorphism too... Is all this
just written from scratch for Dia, or is this all part of a certain
object model, like GObject? I'd think so, but then again it seems like
Object doesn't inherit from GObject, so I'm a bit confused...
It doesn't though it really should. We use the GTK type system, but
everything else is Dia-specific. The renderers have been converted to
GObjects, but the regular objects remain strange.
-Lars
--
Lars Clausen (http://shasta.cs.uiuc.edu/~lrclause)| HÃrdgrim of Numenor
"I do not agree with a word that you say, but I |----------------------------
will defend to the death your right to say it." | Where are we going, and
--Evelyn Beatrice Hall paraphrasing Voltaire | what's with the handbasket?
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]