diff --git a/docs/major-mode.md b/docs/major-mode.md index 56a5372..839949c 100644 --- a/docs/major-mode.md +++ b/docs/major-mode.md @@ -6,10 +6,15 @@ title: Major Mode Major mode offers dynamic menu and functions based on the active buffer. You can access key bindings specific to the current major mode by pressing ` m` or `,` if you want to save one keystroke. -:::note +:::tip If `,` isn't bound, you might need to update your settings. You can add the necessary keybindings to your `settings.json` by pressing `Ctrl+Shift+p` and running the command "VSpaceCode: Configure Default Settings". -More information can be found in the [Installation](./) instructions. +More information can be found in the [Installation](./) for instructions. +::: + +:::note +The default configuration uses `,` as the shortcut to major mode, that will override the vim "find previous match" after a `f{character}`. +You can follow the instructions in [Troubleshooting](./troubleshooting#-cannot-find-previous-match) to remove or modify this shortcut. ::: For example, you can press ` m x b` to make the text bold in a markdown buffer. diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md index 79eb08f..42c18ed 100644 --- a/docs/troubleshooting.md +++ b/docs/troubleshooting.md @@ -25,6 +25,28 @@ If you don't use this feature, disabling it should fix this issue. Otherwise, ad ], ``` +## `,` cannot find previous match + +The default VSpaceCode configuration overrides `,` as a shortcut for the [major mode](./major-mode.md); +therefore, the key `,` cannot get back to the previous match after a find `f{character}` with Vim. + +In order to remove this major mode shortcut, remove the following section from your `settings.json`: + +```json +{ + "before": [","], + "commands": [ + "vspacecode.space", + { + "command": "whichkey.triggerKey", + "args": "m" + } + ], +} +``` + +Alternatively, you can change the shortcut key by changing `","` in `"before"` to other keys. + ## Unresponsive menu activation If you press `` on a buffer and the which-key menu doesn't appear immediately, you might have one of the following problems.