<div dir="auto">This applies to how removing a DOM node with x3dom should behave. From an X3D point of view it probably should behave like group.removeChildren, which x3dom does. That means removing a DOM DEF node does not have an effect on a USE node.<div dir="auto"><br></div><div dir="auto">But from a DOM programming perspective this may be surprising since the USE instance now seems to refer to a null value.</div><div dir="auto"><br></div><div dir="auto">I think improving documentation may be all what is needed.</div><div dir="auto"><br></div><div dir="auto">Thanks again, Andreas</div><div dir="auto"><br><div data-smartmail="gmail_signature" dir="auto">---on the phone---</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jul 11, 2022, 2:08 PM Patrick Dähne <<a href="mailto:pdaehne@gmail.com">pdaehne@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
<br>
> Am 11.07.2022 um 19:27 schrieb Andreas Plesch <<a href="mailto:andreasplesch@gmail.com" target="_blank" rel="noreferrer">andreasplesch@gmail.com</a>>:<br>
> <br>
> On Mon, Jul 11, 2022, 12:34 PM Patrick Dähne <<a href="mailto:pdaehne@gmail.com" target="_blank" rel="noreferrer">pdaehne@gmail.com</a>> wrote:<br>
> > Thanks, very helpful. After the DEF name is removed, do the USE nodes still rrefer to the now nameless node ?<br>
> <br>
> Yes. The scene graph does not care about DEF and USE, it is only needed to serialize the scene graph into a textual representation.<br>
> <br>
> Ok.<br>
> <br>
> <br>
> <br>
> > Also, is there then a way to remove a node from the scene graph ?<br>
> <br>
> Yes, send events to fields (usually Group.children or Group.removeChildren).<br>
> <br>
> Presumably, outer.removeChildren(inner) would then just remove the child (DEF) node. The USE node would still refer to the (original) DEF node ? <br>
<br>
Yes.<br>
<br>
<br>
> Is there a way to remove all instances of a named node at once ?<br>
<br>
No.<br>
<br>
<br>
Bye,<br>
<br>
Patrick<br>
<br>
</blockquote></div>