How could I add a parent to a node? #628
|
Original xml The xml output I want I can append as a child under measure by append_child, but how could I make every elements under measure as the child of ? Thanks |
Answered by
zeux
Sep 12, 2024
Replies: 2 comments 1 reply
|
append_child + append_move for all other children of Note that you will need to be careful about iterating, as append_move changes the sibling structure; you could do something like |
1 reply
Answer selected by
stereomatchingkiss
|
Fix the bug, just change
to
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
append_child + append_move for all other children of
measure; see https://pugixml.org/docs/manual.html#modify.moveNote that you will need to be careful about iterating, as append_move changes the sibling structure; you could do something like