Class FishboneLayout

GoDiagram®
v10.0.11
by Northwoods Software®

FishboneLayout is a custom Layout derived from TreeLayout for creating "fishbone" diagrams. A fishbone diagram also requires a Link class that implements custom routing, FishboneLink.

Namespace: Northwoods.Go.Layouts.Extensions
Assembly: FishboneWinForms.dll
Syntax
public class FishboneLayout : TreeLayout
Remarks

This only works for angle == 0 or angle == 180.

This layout assumes Links are automatically routed in the way needed by fishbone diagrams by using the FishboneLink class instead of Link.

Constructors

FishboneLayout()

Create a Fishbone layout.

Declaration
public FishboneLayout()

Methods

AssignTreeVertexValues(TreeVertex)

Add a direction property to each vertex and modify LayerSpacing.

Declaration
protected override void AssignTreeVertexValues(TreeVertex v)
Parameters
Type Name Description
TreeVertex v
Overrides

This override stops links from being committed since the work is handled by the FishboneLink class.

Declaration
protected override void CommitLinks()
Overrides

CommitNodes()

Commit the position of all nodes.

Declaration
protected override void CommitNodes()
Overrides
Remarks

This is called by CommitLayout(). Please read the Introduction page on Extensions for how to override methods and how to call this base method.

See Also

MakeNetwork(IEnumerable<Part>)

Create and initialize a TreeNetwork with the given nodes and links. This override creates dummy vertexes, when necessary, to allow for proper positioning within the fishbone.

Declaration
public override TreeNetwork MakeNetwork(IEnumerable<Part> coll = null)
Parameters
Type Name Description
IEnumerable<Part> coll
Returns
Type Description
TreeNetwork

TreeNetwork

Overrides

Shift(TreeVertex)

Shifts subtrees within the fishbone based on angle and node spacing.

Declaration
public void Shift(TreeVertex v)
Parameters
Type Name Description
TreeVertex v

ShiftAll(int, double, TreeVertex, TreeVertex)

Shifts a subtree.

Declaration
public void ShiftAll(int direction, double absolute, TreeVertex root, TreeVertex v)
Parameters
Type Name Description
int direction
double absolute
TreeVertex root
TreeVertex v