Keep a wide pair whole when cells move #23
No reviewers
Labels
No labels
Area/ci
Area/cli
Area/client
Area/client-core
Area/daemon
Area/deps
Area/docs
Area/grid
Area/manual
Area/nix
Area/protocol
Area/pty
Area/render
Area/shaping
Area/skills
Area/transport
Area/vt
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Performance
Kind/Security
Kind/Testing
perf-regression-accepted
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Blocked
Status
Need More Info
Status
Upstream
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
felis-terminal/felis!23
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/wide-pair-shift"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #12. Builds on #21.
The editors that move cells repaired only the span they vacated, never the boundaries of the move, so a wide pair crossing one was split, for a plain
字too: DCH on its right half left the owner drawing over the next character, and ICH on a full line left an owner with noSpacerat the margin.Change
erase_pair_across): ICH, DCH, the IRM insert, SL/SR, DECIC/DECDC, DECBI/DECFI, the DECSLRM sub-rectangle scroll, and DECCRA's source and destination edges. The inserted/deleted cell count stays exact, as in kitty. A repair after the move would not work: an owner without aSpaceris also what a refused VS16 widen looks like.Spacerthe new edge cuts.Spaceractually follows, so a refused widen no longer shifts its line right on every resize.w=1;字still prints aSpacer). A newsized_block_atreplacesfind_sized_primary, which found the wrong block in a multi-character run, on the print path too. DECCRA copies a sized block only when its source holds all of it, and erases a destination block it overwrites in part. The saved alternate screen now gets the same unfit-block discard as the live one after a resize.Out of scope, filed as #24: a single-row shift through an uncut multi-row OSC 66 block still moves only that row of the block. This predates the change.
Verification
snapshot_wide_pairs.rs: 39 new cases cover every repro in the issue, the clamped and outside-margin shifts, the sized-block cases, and the stale-tail regressions. The test renderer now reads cells through the watermark, as every other reader does. 34 of them fail on #21. The other 5 are guards: three shifts that #21's erase widening already handled (ICH on a right half, and ICH and DCH clamped to the line), now handled by the seam erase, and two no-ops with the cursor outside the margins.every_wide_pair_stays_whole(replacesevery_spacer_sits_right_of_a_two_cell_glyph) adds the cell-moving editors, DECSLRM, the alternate screen, DECCRA, and a resize step. It also checks a second invariant: a wideCharis always followed by itsSpacer. It passes at 30k cases.unicode_throughput,scroll_region): within noise.just checkgreen. sol reviewed the plan in one round and the code in four. Rounds 1 to 3 were BLOCKED on OSC 66 edge cases: a multi-character run, DECCRA, the saved alternate screen, andwnarrower than the glyph. Round 4 passed, and its one non-blocking note, u32 bounds arithmetic, is applied.