!7 static Timer timer; static Canvas canvas; static CALSpringLayout layout; p-subst { final new CirclesAndLines cal; Circle a = cal.circle_autoVis("Hello", 0.2, 0.5); Circle b = cal.circle_autoVis("World", 0.8, 0.5); cal.arrow(a, "", b); canvas = showCAL(cal); layout = new CALSpringLayout(cal); addToWindow(canvas, jcenteredline(jbutton("Start/Stop", r { if (timer != null) { cancelTimer(timer); timer = null; } else startTimer(); }))); } svoid startTimer { timer = awtCalcEvery2(canvas, 100, r { layout.step(); updateCanvas(canvas); }); }