From 8d647e9c9fc747c14a222a53f9e3db1ba7a07d01 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Thu, 5 Nov 2026 00:05:42 -0300 Subject: pardes, normal, edit: multi_on goes: outside a replay the replay state means one range, its first pass (index 0, count 1, first true), so setYank, registerValue, pushUndo and the open-lines and Tab checks read it plainly; Pardes's walked shape changes, so a client and a daemon from either side refuse each other (wire semantics) Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- src/normal.zig | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/normal.zig') diff --git a/src/normal.zig b/src/normal.zig index 34f5ef58..9e47cf45 100644 --- a/src/normal.zig +++ b/src/normal.zig @@ -48,7 +48,6 @@ fn normalInput(key: Key) modal.Normal.Input { } pub fn multiOnce(p: *Pardes) bool { - if (!p.multi_on) return true; p.multi_stop = true; return p.multi_first; } @@ -527,7 +526,6 @@ pub fn replaySels(p: *Pardes, t: *Text, what: Replay) void { // each pass's result: cursor and anchor cells as distances from the // end of the surface text, plus the range's own j/k goal column var res: [Text.max_selections]struct { cur: usize, anc: usize, sticky: i32 } = undefined; - p.multi_on = true; p.multi_stop = false; var passes: usize = 0; var i: usize = n; @@ -569,8 +567,9 @@ pub fn replaySels(p: *Pardes, t: *Text, what: Replay) void { co; res[i] = .{ .cur = text.len - @min(co, text.len), .anc = text.len - @min(ao, text.len), .sticky = t.sticky_col }; } - p.multi_on = false; - p.multi_first = false; + p.multi_first = true; + p.multi_index = 0; + p.multi_count = 1; if (p.multi_stop) { p.multi_stop = false; if (owner != null) { -- cgit v1.3