[Bug] macOS Chinese IME preedit text does not inherit the shaded CLI composer background
What version of Codex CLI is running?
codex-cli 0.144.4
What subscription do you have?
ChatGPT subscription (exact tier not relevant to this UI issue)
Which model were you using?
gpt-5.6-sol (the issue is model-independent)
What platform is your computer?
Darwin 25.3.0 arm64 arm (macOS 26.3.1)
What terminal emulator and version are you using (if applicable)?
ChatGPT desktop app integrated terminal, app 26.707.72221 (build 5307); zsh; no tmux/zellij
Codex doctor report
Not included: codex doctor was run from Codex's non-interactive tool environment and reports TERM=dumb / NO_COLOR=1, which does not describe the integrated terminal where this issue reproduces. Relevant versions and environment details are listed above.
What issue are you seeing?
When composing Chinese text with the macOS Pinyin IME in Codex CLI's shaded input/composer area, the IME preedit string is rendered using the terminal's original background instead of the composer background. This produces a dark rectangular hole around the in-progress Latin letters (for example, jin) inside the gray input bar. The candidate window itself appears normally.
The gray input-box background is already visually intrusive (related to #27333), but this mismatch makes Chinese input especially inconsistent and hard to read. This happens during IME composition before the text is committed, so changing the syntax theme with /theme does not address it.
Screenshot attached below:
<img width="1040" height="414" alt="Image" src="https://github.com/user-attachments/assets/76c042f8-cacb-4d10-a4b3-8a00ff7dc079" />
What steps can reproduce the bug?
- On macOS, open the integrated terminal in the ChatGPT desktop app.
- Run
codex(0.144.4). - Switch to the macOS Chinese Pinyin input source.
- Type a Chinese prompt such as
深圳明天天气,, then typejinwithout selecting a candidate yet. - Observe the preedit/composition string inside the shaded composer.
What is the expected behavior?
The IME preedit text should visually inherit the current composer background so that in-progress and committed text render consistently. Alternatively, Codex should expose a transparent/no-background composer option.
Additional information
Related: #27333 tracks the visually intrusive gray input background. This report focuses specifically on the macOS IME rendering mismatch, not only the preference for a transparent input box.
Relevant source:
- https://github.com/openai/codex/blob/rust-v0.144.4/codex-rs/tui/src/bottom_pane/chat_composer.rs#L4454-L4458
- https://github.com/openai/codex/blob/rust-v0.144.4/codex-rs/tui/src/style.rs#L36-L82
Current workaround: NO_COLOR=1 codex removes the shaded background, but also reduces rich syntax/diff coloring.