Hi Maik,

Maik Sch�rer wrote:

a reapply of getParentElement().appendChild(theElement) works fine to bring theElement to top.
But why is a previous removeChild() unnecessary ?

Because appendChild (and essentially all insert/add DOM methods) are defined to call 'e.getParentElement().removeChild(e)' - assuming that 'e' has a parent - before appending.

Is the parent element so clever to make a "reappend" only ?

I'm not sure what you mean by 'reappend' but it is smart enough to 'remove' it when needed before adding it. In fact two DOM mutation events are generated (one for remove, one for append).


Andreas Neumann schrieb:

Hi,

http://www.carto.net/papers/svg/manipulating_svg_with_dom_ecmascript/ is a tutorial with small examples on manipulating the DOM. Amongst others it also discusses reordering of elements.

The examples where tested with Batik and Adobe SVG viewer.

Andreas

Maik Sch�rer wrote:

Hi there,
I have several overlapped elements on my canvas.
How can I one of these to the foreground (on top of all) ?
Maik


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





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



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



Reply via email to