diff options
author | JJ | 2023-11-01 01:14:55 +0000 |
---|---|---|
committer | JJ | 2023-11-01 04:08:40 +0000 |
commit | 368995b51f2b0b8574a87ebe04749cb556b4c538 (patch) | |
tree | eadf3985f5d1f703542a1df7759b0d84b79e6a46 /helix-view/src/editor.rs | |
parent | eaf8d6d30da5014a3c475c4187b9dccfe621afd5 (diff) |
Add rainbow indentation guides
ref: https://github.com/helix-editor/helix/issues/4010
ref: https://github.com/helix-editor/helix/pull/4493
Co-authored-by: SoraTenshi <dream@neoncity.dev>
Diffstat (limited to 'helix-view/src/editor.rs')
-rw-r--r-- | helix-view/src/editor.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/helix-view/src/editor.rs b/helix-view/src/editor.rs index fbfed656..b2615c9f 100644 --- a/helix-view/src/editor.rs +++ b/helix-view/src/editor.rs @@ -765,11 +765,20 @@ impl Default for WhitespaceCharacters { } #[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)] +#[serde(rename_all = "kebab-case")] +pub enum RainbowIndentOptions { + None, + Dim, + Normal, +} + +#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)] #[serde(default, rename_all = "kebab-case")] pub struct IndentGuidesConfig { pub render: bool, pub character: char, pub skip_levels: u8, + pub rainbow_option: RainbowIndentOptions, } impl Default for IndentGuidesConfig { @@ -778,6 +787,7 @@ impl Default for IndentGuidesConfig { skip_levels: 0, render: false, character: '│', + rainbow_option: RainbowIndentOptions::None, } } } |