diff options
author | lurpahi | 2021-09-24 01:28:44 +0000 |
---|---|---|
committer | GitHub | 2021-09-24 01:28:44 +0000 |
commit | a958d34bfbcf45c01ce0d9c0d76e681fb863fc6a (patch) | |
tree | 7993d194fafd1d32806538fe34292b6ae37429b8 /helix-view | |
parent | 432bec10eddb3f51f3a6e32aedbfd566d74cde75 (diff) |
Add option for automatic insertion of closing-parens/brackets/etc (#779)
* Add auto-pair editor option
* Document auto-pair editor option
* Make cargo fmt happy
* Actually make cargo fmt happy
* Rename auto-pair option to auto-pairs
* Inline a few constants
Co-authored-by: miaomai <cunso@tutanota.com>
Diffstat (limited to 'helix-view')
-rw-r--r-- | helix-view/src/editor.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/helix-view/src/editor.rs b/helix-view/src/editor.rs index b7df4a9b..b08a2df2 100644 --- a/helix-view/src/editor.rs +++ b/helix-view/src/editor.rs @@ -41,6 +41,8 @@ pub struct Config { pub middle_click_paste: bool, /// Smart case: Case insensitive searching unless pattern contains upper case characters. Defaults to true. pub smart_case: bool, + /// Automatic insertion of pairs to parentheses, brackets, etc. Defaults to true. + pub auto_pairs: bool, } #[derive(Debug, Clone, PartialEq, Eq, Deserialize)] @@ -67,6 +69,7 @@ impl Default for Config { line_number: LineNumber::Absolute, middle_click_paste: true, smart_case: true, + auto_pairs: true, } } } |