Feature request: mouseReporting setting to allow X11 primary selection (highlight-to-copy)

Resolved 💬 2 comments Opened Jun 3, 2026 by NikolaDojic Closed Jun 7, 2026

Summary

Add a mouseReporting boolean setting to settings.json that allows users to disable Claude Code's mouse capture, restoring X11 primary selection (highlight → middle-click paste) in the terminal.

Problem

Claude Code captures mouse events for its TUI (scrolling, clicking buttons, etc.). On Linux/X11, this prevents the terminal from populating the primary selection clipboard when text is dragged-to-highlight. The primary selection is a core Linux workflow: highlight text → paste anywhere with middle-click.

The only current workaround is holding Shift while selecting, which bypasses the app's mouse handling. This is the correct escape hatch but it interrupts muscle memory for users accustomed to primary selection working everywhere.

Proposed solution

Add a setting to settings.json:

{
  "mouseReporting": false
}

When set to false, Claude Code would not enable mouse reporting (\x1b[?1000h / \x1b[?1002h / \x1b[?1006h), leaving full mouse control to the terminal emulator. This would restore primary selection at the cost of losing click-to-focus and scroll wheel support inside the TUI.

Alternatives considered

  • Shift+drag — works but breaks muscle memory
  • Terminal-level override — terminal-specific and not always possible (e.g. GNOME Terminal has no per-app mouse override)
  • tui: "default" vs "fullscreen" — neither disables mouse reporting

Environment

  • OS: Linux (X11)
  • Shell: zsh
  • Terminal: (affects all X11 terminal emulators)

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗