From 98ed98178b667e551ff2bcaeb981e70d1f6ccb1f Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 29 Sep 2026 06:05:56 -0300 Subject: A word written to a raw terminal's look is listed, as in normal mode A new Tty is in raw mode, where a right click is its program's, and a look written to it over 9P did nothing for that reason. The look file is no keyboard input: over 9P a plain word is listed in a +Search pane and read back whatever the terminal's key mode. Co-Authored-By: Claude Opus 5.5 --- src/look.zig | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/look.zig') diff --git a/src/look.zig b/src/look.zig index 796eb5bb..8318973b 100644 --- a/src/look.zig +++ b/src/look.zig @@ -1340,7 +1340,9 @@ pub fn lookAt(p: *Pardes, id: usize, operand: []const u8) void { if (found != .none) clearNavigationSelection(p, pane); switch (found) { .none => { - if (pane.image != null or pane.body.mode == .tty) return; + // A raw terminal's clicks are its program's; a look written over + // 9P is no keyboard input, and searches whatever the key mode. + if (pane.image != null or (pane.body.mode == .tty and !p.fs.serving)) return; if (p.settings.look_word == .search and pane.file != null) return lookWord(p, id, pane, trimmed); const rows = runSearch(p, id, trimmed, .text, .cursor, false) catch |err| { p.reportError(id, "search", err); -- cgit v1.3