summaryrefslogtreecommitdiff
path: root/docs/typ/guide.typ
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-10-24 12:43:02 -0300
committerGabriel Schneider <[email protected]>2026-10-24 13:11:11 -0300
commit1af098381515fbe3a4fe678cd023c7fd74418ae1 (patch)
tree34f8f1495ddbea9542d23af68db53f244a1ec4c5 /docs/typ/guide.typ
parent8ac6db5662dd2db0f082e1651835f1db36e235f8 (diff)
downloadpardes-1af098381515fbe3a4fe678cd023c7fd74418ae1.tar.gz
pardes-1af098381515fbe3a4fe678cd023c7fd74418ae1.zip
Search converge 5/6: the old search pipeline phased out, the notice-band / for texts, Find/Grep prompts and walks on the loop, +Recent, n/N as Look-the-next-row; docs, tutor, Help and goldens to the query pane
Diffstat (limited to 'docs/typ/guide.typ')
-rw-r--r--docs/typ/guide.typ46
1 files changed, 40 insertions, 6 deletions
diff --git a/docs/typ/guide.typ b/docs/typ/guide.typ
index e60b4231..65c7334d 100644
--- a/docs/typ/guide.typ
+++ b/docs/typ/guide.typ
@@ -20,9 +20,9 @@
[the session's directory], [where pardes started, or the directory `pardes DIR` named; workspace and column tags run there],
[active column], [where the next new pane goes (below)],
[command pane], [a terminal that runs one command line and shows its output],
- [`+` names], [panes pardes makes, named in their directory: `+New` a scratch (text with no file yet), `+Search` a listing of places, `+Pager` paged text, `+Errors` output, `+Unsaved` the panes holding unsaved text],
+ [`+` names], [panes pardes makes, named in their directory: `+New` a scratch (text with no file yet), `+Search` a query pane or a listing of places, `+Pager` paged text, `+Errors` output, `+Unsaved` the panes holding unsaved text],
[serial], [a pane's number, never reused: the `3` in `@p3:12` and in 9P paths],
- [message row], [the line where pardes says what happened, and asks: answer a prompt (a search, #word("Save")'s path) with #key("Enter"), cancel it with #key("Esc")],
+ [message row], [the line where pardes says what happened, and asks: answer a prompt (#key("s")'s regex, #word("Save")'s path) with #key("Enter"), cancel it with #key("Esc")],
)
= Modes <modes>
@@ -166,11 +166,45 @@ on the cheatsheet. A relative path is found in the directory of the pane
the #word("Look") came from, then of each pane on the jump list, most
recent first.
+= Search <search>
+
+#key("/") opens a query pane under the pane: a `+Search` whose first line
+is the query, typed into, and whose rows are what it finds, made again at
+each key. It takes its rows from the pane it searches and from no other,
+is born #word("SearchRows") rows tall and never resizes itself; nothing
+found is a count of `0` in its tag, not an exit.
+
#pairs(
- [#key("/") `TODO` #key("Enter")], [a `+Search` of the lines holding `TODO`, the cursor on the first; #keys("n", "N") select the next or previous match],
- [#word("Find") `conf`], [a `+Search` of the files below the pane's directory with `conf` in their names],
- [#word("Grep") `TODO`], [a `+Search` of the lines holding `TODO`, literally, under every pane's directory],
+ [#key("/") `vw`], [every match in the text tinted and ticked on its scroll rail, the first after the cursor selected; the rows under line 1 are the lines holding it, a line number in the gutter, each under the declaration it is in],
+ [#keys("Ctrl-n", "Ctrl-p")], [the next or previous match, typing; the text follows it],
+ [#key("Enter")], [the keyboard on the match, the pattern in `/`, the rows kept as text (#word("Save") keeps them as a file)],
+ [#keys("n", "N")], [the next or previous match in the text, round the end without a word],
+ [#key("Esc")], [typing: the text as it was, the query pane closed],
+ [#key("*")], [the selection as line 1, the keyboard staying in the text],
)
+
+Line 1's first word names what it searches, and editing the word changes it:
+
+#pairs(
+ [`/pat`], [the pane's own text: a regex, any case unless it has a capital (#key("/"))],
+ [`Find name`], [the files below the pane's directory, by a fuzzy match of their names (#key("SPC f f"), #word("Find"))],
+ [`Grep text`], [the lines of those files holding `text`, literally (#key("SPC f g"), #word("Grep")); past 2000 lines #word("More") goes on],
+ [`Recent name`], [the files opened lately (#key("SPC f r"), #word("Recent"))],
+ [`Panes name`], [the open panes (#key("SPC b b"), #word("Panes"))],
+ [`Symbols name`], [the text's declarations (#key("SPC s s"))],
+ [`All pat`], [every open pane's text, its rows under each pane (#key("SPC /"))],
+ [`Refs`, `Def`, `Impl`, `Diagnostics`], [the language server's lists; their places in the text tinted as a `/`'s are, `]d` stepping the diagnostics],
+)
+
+A row in a file no pane shows is shown in a `+Preview` under the query
+pane, following #keys("Ctrl-n", "Ctrl-p") and #btn("B1"), never the
+pointer; #key("Enter") makes the preview that file's pane where it stands.
+#btn("B3") on a row's line number looks at the row; #btn("B2") on line 1
+runs it again. The next search from the same pane reuses its query pane,
+its kept rows back on #key("Esc") (#word("SearchPane") `new`: a pane each;
+#word("SearchPlace") `column`: in a finder column at the right). A PDF's
+and a terminal's #key("/") still ask on the message row and list a
+`+Search`.
#clip("search")
= Unsaved panes <unsaved-panes>
@@ -281,7 +315,7 @@ refusals and `--nested` are in the reference.
[#key("w") #key("d")], [select a word, delete it: motions select, edits act on the selection],
[#key("x"), #key("v"), #key(";")], [select the line; extend; collapse to the cursor],
[#key("s")], [a cursor per regex match; every edit acts at each],
- [#key("/"), #keys("n", "N")], [substring search; repeat the search in the current text, wrapping at the ends],
+ [#key("/"), #keys("n", "N")], [search the text in a query pane (#link(<search>)[Search]); step its matches, round the ends],
[#keys("SPC j n", "SPC j p")], [#word("LookNext") / #word("LookPrev"): select locations across panes; #key("Enter") opens one],
[#key("g l")], [line end],
[`12G`], [line 12; a bare #key("G") does nothing],