You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by rofl <ro...@lummert.net> on 2006/06/05 20:33:17 UTC

ECMAScript generated nodes

Hello forum,

I have an SVG-App that generates parts off its contents 'onload' with
some ECMAScript. But with the usual methods I can't make the
generated nodes visible in my SVGCanvas. Attribute manipulation done
later by other ECMAScript is visible immediately though.
Setting JSVGCanvas.ALWAYS_DYNAMIC didn't solve the problem and
methods to invoke a rerendering like startGVTTreeBuilder seem all to
be protected.
Any ideas?
TIA,

     Robert

--
View this message in context: http://www.nabble.com/ECMAScript-generated-nodes-t1736928.html#a4719874
Sent from the Batik - Users forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Re: ECMAScript generated nodes

Posted by rofl <ro...@lummert.net>.
Thanks a lot, Thomas!

Using createElementNS with the svg namespace instead of
createElement solved the problem.

Cheers,

     Robert

--
View this message in context: http://www.nabble.com/ECMAScript-generated-nodes-t1736928.html#a4738986
Sent from the Batik - Users forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Re: ECMAScript generated nodes

Posted by th...@kodak.com.
Hi Robert,

rofl <ro...@lummert.net> wrote on 06/05/2006 02:33:17 PM:

> I have an SVG-App that generates parts off its contents 'onload' with
> some ECMAScript. But with the usual methods I can't make the
> generated nodes visible in my SVGCanvas. Attribute manipulation done
> later by other ECMAScript is visible immediately though.

   I suspect a bug in your ECMAScript.  There is no significant
difference between script run 'onload' and later.  The most
common problem is namespaces.  If you are used to the Adobe
Viewer your scripts may not create elements in the SVG Namespace
in which case they are _not_ SVG elements and they are not
rendered.

> Setting JSVGCanvas.ALWAYS_DYNAMIC didn't solve the problem and
> methods to invoke a rerendering like startGVTTreeBuilder seem all to
> be protected.

   In fact the first rendering takes place after all 'onload'
scripts are run, so the canvas is rendering after your changes.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org