5

When in copy mode in tmux, using the mouse is there a way to select text, and scroll the window up at the same time? When selecting text the buffer does not scroll up when I reach the top boundary.

I have set-window-option -g mode-mouse on in my /.tmux.conf

1

2 Answers 2

4

From my .tmux.conf:

# Using scroll 
setw -g mode-mouse on

# Sane scrolling
set -g terminal-overrides 'xterm*:smcup@:rmcup@'

This enables the scrolling with mouse and during the selection, it can go beyond the boundaries. Just hold shift when you're selecting.

It works for me using Mint linux.

1
  • 1
    You could edit your answer for the newer versions of tmux. So it should be setw -g mouse on. The scrolling and selecting is working like a charm. Feb 10, 2022 at 11:56
3

To allow both mouse scroll and select on tmux 2.1 and above, set -g mouse on in ~/.tmux.conf is sufficient.

As @RobisonSantos said, you should hold Shift key to copy selection.

2
  • But how can we select and scroll at the same time? Your suggestion I have already applied and still I am only able to select what is shown on the current window. It seems like that shift is blocking to scroll. Is there any other tip or trick too? Feb 10, 2022 at 11:51
  • 2
    @PiMathCLanguage does setw (set-window-option) work better for you ?
    – Noam Manos
    Feb 25, 2022 at 15:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .