Add button navigation to treesit-explorer (bug#75141)
* lisp/treesit.el (treesit--explorer-tree-mode-map): Define it as a child of special-mode-map, adding keys for button navigation.
This commit is contained in:
parent
40fbed939a
commit
493bb2eaf1
1 changed files with 10 additions and 0 deletions
|
@ -4047,6 +4047,16 @@ covers point. PARSER-NAME are unique."
|
|||
"Mode for displaying syntax trees for `treesit-explore-mode'."
|
||||
nil)
|
||||
|
||||
(defvar-keymap treesit--explorer-tree-mode-map
|
||||
:doc "Keymap for the treesit tree explorer.
|
||||
|
||||
Navigates from button to button."
|
||||
:parent special-mode-map
|
||||
"n" #'forward-button
|
||||
"p" #'backward-button
|
||||
"TAB" #'forward-button
|
||||
"<backtab>" #'backward-button)
|
||||
|
||||
(defun treesit-explorer-switch-parser (parser)
|
||||
"Switch explorer to use PARSER."
|
||||
(interactive
|
||||
|
|
Loading…
Add table
Reference in a new issue