aboutsummaryrefslogtreecommitdiff
path: root/alacritty/src/display.rs
diff options
context:
space:
mode:
Diffstat (limited to 'alacritty/src/display.rs')
-rw-r--r--alacritty/src/display.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/alacritty/src/display.rs b/alacritty/src/display.rs
index af21001e..451874c8 100644
--- a/alacritty/src/display.rs
+++ b/alacritty/src/display.rs
@@ -160,6 +160,9 @@ pub struct Display {
#[cfg(not(any(target_os = "macos", windows)))]
pub is_x11: bool,
+ /// UI cursor visibility for blinking.
+ pub cursor_hidden: bool,
+
renderer: QuadRenderer,
glyph_cache: GlyphCache,
meter: Meter,
@@ -300,6 +303,7 @@ impl Display {
is_x11,
#[cfg(all(feature = "wayland", not(any(target_os = "macos", windows))))]
wayland_event_queue,
+ cursor_hidden: false,
})
}
@@ -442,8 +446,9 @@ impl Display {
let viewport_match = search_state
.focused_match()
.and_then(|focused_match| terminal.grid().clamp_buffer_range_to_visible(focused_match));
+ let cursor_hidden = self.cursor_hidden || search_state.regex().is_some();
- let grid_cells = terminal.renderable_cells(config, !search_active).collect::<Vec<_>>();
+ let grid_cells = terminal.renderable_cells(config, !cursor_hidden).collect::<Vec<_>>();
let visual_bell_intensity = terminal.visual_bell.intensity();
let background_color = terminal.background_color();
let cursor_point = terminal.grid().cursor.point;