private void CreateAndRunSugiyamaLayout(Dictionary <DiagramShape, Size> sizeDictionary, BidirectionalGraph <DiagramShape, IEdge <DiagramShape> > graph, SugiyamaLayoutParameters parameters) { layoutAlgorithm = new SugiyamaLayoutAlgorithm <DiagramShape, IEdge <DiagramShape>, IBidirectionalGraph <DiagramShape, IEdge <DiagramShape> > >( graph, sizeDictionary, parameters, e => EdgeTypes.Hierarchical); layoutAlgorithm.Compute(); }
private void CreateAndRunEfficentSugiyamaLayout(Dictionary <DiagramShape, Size> sizeDictionary, BidirectionalGraph <DiagramShape, IEdge <DiagramShape> > graph) { layoutAlgorithm = new EfficientSugiyamaLayoutAlgorithm <DiagramShape, IEdge <DiagramShape>, IBidirectionalGraph <DiagramShape, IEdge <DiagramShape> > >( graph, new EfficientSugiyamaLayoutParameters(), sizeDictionary); layoutAlgorithm.Compute(); }
private void CreateAndRunKamadaKawaiiLayout(BidirectionalGraph <DiagramShape, IEdge <DiagramShape> > graph, double width, double height) { layoutAlgorithm = new KKLayoutAlgorithm <DiagramShape, IEdge <DiagramShape>, IBidirectionalGraph <DiagramShape, IEdge <DiagramShape> > >( graph, new KKLayoutParameters { Width = width, Height = height }); layoutAlgorithm.Compute(); }
public void Layout() { LayoutAlgorithm = new EfficientSugiyamaLayoutAlgorithm <AbstractBlock, Connection, YoloGraph>(this, new EfficientSugiyamaLayoutParameters() { VertexDistance = 20 }, new Dictionary <AbstractBlock, Size>()); LayoutAlgorithm.Compute(); }
private void CreateAndRunFruchtermanReingoldLayout(BidirectionalGraph <DiagramShape, IEdge <DiagramShape> > graph, double width, double height) { var positionDictionary = new Dictionary <DiagramShape, Point>(); foreach (var vertex in graph.Vertices) { positionDictionary.Add(vertex, vertex.Location); } var parameters = new BoundedFRLayoutParameters() { Width = width, Height = height, RepulsiveMultiplier = 2 }; layoutAlgorithm = new FRLayoutAlgorithm <DiagramShape, IEdge <DiagramShape>, IBidirectionalGraph <DiagramShape, IEdge <DiagramShape> > >( graph, positionDictionary, parameters); layoutAlgorithm.Compute(); }
private void CreateAndRunFruchtermanReingoldLayout(BidirectionalGraph<DiagramShape, IEdge<DiagramShape>> graph, double width, double height) { var positionDictionary = new Dictionary<DiagramShape, Point>(); foreach (var vertex in graph.Vertices) { positionDictionary.Add(vertex, vertex.Location); } var parameters = new BoundedFRLayoutParameters(){Width = width, Height = height, RepulsiveMultiplier = 2}; layoutAlgorithm = new FRLayoutAlgorithm<DiagramShape, IEdge<DiagramShape>, IBidirectionalGraph<DiagramShape, IEdge<DiagramShape>>>( graph, positionDictionary, parameters); layoutAlgorithm.Compute(); }
private void CreateAndRunEfficentSugiyamaLayout(Dictionary<DiagramShape, Size> sizeDictionary, BidirectionalGraph<DiagramShape, IEdge<DiagramShape>> graph) { layoutAlgorithm = new EfficientSugiyamaLayoutAlgorithm<DiagramShape, IEdge<DiagramShape>, IBidirectionalGraph<DiagramShape, IEdge<DiagramShape>>>( graph, new EfficientSugiyamaLayoutParameters(), sizeDictionary); layoutAlgorithm.Compute(); }
private void CreateAndRunSugiyamaLayout(Dictionary<DiagramShape, Size> sizeDictionary, BidirectionalGraph<DiagramShape, IEdge<DiagramShape>> graph, SugiyamaLayoutParameters parameters) { layoutAlgorithm = new SugiyamaLayoutAlgorithm<DiagramShape, IEdge<DiagramShape>, IBidirectionalGraph<DiagramShape, IEdge<DiagramShape>>>( graph, sizeDictionary, parameters, e => EdgeTypes.Hierarchical); layoutAlgorithm.Compute(); }
private void CreateAndRunKamadaKawaiiLayout(BidirectionalGraph<DiagramShape, IEdge<DiagramShape>> graph, double width, double height) { layoutAlgorithm = new KKLayoutAlgorithm<DiagramShape, IEdge<DiagramShape>, IBidirectionalGraph<DiagramShape, IEdge<DiagramShape>>>( graph, new KKLayoutParameters { Width = width, Height = height }); layoutAlgorithm.Compute(); }