summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-09-22 17:43:57 -0300
committerGabriel Schneider <[email protected]>2026-10-01 00:12:14 -0300
commit9695cb098c784792af79c22d46a17f7bc7247d33 (patch)
treefa446f3cb588b3184b7914b3f50c36cd3e5ece7b /docs
parentf962de52df4b3d33438150920ae95b8708b0dde0 (diff)
downloadpardes-9695cb098c784792af79c22d46a17f7bc7247d33.tar.gz
pardes-9695cb098c784792af79c22d46a17f7bc7247d33.zip
Repaint PDF highlights by row, send rasters by shared memory, and animate messages
PDF highlights (hover preview, search, selection) are baked into page rasters, and any change re-rendered the whole page with MuPDF; the TTY then re-sent it as base64 (4.7 MB a page), the GUI as a new texture. Worse, a pointer motion over a PDF invalidated the page even when no preview was shown, so every motion paid that. Now: - A raster whose baked highlight set equals the wanted one is left alone. - A highlighted page keeps its clean rows (before highlights and tint); a change repaints only the rows of quads that differ, running MuPDF's highlight pass (pardes_pdf_paint_highlights) over those clean rows and tinting them: the operations a full render performs, so the pixels are identical. MuPDF band renders are NOT bit-identical to a whole page (edge rows, resampled images), so they are never used to patch; the comment claiming otherwise is corrected. - ImagePlace.patch hands shells the changed rows; the GUI uploads just those rows into the texture it holds. - The TTY probes kitty shared memory (t=s) with an id vaxis never reaches and sends rasters as a /dev/shm name when the terminal reads it; direct base64 otherwise (ssh). - Shells that take row patches (GUI, TTY with shm) repaint a selection while it is dragged instead of only on release. Latency elsewhere: - TTY: an animating frame no longer sleeps 16 ms blind; a tick thread posts into the input queue, so input inside the frame is handled at once. - TTY and GUI: queued pointer motions coalesce to the last. - GUI: a skipped swapchain image re-arms the frame (3 retries); animations still tick while nothing presents. - Editing: the line index is carried across an edit instead of rebuilt from a scan of the whole file per keystroke. Messages fall into their row (ease-in; the GUI slides the band out from under the tagline, a terminal fades it), stay until the next input as before, linger MessageLinger ms (default 800), and dissolve (ease-out). MessageAnimation toggles it; both are settings, in Config and startup files. The snapshot harness pins the old behaviour. The detached server now ticks animations. A restored terminal comes back live: the old screen and scrollback (dumped as clean VT by ghostty's formatter, replayed at the new size; older dumps fall back to their rendered text), a dim "restored history" marker, then a new shell in the directory it was in. Right-click on a line number in a file pane looks at that line (a sticky context header's number included). Measured with an external pty driver (TTY), an in-process fence trace (GUI, PARDES_TEST_LATENCY), and test/pdf_pointer_bench.zig (pixel identity against the baseline and a whole-page oracle); balanced A/A/B rounds, paired per-round statistics. Messages stack: each event gets its own row and its own fall, linger and dissolve; a line keeps its row until it leaves and a new one fills the first free row. Announcements and statuses are replaced in place, not stacked. MessageFall, MessageDissolve and DumpDir are settings Config reports. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Diffstat (limited to 'docs')
-rw-r--r--docs/config.md24
1 files changed, 22 insertions, 2 deletions
diff --git a/docs/config.md b/docs/config.md
index 8eff79a8..27818b5b 100644
--- a/docs/config.md
+++ b/docs/config.md
@@ -115,6 +115,16 @@ compact screen. Hiding it preserves your custom column commands.
name before it runs; it is on by default, and the builtins that own the message
row themselves (`Msg`) never announce. Turning it off leaves the row to the
messages a builtin chooses to write.
+`MessageAnimation` toggles how a message comes and goes; it is on by default.
+A message eases down into its row (graphical frontends slide it out from under
+the tagline; a terminal fades it in), stays until the next key or click as it
+always has, then lingers for `MessageLinger` milliseconds (default 800) before
+it dissolves into the page. `MessageFall` (default 180) and `MessageDissolve`
+(default 300) set how long the fall and the dissolve take, also in
+milliseconds; each timing is at most 60000, and `Config` reports all three. `MessageLinger 0` with
+`MessageAnimation off` restores the old behaviour, a message cleared by the
+very input that follows it. An updated line on a row already showing one swaps
+its text in place rather than falling again.
`SyntaxBold` toggles bold syntax keywords; it is off by default. These
settings are shared by GUI and TTY, and `Config` reports their current
states. Like `Colors` and `Wrap`, these commands take no argument and invert
@@ -573,8 +583,18 @@ control all yield null, and the flag has to work anyway. Neither is a question
asked at runtime — a binary that shelled out to `git` would describe whatever
tree it was standing in rather than the one it came from.
-`Restore a.dump` first looks for the relative path in the default dump directory
-(`$XDG_DATA_HOME/pardes`, or `~/.local/share/pardes`). If it is absent, Restore
+`Restore a.dump` first looks for the relative path in the dump directory:
+`DumpDir <path>` when set (a leading `~/` is your home; bare `DumpDir` returns
+to the default), else `$XDG_DATA_HOME/pardes` or `~/.local/share/pardes`.
+`Config` reports the directory in effect as `DumpDir <path>`, so the line can
+be fed back as configuration. If it is absent, Restore
uses the argument as a path as before. Absolute paths and argument-free Restore
retain their existing behavior. `Dump` still honors `$PARDES_DUMP` and otherwise
writes a timestamped file in the default directory.
+
+A restored terminal comes back live: its recorded output (the last MiB of it)
+is replayed as history, a dim `── restored history ──` line marks where it
+ends, and a new shell starts below it in the directory the old one was in. A
+view left scrolled back stays where it was. Only the shell is new; nothing the
+old one was running is restarted. The web shell, which has no ptys, still
+shows the history alone.