fix-deviant(links): bound hover lookup and renderer regex work
Follow-up testing showed that the mailbox limit did not fix the base64 hang: moving the pointer stalled the app, and opening a tab could hang it. Mouse link lookup copied the entire wrapped line before checking modifier eligibility, while renderer link searches had no whole-search work budget. Filter eligible links before traversing scrollback. Add bounded logical line selection and skip automatic regex lookup on lines exceeding 65,536 grid cells. Keep explicit line selection and OSC8 handling unrestricted. Skip oversized lines instead of truncating URLs into different targets. Apply the existing terminal StringMap retry budget to renderer searches and handle search errors without panicking. The regression triggered a retry-limit panic through the old onig search API and now returns normally, allowing subsequent link patterns to run. Document the lookup limits and correct the earlier mailbox fix entry to record that it did not resolve the reported hang on its own. Test Plan: - 1,513 unit/integration tests and one doctest pass across core, renderer, and terminal with Mesa software OpenGL; one existing doctest is ignored. - Release application build, formatting, and all-target Clippy pass. - GTK handles 400 pointer moves, including Ctrl hover, during continuous base64 output, opens/closes a tab, handles Ctrl+C, prints a marker, and exits cleanly. Normal URL hover still works after a hard newline. Reference: docs/rewrite/DEVIANT_FIXES.md (entry 41)
This commit is contained in:
1 parent
4c31d27888
commit
9010117d08
9 files changed
+153
-24
No files matched your search
@@ -132,6 +132,13 @@ GTK invokes `glib-compile-resources` directly so generated XML/UI files in
|
||||
the runtime again if work remains. Continuous renderer notifications must
|
||||
yield to GTK input, timers, and drawing instead of extending one tick
|
||||
indefinitely.
|
||||
Interactive link lookup checks modifier eligibility before scanning text.
|
||||
`Surface::link_at_pin` uses `Screen::select_line_bounded` to skip logical
|
||||
lines spanning more than 65,536 grid cells, bounding synchronous scrollback
|
||||
traversal and string-map allocation while holding the terminal mutex.
|
||||
Explicit text selection remains unrestricted. Renderer link regex searches
|
||||
use the same 100,000-step whole-search retry budget as terminal `StringMap`
|
||||
and treat regex failures as no further matches instead of panicking.
|
||||
9. **Config:** same file format, same keys, same defaults, same CLI flags,
|
||||
same docs text (used by `+show-config --docs` and `--help`).
|
||||
10. **Tests:** every Zig `test "..."` block in a ported file is ported to a
|
||||
|
||||
Reference in new issue
Block a user