Compare commits

..

No commits in common. "3d4125bd3f29d119f375613428a73a3cd52cda34" and "601fcb1aea015f586228a733a54e8efb23b6b2d9" have entirely different histories.

3 changed files with 3 additions and 7 deletions

View File

@ -104,8 +104,6 @@ separator = "│"
mode.normal = "NORMAL"
mode.insert = "INSERT"
mode.select = "SELECT"
diagnostics = ["warning", "error"]
workspace-diagnostics = ["warning", "error"]
```
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.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"` |
| `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:

View File

@ -304,7 +304,7 @@ where
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 {
Severity::Hint if hints > 0 => {
write(

View File

@ -498,7 +498,7 @@ pub struct StatusLineConfig {
pub separator: String,
pub mode: ModeConfig,
pub diagnostics: Vec<Severity>,
pub workspace_diagnostics: Vec<Severity>,
pub w_diagnostics: Vec<Severity>,
}
impl Default for StatusLineConfig {
@ -524,7 +524,7 @@ impl Default for StatusLineConfig {
separator: String::from(""),
mode: ModeConfig::default(),
diagnostics: vec![Severity::Warning, Severity::Error],
workspace_diagnostics: vec![Severity::Warning, Severity::Error],
w_diagnostics: vec![Severity::Warning, Severity::Error],
}
}
}