From a3e07c437ed6f94f2eda5cfb5e50d2728a747aad Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Sun, 8 Nov 2026 22:05:02 -0300 Subject: helix: hxparity's pty run parked its cursor at (0,0) but left the view where tty mode had it, at the live grid's bottom, so zj there scrolled nothing and scrolloff snapped the cursor to row 13 where the file run's went to 4; the harness now lets the view follow the parked cursor (ensureCursorVisible, the state a real gg reaches: the same 738 results), zj-snaps-cursor passes, and the seven viewport waivers that only recorded the stranded view go (zj-snaps-cursor, zj-noop-in-band, zk-bottom-snap, sticky-view-scroll, sticky-view-then-move, sticky-view-ignores, view-z-not-sticky); helix-keys.md's parity waivers say so Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- test/hxdiff.zig | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'test/hxdiff.zig') diff --git a/test/hxdiff.zig b/test/hxdiff.zig index 03b135e2..85c854a0 100644 --- a/test/hxdiff.zig +++ b/test/hxdiff.zig @@ -404,13 +404,17 @@ fn runCase(arena: std.mem.Allocator, case: Case, pane_kind: []const u8) !Result // leave tty mode the way a live session does: Ctrl-, // then park the cursor at (0,0) — the helix harness's initial // Selection::single(0,1) equivalent (a live exit would leave the - // modal cursor tracking the shell cursor below the output) + // modal cursor tracking the shell cursor below the output) — and + // let the view follow it there, as it follows `gg`. Left at the + // live grid, the view would not show the cursor, which no session + // reaches, and zj or a page key would start from the grid's bottom. core.update(.{ .key = .{ .cp = core.opts.tty_toggle, .ctrl = true } }); pump(core); if (core.panes[core.view().active]) |pane| { pane.body.cur_row = 0; pane.body.cur_col = 0; pane.body.cur_pinned = true; + pane.ensureCursorVisible(); } } else fatal("case {s}: unknown pane {s}", .{ case.name, pane_kind }); -- cgit v1.3