Appearance
Mode 2031 color scheme reporting
Private mode 2031 enables unsolicited notifications when the terminal's color scheme changes between dark and light. When enabled, the terminal sends
CSI ? 997 ; Ps n (DECDSR) whenever the scheme changes, where Ps=1 for dark and Ps=2 for light.
Applications can also synchronously query the current scheme via CSI ? 997 n (DECDSR 997). This solves a longstanding problem for TUI applications that need to adapt their color palette to the terminal's dark/light mode. Supported by iTerm2 (3.6.6+), tmux 3.6, Contour, foot, and kitty.How this is testedautomated
Check DECRPM for mode 2031. Fallback: query current scheme via
Check DECRPM for mode 2031. Fallback: query current scheme via
DECDSR 997 and check for response.The same probe runs against headless backends (via Termless) and real terminal apps (via a daemon launched in each terminal). This lets us distinguish parser correctness from rendering correctness.
Analysis2026-04-06
Supported by 4 of 12 terminals (33%). Part of the Modern TUI baseline.
Supported by 5 of 14 backends (36%)
Terminal Applications
| Terminal | Version | Support | Notes |
|---|---|---|---|
| iTerm2 | 3.6.9 | ✓ yes | DECRPM: mode reset |
| Ghostty | 1.3.1 | ✓ yes | DECRPM: mode reset |
| VS Code | ✗ no | ||
| Warp | ✗ no | ||
| Cursor | ✗ no | ||
| Terminal.app | ✗ no |
Headless Backends
Parser correctness only — a ✓ means the parser accepts the sequence.
| Backend | Version | Support | Notes |
|---|---|---|---|
| vterm | 0.2.0 | ✓ yes | Mode 2031 not implemented |
| Kitty | 0.40.0 | ~ partial | Mode 2031 not exposed via Python batch bridge |
| WezTerm | 0.1.0-fork.5 | ~ partial | Mode 2031 not exposed in headless mode |
| Alacritty | 0.26.0 | ✗ no | Mode 2031 not implemented in alacritty |
| vt100.js | 0.2.1 | ✗ no | Not implemented — pure TypeScript emulator |
| xterm.js | 5.5.0 | ✗ no | Mode 2031 not implemented in xterm.js |