Status: New Owner: ---- Labels: Type-Defect Priority-Medium Component-Roassal
New issue 938 by tu...@tudorgirba.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Try this: view nodes: (Collection withAllSubclasses). view edgesFrom: #superclass. view radialTreeLayout.
The center of the graph is placed at 0@0, and this is annoying because you do not see half of the graph. The layout should translate the graph to make it start at 0@0
Updates: Status: Started
Comment #1 on issue 938 by alexandr...@gmail.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
This should not belong to the layout I have the impression. Where to position the camera against the nodes the view contains is the real question in my opinion. Probably that the other layout are not doing it in the right way.
I have added ROFocusView class>>centerView: The Mondrian builder has been updated accordingly. For example: -=-=-=-=-=-=-=-=-= view nodes: (Collection withAllSubclasses). view edgesFrom: #superclass. view radialTreeLayout. view center. -=-=-=-=-=-=-=-=-=
produces what is expected.
In Roassal 1.356. Doru, if you agree with this, then close the issue.
Comment #2 on issue 938 by tu...@tudorgirba.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
I think the ability to center the view is nice, but it does not solve the layout problem.
The layout positions nodes. So, there is no reason why the layout should not start positioning nodes at 0@0. And there is no reason for the default camera to not start at 0@0.
Or am I wrong?
Updates: Cc: alexandr...@gmail.com
Comment #3 on issue 938 by tu...@tudorgirba.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Any taker? :)
Comment #4 on issue 938 by alexandr...@gmail.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Actually, I think the radial tree layout does the right think. 0 @ 0 should be at the middle of the window. No reason to have it top left corner. The way layouts are implemented, prevent them from being composed (e.g., there is no easy way to layout a tree with a root node that is not in 0 @ 0).
Comment #5 on issue 938 by tu...@tudorgirba.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
I do not get it. I am talking about the user, not the internal implementation.
I apply the layout, and two thirds of the graph cannot be seen. How is that the right thing?
The only thing that would be required would be to perform a translation of the whole graph (or maybe only of the camera) after the layout algorithm finished. This would be a linear algorithm depending on the number of nodes.
Comment #6 on issue 938 by tu...@tudorgirba.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Ping? :)
Comment #7 on issue 938 by alexandr...@gmail.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Mathieu and I are working on this... We will need a few days more...
Updates: Status: Fixed
Comment #8 on issue 938 by alexandr...@gmail.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Sorry to have been that slow on this.
| rawView nodes edges | rawView := ROView new.
nodes := (ROEllipse gray size: 10) elementsOn: Collection withAllSubclasses.
nodes do: [ :n | n @ RODraggable ].
rawView addAll: nodes.
edges := ROLine buildEdgesFromElements: nodes from: #superclass to: #yourself.
rawView addAll: edges.
RORadialTreeLayout new "translator: (ROSmoothLayoutTranslator new nbCycles: 10);" applyOn: nodes. rawView openInWindowSized: 1000 @ 600.
Comment #9 on issue 938 by alexandr...@gmail.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Forgot to say this is now fixed in Roassal 1.458
Updates: Labels: Milestone-4.9
Comment #10 on issue 938 by tu...@tudorgirba.com: RadialTreeLayout should translate the graph http://code.google.com/p/moose-technology/issues/detail?id=938
Great!