GMF Layout Algorithm for Graphiti [message #1609664] |
Tue, 10 February 2015 08:58 |
|
I have tried using the CompoundDirectedGraph and KIELER layout algorithm, but none of these are able to give me the desirable result, I wish to try the GMF layout algorithm for a try and see if I can get a better result for my Process Network.
Can someone suggest how can I achieve the same on my Diagram .
Regards,
Abhishek Chakraborty
|
|
|
Re: GMF Layout Algorithm for Graphiti [message #1611306 is a reply to message #1609664] |
Wed, 11 February 2015 09:29 |
|
This is how I have introduced the GMF layout in Graphiti.
int PADDING = 10;
final CompoundDirectedGraph graph = mapDiagramToGraph(d);
graph.setDirection(PositionConstants.EAST);
graph.setDefaultPadding(new Insets(PADDING));
// new CompoundDirectedGraphLayout().visit(graph);
// mapGraphCoordinatesToDiagram(graph);
new GMFDirectedGraphLayout().visit(graph);
// new CompositeDirectedGraphLayout().visit(graph);
mapGraphCoordinatesToDiagram(graph);
In the last method you need to map the draw 2d node and edge to graphiti Shape and Connection, and add the bendpoints too.
Regards,
Abhishek Chakraborty
|
|
|
Powered by
FUDForum. Page generated in 0.03917 seconds