We are displaying physical network data (i. e. hardware (monitors, computers, switches ...) and their relations) contained in our database in a FlowChart.NET diagram. The user chooses a HW node from which to start and then explores the network by expanding HW nodes of interest.
When the user clicks the + symbol of an expandable node, our program fetches the data of the related nodes, displays those nodes and links the newly added nodes to the expanded one. Everything works fine so far.
Now we would like the network that is being displayed be arranged neatly at any time. One of the basic question hereby is where to put the new nodes when an existing node is expanded. Basically the new nodes should not overlap existing nodes and should "fit best into the rest of the diagram" (I know that this is a very squishy statement).
We tried to come up with different approaches:
A) Search the spots on our own
We find the node that is located bottom most in the diagram and add the new nodes a little below it. It works ok, but I can't claim that the results are astonishing

B) Let FlowChart.NET look for appropriate spots
Here the idea was to somehow make use of your built in layout algoritm and let them do the work, instead of trying to come up with an own algorithm respectively heuristics.
B1) Always re-arrange the entire diagram after expanding a node
This works fine and when limiting the time permitted for the single algorithms offers acceptable performance. The problem with this approch however is that all the nodes are moved around after an expansion and thus the user is getting lost. Nodes that used to be in one place are moved to a totally different location by the algoritm (no blame to the algorithm!!) and so after each expand operation the user has to orient herself again. So in the end we considered this approach not to be suitable.
B2) Only re-arrange parts of the diagram after expanding a node
So we thought to not re-arrange the entire diagram after expansion, but to re-arrange only the nodes that were newly added during the expansion. Hereby we tried 2 different implementations:
a) Set the IgnoreLayout property to true for any nodes existing before the expansion actually happens and re-arrange the entire diagram after the new nodes (with IgnoreLayout set to false) have been added.
b) Call the layout algorithm's Arrange() method passing in a ChartObjectCollection containing only the nodes and arrows added during the expansion.
The issue that I noticed with this approach is that Arrange() does not seem to care about existing nodes when arranging the passed in new nodes. Result is that the new nodes are placed "on top" of existing nodes and thus the diagram becomes unreadable.
So after this lenghty introduction (I am sorry, but I wanted you to have some background info) here the question:
Can any of you think of any other way of getting nicely layouted diagrams after expanding nodes and thereby adding new ones? Is there maybe some tweak to the layout algorithms or some property that I might set to get better results?
It would be great, if you could share any experience with us.
Thanks,
Michael