diff options
author | Skyler Hawthorne | 2022-05-01 00:44:54 +0000 |
---|---|---|
committer | Skyler Hawthorne | 2022-06-19 03:54:03 +0000 |
commit | 07fc80aece221233b4a986b0c5a03e2056cc1307 (patch) | |
tree | 5165c2e33265cefa10081b77fb6436b4f08c8d26 /helix-view/src/editor.rs | |
parent | ee705dcb3363aeb197f6125ab2f8285782333010 (diff) |
tests for serialized writes
Diffstat (limited to 'helix-view/src/editor.rs')
-rw-r--r-- | helix-view/src/editor.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/helix-view/src/editor.rs b/helix-view/src/editor.rs index 8607c65a..d828f9ec 100644 --- a/helix-view/src/editor.rs +++ b/helix-view/src/editor.rs @@ -571,6 +571,11 @@ impl Editor { self.status_msg = Some((error.into(), Severity::Error)); } + #[inline] + pub fn get_status(&self) -> Option<(&Cow<'static, str>, &Severity)> { + self.status_msg.as_ref().map(|(status, sev)| (status, sev)) + } + pub fn set_theme(&mut self, theme: Theme) { // `ui.selection` is the only scope required to be able to render a theme. if theme.find_scope_index("ui.selection").is_none() { |