szn

Bug 152 — tty/tty.zig — writeCell always advances cx by 1, ignoring wide character width

152. tty/tty.zig — writeCell always advances cx by 1, ignoring wide character width

File: src/tty/tty.zig:416 Severity: LOW Status: ✅ FIXED — use char_width.charWidth(cell.char) to determine advance amount.

if (self.cx >= 0) self.cx += 1;

Wide characters (e.g., CJK, emoji) occupy 2 terminal columns, but cx is always incremented by 1. The terminal hardware cursor advances by 2, creating a mismatch with the cached position. This causes unnecessary cursorMove CUP sequences for every cell following a wide character.