aboutsummaryrefslogtreecommitdiffstats
path: root/zellij-utils/src/input
diff options
context:
space:
mode:
authoruser <user@clank>2026-08-12 14:09:21 +0200
committeruser <user@clank>2026-08-12 14:09:21 +0200
commitea500ea70aa77da57870e8272bab593887819b0b (patch)
tree9e73592f03884dba54c3ff1ab3b5ab41cb9721d6 /zellij-utils/src/input
parentsl0p(pane-finder): find panes hidden in a stack, not just the visible one (diff)
downloadsl0ppij-ea500ea70aa77da57870e8272bab593887819b0b.tar.gz
sl0ppij-ea500ea70aa77da57870e8272bab593887819b0b.tar.xz
sl0ppij-ea500ea70aa77da57870e8272bab593887819b0b.zip
sl0p: separate the hover resize hint from the hover highlight
Upstream's mouse_hover_effects governs two unrelated things: the frame highlight on hover, and the "Ctrl <MouseScroll> or <drag borders> to resize" hint. Its own comment in default.kdl admits as much. So silencing a beginner reminder you have outgrown also costs you a highlight that stays useful indefinitely. mouse_hover_help_text (default true) gates only the hint. One line in execute_send_to_terminal; the highlight is set in execute_update_hover and is untouched. Config-file only, deliberately. The option has no protobuf slot, so it does not cross the client/server IPC contract -- the roundtrip test asserts exactly that, with the fixture set to None and a comment explaining why. It still works from the config file because the server parses the file itself and Options::merge keeps the file value when the client sends None; a CLI flag would be silently ignored.
Diffstat (limited to 'zellij-utils/src/input')
-rw-r--r--zellij-utils/src/input/options.rs13
1 files changed, 13 insertions, 0 deletions
diff --git a/zellij-utils/src/input/options.rs b/zellij-utils/src/input/options.rs
index 5937237f..b4621c13 100644
--- a/zellij-utils/src/input/options.rs
+++ b/zellij-utils/src/input/options.rs
@@ -400,6 +400,15 @@ pub struct Options {
#[serde(default)]
pub mouse_hover_effects: Option<bool>,
+ /// Whether hovering a pane shows the "Ctrl <MouseScroll> or <drag borders> to
+ /// resize" hint. Split out from mouse_hover_effects, which also governs the
+ /// hover frame highlight: the hint is a beginner reminder you outgrow, while
+ /// the highlight is useful indefinitely.
+ /// default is true
+ #[clap(long, value_parser)]
+ #[serde(default)]
+ pub mouse_hover_help_text: Option<bool>,
+
/// Whether to show visual bell indicators (pane/tab frame flash and [!] suffix)
/// default is true
#[clap(long, value_parser)]
@@ -552,6 +561,7 @@ impl Options {
let advanced_mouse_actions = other.advanced_mouse_actions.or(self.advanced_mouse_actions);
let mouse_scroll_resize = other.mouse_scroll_resize.or(self.mouse_scroll_resize);
let mouse_hover_effects = other.mouse_hover_effects.or(self.mouse_hover_effects);
+ let mouse_hover_help_text = other.mouse_hover_help_text.or(self.mouse_hover_help_text);
let visual_bell = other.visual_bell.or(self.visual_bell);
let focus_follows_mouse = other.focus_follows_mouse.or(self.focus_follows_mouse);
let mouse_click_through = other.mouse_click_through.or(self.mouse_click_through);
@@ -619,6 +629,7 @@ impl Options {
advanced_mouse_actions,
mouse_scroll_resize,
mouse_hover_effects,
+ mouse_hover_help_text,
visual_bell,
focus_follows_mouse,
mouse_click_through,
@@ -707,6 +718,7 @@ impl Options {
let advanced_mouse_actions = other.advanced_mouse_actions.or(self.advanced_mouse_actions);
let mouse_scroll_resize = other.mouse_scroll_resize.or(self.mouse_scroll_resize);
let mouse_hover_effects = other.mouse_hover_effects.or(self.mouse_hover_effects);
+ let mouse_hover_help_text = other.mouse_hover_help_text.or(self.mouse_hover_help_text);
let visual_bell = other.visual_bell.or(self.visual_bell);
let focus_follows_mouse = merge_bool(other.focus_follows_mouse, self.focus_follows_mouse);
let mouse_click_through = merge_bool(other.mouse_click_through, self.mouse_click_through);
@@ -774,6 +786,7 @@ impl Options {
advanced_mouse_actions,
mouse_scroll_resize,
mouse_hover_effects,
+ mouse_hover_help_text,
visual_bell,
focus_follows_mouse,
mouse_click_through,