aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/ui/prompt.rs
diff options
context:
space:
mode:
Diffstat (limited to 'helix-term/src/ui/prompt.rs')
-rw-r--r--helix-term/src/ui/prompt.rs16
1 files changed, 2 insertions, 14 deletions
diff --git a/helix-term/src/ui/prompt.rs b/helix-term/src/ui/prompt.rs
index b09b8e14..9bde1f57 100644
--- a/helix-term/src/ui/prompt.rs
+++ b/helix-term/src/ui/prompt.rs
@@ -126,13 +126,7 @@ impl Prompt {
let area = completion_area;
let background = theme.get("ui.statusline");
- for y in area.top()..area.bottom() {
- for x in area.left()..area.right() {
- let cell = surface.get_mut(x, y);
- cell.reset();
- cell.set_style(background);
- }
- }
+ surface.clear_with(area, background);
let mut row = 0;
let mut col = 0;
@@ -172,13 +166,7 @@ impl Prompt {
);
let background = theme.get("ui.window");
- for y in area.top()..area.bottom() {
- for x in area.left()..area.right() {
- let cell = surface.get_mut(x, y);
- cell.reset();
- cell.set_style(background);
- }
- }
+ surface.clear_with(area, background);
use tui::layout::Margin;
text.render(