This procedure is defined in the server but not documented via ad_proc or proc_doc and may be intended as a private interface.

The procedure is defined as:

proc dom::Trim {nodeid} {
    
    array set node [set $nodeid]

    switch -- $node(node:nodeType) {

        textNode {
            if {[string trim $node(node:nodeValue)] eq ""} {
                node removeChild $node(node:parentNode) $nodeid
            }
        }

        default {
            foreach child [set $node(node:childNodes)] {
                Trim $child
            }
        }

    }

    return {}

}

Show another procedure: