Variable: treemacs-indent-guide-mode

treemacs-indent-guide-mode is a customizable variable defined in treemacs-visuals.el.

Value

nil

Documentation

Non-nil if Treemacs-Indent-Guide mode is enabled.

See the treemacs-indent-guide-mode(var)/treemacs-indent-guide-mode(fun) command for a description of this minor mode. Setting this variable directly does not take effect; either customize it (see the info node (emacs)Easy Customization) or call the function treemacs-indent-guide-mode(var)/treemacs-indent-guide-mode(fun).

Key Bindings

Source Code

;; Defined in ~/.emacs.d/elpa/treemacs-20251226.1307/treemacs-visuals.el
(define-minor-mode treemacs-indent-guide-mode
  "Toggle `treemacs-indent-guide-mode'.
When enabled treemacs will show simple indent guides for its folder structure.
The effect is achieved by overriding the values of `treemacs-indentation' and
`treemacs-indentation-string'.  Disabling the mode will restore the previously
used settings."
  :init-value nil
  :global     t
  :lighter    nil
  :group      'treemacs
  (if treemacs-indent-guide-mode
      (progn
        (setf
         treemacs--saved-indent-settings
         (cons treemacs-indentation treemacs-indentation-string)
         treemacs-indentation 1
         treemacs-indentation-string
         (pcase-exhaustive treemacs-indent-guide-style
           ('line  (propertize " ┃ " 'face 'font-lock-comment-face))
           ('block (list
                    "  "
                    (propertize "██" 'face 'font-lock-comment-face))))))
    (setf treemacs-indentation (car treemacs--saved-indent-settings)
          treemacs-indentation-string (cdr treemacs--saved-indent-settings)))
  (treemacs-without-messages
   (treemacs-run-in-every-buffer
    (treemacs--do-refresh (current-buffer) 'all))))