Closed iamrakesh closed 8 years ago
I don't think we ship the fixed layout algorithm with the JavaScript version (my colleague will correct me if I'm wrong there). However, regarding your use case: fixing node positions and only routing edges is actually something we don't support.
Actually, we do ship the fixed layouter in js. I'll check your example later.
I tried to change one of the example .json files with the fixed layout property, please find the attached sample.
You have to explicitly set the layoutHierarchy
option to false
. Otherwise the klay.layered
algorithm is executed right from the start. I'll add that to the documentation.
ok, will check that. any possibility of adding support for only edge routing (old ticket with 'wont fix' status - http://rtsys.informatik.uni-kiel.de/jira/browse/KIPRA-1403)?
There are no short-term plans to add standalone edge routing. Nevertheless, since it's a frequent request, we may look into it in the future.
If we run layout on json data like below (assume edges have bendpoints as well) { id: 'root', properties: { algorithm: 'de.cau.cs.kieler.fixed' }, children: [ { id: '1', x: 100, y : 25},{id: '2', x: 200, y: 45},{id: '3', x: 200, y: 20} ], edges: [ {source: '1', target: '2'}, {source: '1', target: '3'},{source: '3', target: '2'} ] }
'algorithm' property is not considered and x, y positions for nodes get re-calculated.
Is this property supported for JavaScript version?
To elaborate more, what I am trying is to use klayjs to layout a workflow, and allow user to drag nodes to different position on the browser. At this point I wanted to avoid node position calculation, but want edge bend point calculation only.
is there any other way to achieve this?