Skip to content

Terminal: send Shift+Tab, Delete, Ctrl+Alt and Ctrl+digit keys as xterm does - #3067

Open
insjang wants to merge 1 commit into
eclipse-platform:masterfrom
insjang:xterm-keys
Open

insjang wants to merge 1 commit into
eclipse-platform:masterfrom
insjang:xterm-keys

Conversation

@insjang

@insjang insjang commented Nov 11, 2026

Copy link
Copy Markdown
Contributor

Keys that Claude Code, Codex and other terminal programs use, checked key by key against xterm:

  • Shift+Tab sends back tab (CSI Z), as xterm and Windows Terminal do, and no longer moves the focus out of the terminal; Claude Code switches modes with it.
  • Ctrl, Shift and Alt with Delete carry the modifier (CSI 3 ; 5 ~ and so on); every Delete used to arrive as a plain Delete.
  • A real Ctrl+Alt keeps its Alt: ESC before the control character, as in xterm (Ctrl+Alt+V pastes an image in Codex on WSL). AltGr, which SWT reports as Ctrl+Alt with the character it types, types that character as before.
  • Ctrl+2 to Ctrl+8 send NUL, ESC, FS, GS, RS, US and DEL; on Windows they sent the digits.
  • On the alternate screen Alt and Ctrl with the arrows go to the full screen program even where Eclipse has a binding for them (Alt+Up edits a queued message in Codex); at the shell prompt Alt+Up still maximizes the view.

How to test, in a bash terminal: run od -c, press the key, then Enter, and Ctrl+D to end.

  • Shift+Tab shows 033 [ Z, and the focus stays in the terminal.
  • Ctrl+Delete shows 033 [ 3 ; 5 ~ (Shift: ; 2, Alt: ; 3).
  • Ctrl+Alt+V shows 033 026; on a German keyboard AltGr+Q still types @.
  • Ctrl+6 shows 036.
  • In vim (alternate screen) Alt+Up is not taken by Eclipse; at the prompt Alt+Up still maximizes the view.

Tests: new cases in VT100EmulatorTest for Ctrl with the digits, Alt with ESC (AltGr included), Delete with modifiers and the alternate screen flag.

…rm does

Keys that Claude Code, Codex and other terminal programs use, checked
key by key against xterm:

- Shift+Tab sends back tab (CSI Z), as xterm and Windows Terminal do,
  and no longer moves the focus out of the terminal; Claude Code
  switches modes with it.
- Ctrl, Shift and Alt with Delete carry the modifier (CSI 3 ; 5 ~ and
  so on); every Delete used to arrive as a plain Delete.
- A real Ctrl+Alt keeps its Alt: ESC before the control character, as
  in xterm (Ctrl+Alt+V pastes an image in Codex on WSL). AltGr, which
  SWT reports as Ctrl+Alt with the character it types, types that
  character as before.
- Ctrl+2 to Ctrl+8 send NUL, ESC, FS, GS, RS, US and DEL; on Windows
  they sent the digits.
- On the alternate screen Alt and Ctrl with the arrows go to the full
  screen program even where Eclipse has a binding for them (Alt+Up
  edits a queued message in Codex); at the shell prompt Alt+Up still
  maximizes the view.
@github-actions

Copy link
Copy Markdown
Contributor

Test Results

    54 files  ±0      54 suites  ±0   37m 23s ⏱️ + 3m 15s
 5 008 tests +3   4 986 ✅ +3   22 💤 ±0  0 ❌ ±0 
12 915 runs  +9  12 761 ✅ +9  154 💤 ±0  0 ❌ ±0 

Results for commit 844e234. ± Comparison against base commit 5cccf6a.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant