Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

docs: Add clarifying note about Vim subword motion (#44535)

Will Garrisonf2cc24c5faa8
diff --git a/docs/src/vim.md b/docs/src/vim.md
index 9ba1b059223..09baa9b54f7 100644
--- a/docs/src/vim.md
+++ b/docs/src/vim.md
@@ -471,7 +471,7 @@ But you cannot use the same shortcuts to move between all the editor docks (the
}
```
-Subword motion, which allows you to navigate and select individual words in camelCase or snake_case, is not enabled by default. To enable it, add these bindings to your keymap.
+Subword motion, which allows you to navigate and select individual words in `camelCase` or `snake_case`, is not enabled by default. To enable it, add these bindings to your keymap.
```json [settings]
{
@@ -485,6 +485,9 @@ Subword motion, which allows you to navigate and select individual words in came
}
```
+> Note: Operations like `dw` remain unaffected. If you would like operations to
+> also use subword motion, remove `vim_mode != operator` from the `context`.
+
Vim mode comes with shortcuts to surround the selection in normal mode (`ys`), but it doesn't have a shortcut to add surrounds in visual mode. By default, `shift-s` substitutes the selection (erases the text and enters insert mode). To use `shift-s` to add surrounds in visual mode, you can add the following object to your keymap.
```json [settings]