Can't use mouse properly when running vim in tmux
There are two settings that you need to configure for this to work.
In your
.vimrc
add:set ttymouse=xterm2 set mouse=a
In your
.tmux.conf
add:set -g mouse on
You will then be able to use the mouse to select blocks of text, resize splitted windows, ...
The answer by @jasonwryan won't work as of tmux 2.1 since the several mouse options were merged into one configuration called mouse
.
The new approach is:
In your
.vimrc
add:set ttymouse=xterm2 set mouse=a
In your
tmux.conf
add:set -g mouse on