bourdett

bourdett

  • NA
  • 3
  • 0

Graphic display of nodes on a form.panel

Jun 26 2004 9:01 AM
I have created a custom user control which I call a Node. Basically a Node is just visual representation of a small black circle. In my mainForm I have an array of these NodeControls. I want to be able to run through the the array and Add all the controls to a Form.Panel control which I have created. I can add them to the contol now by just saying something like Location = new Drawing.Point( counter*32, yvalue); but I'm looking for a smart algorithm that will know how to place my object all over the screen without making it look terrible. I mean in one case there might be 5 object in which case showing them in a linear row like i do now is fine, but more then likely the case will be like perphaps up to 100 nodes. How can intelligently display these node, and also I will be adding lines (connections) between these nodes? Thanks Jason

Answers (2)