how to ungroup g ?
#Hi ! I found undrag , unclick method. but where is ungroup ?
here is my svg
<g transform="matrix(1,0,0,1,139,35)"><rect x="150" y="150" width="50" height="50" fill="#ffffff" stroke="#000000" style="stroke-width: 4; opacity: 0.5;" class="jtool got"></rect><circle cx="150" cy="150" r="25" fill="#ffffff" stroke="#000000" style="stroke-width: 4; opacity: 0.5;" class="jtool got"></circle></g>
thank you !
It's not really clear what you would want from this. Group is an svg element, not a handler. If you want to remove an element from a group, you can just add/append the element again somewhere else (not in the group).
thank you sir ! I made an example for my question.
https://jsfiddle.net/taiwanhotdog/1nzo7pL4/
step 1. mouse drag select two shapes. step 2. drag group to any position. step 3. click ungroup button.
after ungorup the new position is wrong !
I just get an error 'selections is not defined'
sorry , try again please https://jsfiddle.net/taiwanhotdog/1nzo7pL4/1/
Still doesn't do anything. I think this is probably better a question for Stackoverflow, I don't really see any bug here, unless it's just a feature request, but you should be able to just append the element, and then set any transformations you want on it (eg the transformation that the group had plus the element), that's more of a coding/logic issue.
thank you sir ! I found this issue . I had same issue https://github.com/adobe-webplatform/Snap.svg/issues/277