This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at firstname.lastname@example.org
We have Flow Diagram that contains a lot of Comment Nodes. However, when we apply any layout algorithm, it does not apply for comment nodes.
We thought of 2 ways of dealing with this:
Option 1. Extend the nodes to be able to receive a connection from the Comment Node. Doing so, we also need to have a property that would hide all comment nodes and reorder the flow appropriately.
Option 2. Extend the basic nodes such that in addition to the Data, there is another Data associated to comments that could be entered by the user. Doing so, we would also need to have a property that would hide all comment nodes and reorder the flow appropriately.
We would like your insights and suggestions on our given options or other options that could easily resolve this situation.
If you've followed any of our code examples, you're probably setting the Info property of the layout algorithm to be a FlowDiagramLayoutAlgorithmInfo instance whose sole purpose is to prevent Comment nodes and Title nodes from being affected by the layout algorithm. If this is the case, you'll want to not set the Info property.
That said, the provided layout algorithms don't treat comment nodes in a special way, so they may not arrange them in the way you expect. If that's the case, you may need to implement a custom layout algorithm if comment nodes are to be treated with specialised logic.
Both options you provided should be possible, so you can pick which one you like best for your application. Sounds like they'll both require some kind of custom node implementing. The ActivityDiagrams sample provided with WPF Diagramming is a good source of examples for implementing nodes.