aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorStephan Seitz <stephan.seitz@fau.de>2020-08-02 19:35:52 +0200
committerStephan Seitz <stephan.seitz@fau.de>2020-08-17 17:44:40 +0200
commite629efafd8f529ff9b1297b947b4438bf4d2265c (patch)
tree83d60021573cbba25b0a829b8417297e13dbda0e /doc
parentTextobjects: Add goto_adjacent (diff)
downloadnvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.tar
nvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.tar.gz
nvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.tar.bz2
nvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.tar.lz
nvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.tar.xz
nvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.tar.zst
nvim-treesitter-e629efafd8f529ff9b1297b947b4438bf4d2265c.zip
Textobjects: provide mappings for all swap/goto functions
Diffstat (limited to 'doc')
-rw-r--r--doc/nvim-treesitter.txt26
1 files changed, 25 insertions, 1 deletions
diff --git a/doc/nvim-treesitter.txt b/doc/nvim-treesitter.txt
index ed992e2d9..1f2d87569 100644
--- a/doc/nvim-treesitter.txt
+++ b/doc/nvim-treesitter.txt
@@ -94,7 +94,31 @@ By default, everything is disabled. To enable support for features, in your `ini
["ad"] = "@comment.outer",
["am"] = "@call.outer",
["im"] = "@call.inner"
- }
+ },
+ -- swap parameters (keymap -> textobject query)
+ swap_next = {
+ ["<a-p>"] = "@parameter.inner",
+ },
+ swap_previous = {
+ ["<a-P>"] = "@parameter.inner",
+ },
+ -- set mappings to go to start/end of adjacent textobjects (keymap -> textobject query)
+ goto_previous_start = {
+ ["[m"] = "@function.outer",
+ ["[["] = "@class.outer",
+ },
+ goto_previous_end = {
+ ["[M"] = "@function.outer",
+ ["[]"] = "@class.outer",
+ },
+ goto_next_start = {
+ ["]m"] = "@function.outer",
+ ["]]"] = "@class.outer",
+ },
+ goto_next_end = {
+ ["]M"] = "@function.outer",
+ ["]["] = "@class.outer",
+ },
},
ensure_installed = "all" -- one of "all", "language", or a list of languages
}