On Fri Nov 20, 2026 at 1:43 AM MST, Kim Wilkes wrote:
I want to run tmux in xterm, but xterm behaves as though tmux is not there.

My .tmux.conf file at present contains one line:

set -g mouse on

I can start Alacritty, then tmux. Right-click and the tmux context appears. This is great, exactly what I expect.

However, when I run tmux in xterm, right-clicking simply selects a number of lines. It's the same as if tmux was not running and I was just clicking in an xterm window.

I have the same problem and can't provide a solution for this. I never
tried Alacritty, though.

The Arch Wiki has some info:
<https://wiki.archlinux.org/title/Tmux#Scrolling_issues>
but nothing that helped me.

If you type ^B :, it'll take you to the prompt. I've tried the Arch
Wiki's snippet `display "Mouse: #{?mouse,ON,OFF}"` and it does react to
the `set -g mouse on` option, but either way it's set seems to make no
difference.

I have resigned myself to exclusively using the keyboard in xterm. On
Wayland I think the cursor might work but non-Sway window managers seem
to have some bugs.

My default value of TERM is xterm. Changing this to xterm-256color does not help. Inside tmux, TERM is screen, which I guess is OK (?).

The following sets in-tmux TERM to whatever you want. tmux-direct isn't
recognized by most applications, so I probably set mine wrong!

        set -g default-terminal "tmux-direct"

Since I wanted this at the same time, in case you might, these are the
tmux.conf(5) lines that got me working colors in Helix:

        set -a terminal-features 'xterm-256color:RGB'
        set -sa terminal-overrides ",xterm*:Tc"

This bit actually did work for me.

Looking around, I get the impression this should Just Work and it's a mystery to me that it doesn't.

It's been my experience that tmux will work expectedly when it wants to
(the software distributors have packaged in the magic sauce that makes
it all go together) but will require some kneading when it doesn't.

Another tip for you:

        set -s copy-command 'xsel -bi' # X11

But you can read the man pages for this one. Besides, it won't do
anything while we have these troubles.

:3 <3 -3

Reply via email to