As the title suggests, I want to select a pane in tmux by just doing mouse over on the pane, like it can be done with Gnome Terminal. I don't want to click the pane to select it.
Is that possible?
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
Correct me if I am wrong, but I don't believe this is (easily) possible. The only reason that clicking between panes is possible is because your terminal application will forward mouse position to the terminal application on mouse click.
As an example, enable this in your
set-window-option -g mode-mouse on
With this enabled, the terminal cursor can be dragged around inside a
tmux pane. This shows why it is possible to click between panes, and resize panes with your mouse. Your terminal application (
xterm, for example) does the broadcasting of mouse cursor location to the terminal application, when you click.
tmux can then use that information to, for example, move the terminal cursor, or switch to/resize panes as I explained above.
I don't see any evidence online that someone has managed to do change
tmux panes by hovering over a different one.
Unless you rewrite parts of a terminal application so that it always broadcasts mouse location (even when you don't click), and then alter
tmux so that it always keeps track of it (or something similar), I don't see a solution.
I honestly just suggest adding this line to your
~/.tmux.conf file. It allows you to change panes just by clicking on a different one, which I don't see being much more inconvenient than only hovering over it:
set-option -g mouse-select-pane on