From f3df26b6b34f16f6cbc4b9b1f4028220ab523f5a Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 2 Jan 2025 09:16:11 +0800 Subject: [PATCH] docs(core): update doc about quickfix mappings --- docs/cn/layers/core.md | 21 +++++++++++++++++++++ docs/layers/core.md | 22 ++++++++++++++++++++++ 2 files changed, 43 insertions(+) diff --git a/docs/cn/layers/core.md b/docs/cn/layers/core.md index 4d4712d82..9b8504436 100644 --- a/docs/cn/layers/core.md +++ b/docs/cn/layers/core.md @@ -40,3 +40,24 @@ nerdtree 或者 vimfiler,默认为 vimfiler,由 `filemanager` 选项控制 filetree_opened_icon = '' filetree_closed_icon = '' ``` + +如果 `enable_quickfix_key_bindings` 设置为 `true`,那么可以在 quickfix 窗口内使用如下快捷键: + +| Key bindings | description | +| ------------ | ---------------------------------------------------------- | +| `dd` | remove item under cursor line in normal mode | +| `d` | remove selected items in visual mode | +| `c` | remove items which filename match input regex | +| `C` | remove items which filename not match input regex | +| `o` | remove items which error description match input regex | +| `O` | remove items which error description not match input regex | + +也可以在启动函数里面使用如下变量修改默认的按键: + +- `g:quickfix_mapping_delete`: default is `dd` +- `g:quickfix_mapping_visual_delete`: default is `d` +- `g:quickfix_mapping_filter_filename`: default is `c` +- `g:quickfix_mapping_rfilter_filename`: default is `C` +- `g:quickfix_mapping_filter_text`: default is `o` +- `g:quickfix_mapping_rfilter_text`: default is `O` + diff --git a/docs/layers/core.md b/docs/layers/core.md index da0f1386e..1322a045e 100644 --- a/docs/layers/core.md +++ b/docs/layers/core.md @@ -48,3 +48,25 @@ To use defx, please add following snippet into your configuration file. filetree_opened_icon = '' filetree_closed_icon = '' ``` + +If `enable_quickfix_key_bindings` is `true`, The following key bindings can be used in quickfix window, +and which also can be change in bootstrap function. + +| Key bindings | description | +| ------------ | ---------------------------------------------------------- | +| `dd` | remove item under cursor line in normal mode | +| `d` | remove selected items in visual mode | +| `c` | remove items which filename match input regex | +| `C` | remove items which filename not match input regex | +| `o` | remove items which error description match input regex | +| `O` | remove items which error description not match input regex | + +Options to change these mappings: + +- `g:quickfix_mapping_delete`: default is `dd` +- `g:quickfix_mapping_visual_delete`: default is `d` +- `g:quickfix_mapping_filter_filename`: default is `c` +- `g:quickfix_mapping_rfilter_filename`: default is `C` +- `g:quickfix_mapping_filter_text`: default is `o` +- `g:quickfix_mapping_rfilter_text`: default is `O` +