diff options
author | 再生花 <hoangtun0810@gmail.com> | 2024-02-23 05:58:59 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-22 14:58:59 -0600 |
commit | bb15fa035610bb9765ca16900703804a88faa3bb (patch) | |
tree | c3531fb1162c8fadf2aaecb6f308fdd24f92ba0c /runtime/lua/vim/treesitter.lua | |
parent | 85cb0b0ddc59cd1b3a911e5b4a358e5404c1d0d8 (diff) | |
download | rneovim-bb15fa035610bb9765ca16900703804a88faa3bb.tar.gz rneovim-bb15fa035610bb9765ca16900703804a88faa3bb.tar.bz2 rneovim-bb15fa035610bb9765ca16900703804a88faa3bb.zip |
feat(treesitter): add folding for `InspectTree` (#27518)
As the InspectTree buffer is now a valid tree-sitter query tree, we can
use the bundled fold queries to have folding for the tree.
Diffstat (limited to 'runtime/lua/vim/treesitter.lua')
-rw-r--r-- | runtime/lua/vim/treesitter.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/runtime/lua/vim/treesitter.lua b/runtime/lua/vim/treesitter.lua index 88b68ff658..2aa46ceebd 100644 --- a/runtime/lua/vim/treesitter.lua +++ b/runtime/lua/vim/treesitter.lua @@ -461,7 +461,8 @@ end --- --- While in the window, press "a" to toggle display of anonymous nodes, "I" to toggle the --- display of the source language of each node, "o" to toggle the query editor, and press ---- <Enter> to jump to the node under the cursor in the source buffer. +--- <Enter> to jump to the node under the cursor in the source buffer. Folding also works +--- (try |zo|, |zc|, etc.). --- --- Can also be shown with `:InspectTree`. *:InspectTree* --- |