summaryrefslogtreecommitdiff
path: root/test/snapshots/psearch.snap
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-07-31 11:42:18 -0300
committerGabriel Schneider <[email protected]>2026-08-01 15:02:08 -0300
commit911215846f1d5a9b2e37a00e74fb9266d4a0884a (patch)
tree31413ca3336cbbd1933d9dc3e24f09a3b8ef46b4 /test/snapshots/psearch.snap
parent0b7a480bef38b209741c520e2478d178767a9e51 (diff)
downloadpardes-911215846f1d5a9b2e37a00e74fb9266d4a0884a.tar.gz
pardes-911215846f1d5a9b2e37a00e74fb9266d4a0884a.zip
a Look path can name a range, and search selects what it found
file:LINE:COL-ENDLINE:ENDCOL, with the two short forms people actually type reading naturally: file:412:9-21 on one line, file:412-418 whole ones. Ends are inclusive. A path feature, not a search feature — a ranged path typed in a tag or middle-clicked out of a shell's output selects just the same; search is only its first consumer. The dash is the fussy part. `-` was already a file char, so a ranged word survives click expansion whole, but a range needs a number on BOTH sides or my-file:10, build-2 and 2026-07-30 would stop being paths. Table-driven test in look.zig for exactly that. Selecting goes through the cellRange/setPaneRange pair the multi-cursor work left, and hxOff clamps both ends, so a stale range selects what still exists rather than crashing or reaching past EOF — pinned with an 8:6-400:9 range in a nine-line file. Producers: / search, Grep, and five LSP sites through a new spanRow — goto, references, rename tokens and both symbol lists were throwing away real protocol ranges at path:line:col. Left alone deliberately: Find rows are bare paths with nothing to span, a jump is a spot not a span, and the diagnostic and format paths only ever have a point, where half a range would be worse than none. One knock-on worth knowing: n now leaves an EXPLICIT selection, so a topbar execute chords it. grep.snap's no-match step was silently becoming `Grep TARGET`; it runs from the leader path now, which never chords, and the dedicated chord steps stayed where they were.
Diffstat (limited to 'test/snapshots/psearch.snap')
-rw-r--r--test/snapshots/psearch.snap12
1 files changed, 7 insertions, 5 deletions
diff --git a/test/snapshots/psearch.snap b/test/snapshots/psearch.snap
index fb721c7d..e2ea1aea 100644
--- a/test/snapshots/psearch.snap
+++ b/test/snapshots/psearch.snap
@@ -1,9 +1,10 @@
# `/` search on a TERMINAL pane: the same tag input as a file pane, searching
# the shell's own scrollback (the plain text view Look reads, prompt rows
# hidden). Results land in a +Search OUTPUT BUFFER — a file pane with no file
-# behind it, so its tag has no Save — and point at `@p0:LINE`, the look target
-# that names a live pane, since a terminal has no path. n/N walk the buffer
-# and look each row, scrolling the terminal to that line of its scrollback.
+# behind it, so its tag has no Save — and point at `@p0:LINE:COL-ENDCOL`, the
+# look target that names a live pane, since a terminal has no path. n/N walk
+# the buffer and look each row, scrolling the terminal to that line of its
+# scrollback and selecting the span the row names.
# PLACEMENT, and this script is the proof: an output buffer is NOT a document
# — it is the result list of the pane that asked for it — so even here, with no
# doc pane in the session for it to join, it does NOT take a column of its own.
@@ -34,8 +35,9 @@ key enter
wait 10000 @p0:2:3
stable 700 15000
snap results
-# n looks result 1: the terminal's cursor lands on that scrollback line, at
-# the matched COLUMN (3, past the leading "x ") — not the start of the line
+# n looks result 1: the terminal's cursor lands on that scrollback line, on
+# the matched SPAN (cols 3..6, past the leading "x ") — not the start of the
+# line, and selected rather than merely parked on
key n
stable 700 15000
snap first