Function: treemacs--collapse-tag-node-recursive

treemacs--collapse-tag-node-recursive is a byte-compiled function defined in treemacs-tags.el.

Signature

(treemacs--collapse-tag-node-recursive BTN)

Documentation

Recursively close tag section BTN.

Workaround for tag section having no easy way to purge all open tags below a button from cache. Easiest way is to just do it manually here.

Source Code

;; Defined in ~/.emacs.d/elpa/treemacs-20251226.1307/treemacs-tags.el
(defun treemacs--collapse-tag-node-recursive (btn)
  "Recursively close tag section BTN.
Workaround for tag section having no easy way to purge all open tags below a
button from cache.  Easiest way is to just do it manually here."
  (--each (treemacs-collect-child-nodes btn)
    (when (eq 'tag-node-open (treemacs-button-get it :state))
      (treemacs--collapse-tag-node-recursive it)
      (goto-char (treemacs-button-start it))
      (treemacs--collapse-tag-node it)))
  (goto-char (treemacs-button-start btn))
  (treemacs--collapse-tag-node btn))