Skip to content

Instantly share code, notes, and snippets.

@madx
Created February 6, 2013 13:16
Show Gist options
  • Save madx/4722433 to your computer and use it in GitHub Desktop.
Save madx/4722433 to your computer and use it in GitHub Desktop.
Using Alt+Mouse for block selection and Shift+Mouse for line selection in Vim
" Block/Line selection with mouse
noremap <M-LeftMouse> <4-LeftMouse>
inoremap <M-LeftMouse> <4-LeftMouse>
onoremap <M-LeftMouse> <C-C><4-LeftMouse>
noremap <M-LeftDrag> <LeftDrag>
inoremap <M-LeftDrag> <LeftDrag>
onoremap <M-LeftDrag> <C-C><LeftDrag>
noremap <S-LeftMouse> <3-LeftMouse>
inoremap <S-LeftMouse> <3-LeftMouse>
onoremap <S-LeftMouse> <C-C><3-LeftMouse>
noremap <S-LeftDrag> <LeftDrag>
inoremap <S-LeftDrag> <LeftDrag>
onoremap <S-LeftDrag> <C-C><LeftDrag>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment