aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
authorBlaž Hrastnik2021-04-09 15:22:14 +0000
committerBlaž Hrastnik2021-04-09 15:25:46 +0000
commit7493d19098a8cea44badf4c127fbe754e9733439 (patch)
tree7637dd160e1fb43f0e2500355b26f68e17c38d9d /helix-term/src
parent392c4a9c02d74974ff3160505aec4e4af370bf81 (diff)
Re-introduce clearing with bg color, seems the TUI issue was fixed.
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/ui/editor.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/helix-term/src/ui/editor.rs b/helix-term/src/ui/editor.rs
index 35693d7b..8879612c 100644
--- a/helix-term/src/ui/editor.rs
+++ b/helix-term/src/ui/editor.rs
@@ -77,10 +77,6 @@ impl EditorView {
}
}
- // clear with background color
- // TODO: this seems to prevent setting style later
- // surface.set_style(viewport, theme.get("ui.background"));
-
self.render_diagnostics(doc, view, area, surface, theme, is_focused);
let area = Rect::new(
@@ -630,6 +626,9 @@ impl Component for EditorView {
}
fn render(&self, mut area: Rect, surface: &mut Surface, cx: &mut Context) {
+ // clear with background color
+ surface.set_style(area, cx.editor.theme.get("ui.background"));
+
for (view, is_focused) in cx.editor.tree.views() {
let doc = cx.editor.document(view.doc).unwrap();
self.render_view(doc, view, area, surface, &cx.editor.theme, is_focused);