diff options
Diffstat (limited to 'docs/user')
-rw-r--r-- | docs/user/features.md | 6 | ||||
-rw-r--r-- | docs/user/readme.adoc | 14 |
2 files changed, 18 insertions, 2 deletions
diff --git a/docs/user/features.md b/docs/user/features.md index 340bce835..12ecdec13 100644 --- a/docs/user/features.md +++ b/docs/user/features.md | |||
@@ -93,6 +93,12 @@ Shows internal statistic about memory usage of rust-analyzer. | |||
93 | 93 | ||
94 | Show current rust-analyzer version. | 94 | Show current rust-analyzer version. |
95 | 95 | ||
96 | #### Toggle inlay hints | ||
97 | |||
98 | Toggle inlay hints view for the current workspace. | ||
99 | It is recommended to assign a shortcut for this command to quickly turn off | ||
100 | inlay hints when they prevent you from reading/writing the code. | ||
101 | |||
96 | #### Run Garbage Collection | 102 | #### Run Garbage Collection |
97 | 103 | ||
98 | Manually triggers GC. | 104 | Manually triggers GC. |
diff --git a/docs/user/readme.adoc b/docs/user/readme.adoc index 40ed54809..64bd0feb1 100644 --- a/docs/user/readme.adoc +++ b/docs/user/readme.adoc | |||
@@ -9,8 +9,6 @@ | |||
9 | :caution-caption: :fire: | 9 | :caution-caption: :fire: |
10 | :warning-caption: :warning: | 10 | :warning-caption: :warning: |
11 | 11 | ||
12 | |||
13 | |||
14 | // Master copy of this document lives in the https://github.com/rust-analyzer/rust-analyzer repository | 12 | // Master copy of this document lives in the https://github.com/rust-analyzer/rust-analyzer repository |
15 | 13 | ||
16 | At its core, rust-analyzer is a *library* for semantic analysis of Rust code as it changes over time. | 14 | At its core, rust-analyzer is a *library* for semantic analysis of Rust code as it changes over time. |
@@ -21,6 +19,8 @@ The LSP allows various code editors, like VS Code, Emacs or Vim, to implement se | |||
21 | To improve this document, send a pull request against | 19 | To improve this document, send a pull request against |
22 | https://github.com/rust-analyzer/rust-analyzer/blob/master/docs/user/readme.adoc[this file]. | 20 | https://github.com/rust-analyzer/rust-analyzer/blob/master/docs/user/readme.adoc[this file]. |
23 | 21 | ||
22 | If you have questions about using rust-analyzer, please ask them in the https://users.rust-lang.org/c/ide/14["`IDEs and Editors`"] topic of Rust users forum. | ||
23 | |||
24 | == Installation | 24 | == Installation |
25 | 25 | ||
26 | In theory, one should be able to just install the <<rust-analyzer-language-server-binary,`rust-analyzer` binary>> and have it automatically work with any editor. | 26 | In theory, one should be able to just install the <<rust-analyzer-language-server-binary,`rust-analyzer` binary>> and have it automatically work with any editor. |
@@ -65,6 +65,16 @@ The server binary is stored in: | |||
65 | 65 | ||
66 | Note that we only support two most recent versions of VS Code. | 66 | Note that we only support two most recent versions of VS Code. |
67 | 67 | ||
68 | ==== Special `when` clause context for keybindings. | ||
69 | You may use `inRustProject` context to configure keybindings for rust projects only. For example: | ||
70 | [source,json] | ||
71 | ---- | ||
72 | { "key": "ctrl+shift+f5", "command": "workbench.action.debug.restart", "when": "inDebugMode && !inRustProject"}, | ||
73 | { "key": "ctrl+shift+f5", "command": "rust-analyzer.debug", "when": "inRustProject"}, | ||
74 | { "key": "ctrl+i", "command": "rust-analyzer.toggleInlayHints", "when": "inRustProject" } | ||
75 | ---- | ||
76 | More about `when` clause contexts https://code.visualstudio.com/docs/getstarted/keybindings#_when-clause-contexts[here]. | ||
77 | |||
68 | ==== Updates | 78 | ==== Updates |
69 | 79 | ||
70 | The extension will be updated automatically as new versions become available. It will ask your permission to download the matching language server version binary if needed. | 80 | The extension will be updated automatically as new versions become available. It will ask your permission to download the matching language server version binary if needed. |