is_padding == true)is_padding == true)File: src/grid.zig:782–788, 804–809
Severity: MEDIUM
Status: ✅ FIXED — trim condition changed to last.char == 0 and !last.is_padding and last.comb1 == 0 and last.comb2 == 0 in both the per-line trim and final flat_cells trim. Unit test added.
During reflowCursorInternal, physical lines are trimmed of trailing empty cells using if (last.char == 0). Wide CJK characters consist of a base cell and an adjacent padding cell (.char = 0, .is_padding = true). Trimming strips the padding cell, leaving an orphaned base cell in flat_cells. When rewrapped, findClusterEnd consumes the subsequent character cell as padding.
Impact: CJK text alignment corruption, cluster boundary miscalculations, and text rendering distortion upon window resize.