- From: guilhelm savin <guilhelm.savin AT gmail.com>
- To: graphstream-users AT litislab.fr, Filippo Bistaffa <filippo.bistaffa AT gmail.com>
- Subject: Re: Run SpringBox Layout again
- Date: Wed, 21 Dec 2011 16:38:50 +0100
Hi Filippo,
I think the fact that layout does not restart when adding new elements
is a bug. We will look at this as swiftly as possible.
However, you have temporary solutions :
1. set the stabilization limit to 0
|
| Graph g = ...;
| SpringBox box = new SpringBox(false);
|
| Viewer v = g.display(false);
| v.enableAutoLayout(box);
|
| box.setStabilizationLimit(0);
|
Another solution could be to call the "shake()" method of
SpringBox when you need to compute new coordinates but this
should lead to a concurrent exception since the layout is
running in its own thread.
Hope this helps ...
Regards.
Guilhelm
2011/12/21 Filippo Bistaffa
<filippo.bistaffa AT gmail.com>
How can I force the SpringBox Layout run again on a graph? I need to do this after I add/remove some nodes/edges, and the visualization is already running.
So far I've tried this:
new LayoutRunner(g, new SpringBox(), true);
(g is the graph), but it's not working
--
Guilhelm Savin
PhD Student of Computer ScienceLITIS, University of Le Havre
\/\/\/\/\/\/
Archives gérées par MHonArc 2.6.16.