mirror of https://github.com/helix-editor/helix
Compare commits
No commits in common. "3d4125bd3f29d119f375613428a73a3cd52cda34" and "601fcb1aea015f586228a733a54e8efb23b6b2d9" have entirely different histories.
3d4125bd3f
...
601fcb1aea
|
@ -104,8 +104,6 @@ separator = "│"
|
||||||
mode.normal = "NORMAL"
|
mode.normal = "NORMAL"
|
||||||
mode.insert = "INSERT"
|
mode.insert = "INSERT"
|
||||||
mode.select = "SELECT"
|
mode.select = "SELECT"
|
||||||
diagnostics = ["warning", "error"]
|
|
||||||
workspace-diagnostics = ["warning", "error"]
|
|
||||||
```
|
```
|
||||||
The `[editor.statusline]` key takes the following sub-keys:
|
The `[editor.statusline]` key takes the following sub-keys:
|
||||||
|
|
||||||
|
@ -118,8 +116,6 @@ The `[editor.statusline]` key takes the following sub-keys:
|
||||||
| `mode.normal` | The text shown in the `mode` element for normal mode | `"NOR"` |
|
| `mode.normal` | The text shown in the `mode` element for normal mode | `"NOR"` |
|
||||||
| `mode.insert` | The text shown in the `mode` element for insert mode | `"INS"` |
|
| `mode.insert` | The text shown in the `mode` element for insert mode | `"INS"` |
|
||||||
| `mode.select` | The text shown in the `mode` element for select mode | `"SEL"` |
|
| `mode.select` | The text shown in the `mode` element for select mode | `"SEL"` |
|
||||||
| `diagnostics` | A list of severities which are displayed for the current buffer | `["warning", "error"]` |
|
|
||||||
| `workspace-diagnostics` | A list of severities which are displayed for the workspace | `["warning", "error"]` |
|
|
||||||
|
|
||||||
The following statusline elements can be configured:
|
The following statusline elements can be configured:
|
||||||
|
|
||||||
|
|
|
@ -304,7 +304,7 @@ where
|
||||||
write(context, " W ".into(), None);
|
write(context, " W ".into(), None);
|
||||||
}
|
}
|
||||||
|
|
||||||
for sev in &context.editor.config().statusline.workspace_diagnostics {
|
for sev in &context.editor.config().statusline.w_diagnostics {
|
||||||
match sev {
|
match sev {
|
||||||
Severity::Hint if hints > 0 => {
|
Severity::Hint if hints > 0 => {
|
||||||
write(
|
write(
|
||||||
|
|
|
@ -498,7 +498,7 @@ pub struct StatusLineConfig {
|
||||||
pub separator: String,
|
pub separator: String,
|
||||||
pub mode: ModeConfig,
|
pub mode: ModeConfig,
|
||||||
pub diagnostics: Vec<Severity>,
|
pub diagnostics: Vec<Severity>,
|
||||||
pub workspace_diagnostics: Vec<Severity>,
|
pub w_diagnostics: Vec<Severity>,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Default for StatusLineConfig {
|
impl Default for StatusLineConfig {
|
||||||
|
@ -524,7 +524,7 @@ impl Default for StatusLineConfig {
|
||||||
separator: String::from("│"),
|
separator: String::from("│"),
|
||||||
mode: ModeConfig::default(),
|
mode: ModeConfig::default(),
|
||||||
diagnostics: vec![Severity::Warning, Severity::Error],
|
diagnostics: vec![Severity::Warning, Severity::Error],
|
||||||
workspace_diagnostics: vec![Severity::Warning, Severity::Error],
|
w_diagnostics: vec![Severity::Warning, Severity::Error],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue