Fix TUI layout for halfwidth Japanese sound marks (#35962)

## What changed

- Use Ratatui-compatible terminal widths throughout TUI layout, preserving
  full-width counters for long lines.
- Wrap and truncate on grapheme boundaries so halfwidth kana sound marks and
  emoji sequences stay intact.
- Apply the corrected sizing to text input, selection popups, status and
  history cells, Markdown, hyperlinks, and scrollable cloud diffs.

## Testing

- Add focused unit and snapshot coverage for wrapping, truncation, cursor and
  mask alignment, popup columns, status output, session headers, Markdown
  tables, process output, and scrollable diffs.

GitOrigin-RevId: 294ec0bcff743c6bb16d55ec26308524ce741879
This commit is contained in:
Charlie Marsh
2026-07-29 13:46:52 +00:00
committed by copyberry
parent cef3910ea4
commit 3725f02cf3
38 changed files with 1335 additions and 245 deletions

2
codex-rs/Cargo.lock generated
View File

@@ -2482,6 +2482,7 @@ dependencies = [
"codex-utils-cli",
"crossterm",
"http 1.4.0",
"insta",
"owo-colors",
"pretty_assertions",
"ratatui",
@@ -2492,6 +2493,7 @@ dependencies = [
"tokio-stream",
"tracing",
"tracing-subscriber",
"unicode-segmentation",
"unicode-width 0.2.1",
]