Vim Tips Wiki

Switching between files

Revision as of 11:28, April 24, 2008 by JohnBot (Talk | contribs)

1,615pages on
this wiki
Tip 195 Printable Monobook Previous Next

created January 9, 2002 · complexity basic · author Kontra, Gergely · version 5.7

When you edit multiple files, you often need to change windows.

You can set up Vim in windows and gvim to switch between windows with the commonly used Ctrl-Tab and Ctrl-Shift-Tab

The mappings

nmap <C-Tab> <C-w>w
nmap <C-S-Tab><C-w>W

They wrap around.



I don't know which way is better, but I couldn't get that way to work. So I use this instead.

:map <C-Tab> :bn<CR>
:map <C-S-Tab> :bp<CR>

Around Wikia's network

Random Wiki