Hi all
I am adding animation to a <g> element
everything is ok the first time I add & start it, then I stop the anim
and remove the <g> element.
The second time I try it, animation doesn't start.
How can I debug it?

I tried to save the svg when the second animation is created, and
squiggle plays it properly.


can you spot any error here?

//creating animation
        Element elt = getDocument().getElementById(tickerId);
        Element anim = getDocument().createElementNS(svgNS, "animate");
        anim.setAttributeNS(null, "id", animId);
        anim.setAttributeNS(null, "dur", String.valueOf(dur));
        //anim.setAttributeNS(null, "dur", "15");
        anim.setAttributeNS(null, "values", "0;26;51;76;102");
        anim.setAttributeNS(null, "begin", "indefinite");
        anim.setAttributeNS(null, "calcMode", "discrete");
        anim.setAttributeNS(null, "fill", "freeze");
        anim.setAttributeNS(null, "attributeName", "width");
        anim.setAttributeNS(null, "attributeType", "XML");
        //adding anim to ticker
        elt.appendChild(anim);


.....

//starting animation, sometimes ok, sometimes not
 Element elt = getDocument().getElementById(animId);
        if (elt != null) {
            boolean res = ((SVGAnimationElement) elt).beginElement();
            logger.info(animId + " res: " + res);
                //nb: res is always true!
        }




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to