in reply to Building a tree 1 leaf at a time

“There’s More Than One Way To Do It,™” yes yes, but there is also much to be said for “get ’er done.”   You seem to have developed a one-page solution to your problem that does not require a five-hundred pound gorilla (XSH2) to ride along with you.   I feel that I could read it in a couple minutes and (if I had read it) convince myself that it was correct.   If it were me, I’d take what you now have, and move along.