Page 1 of 1

A sample of deriving from node class?

PostPosted: May 14th, 2006, 12:05 am
by lee
Can someone provide an example of deriving from a node class? I'm interested in seeing how to create custom nodes. I want to create a node that implements a property sheet. I'm just not sure which method to override to implement inserting another control in the node's area.

Thank you,

Lee

PostPosted: May 15th, 2006, 2:02 pm
by Kambiz
In the SimpleGraph, all nides are derived from TGraphNode. Therefore, you can consider each of nodes as a sample.

PostPosted: May 16th, 2006, 3:56 am
by lee
Hello Kambiz,

I don't mean to be a pain to you, but I don't understand where I can add what I want to add. I would like to place another component within a derived node. Is this possible?

Thank you and very nice product, BTW

Lee

PostPosted: May 16th, 2006, 12:09 pm
by Kambiz
Yes, you can.

After deriving a new node/link class, you should register it to SimpleGraph by calling Register class method of TSimpleGraph. After that, the new class can be used within SimpleGraph.