Monday, May 22, 2006

Vim tabs

Recently stable version of vim 7.0 was released. TabPage is one of the notable feature additions in Vim 7.0. In the earlier versions tabs could have been (sort of) simulated using buffers. Now we can explicitly create tabs and have multiple windows within them. Some vim settings that i have done to make tabbed vimming more convenient (firefox-ish):- 1. Clicking on a file should open it in existing gvim but in a new tab For this i have created a batch file in which gvim is invoked with --remote-tab-silent option ( gvim --remote-tab-silent %1 ). Then i have associated the text files which were previously bound to open with gvim to be opened using this batch file. 2. Creating new tab using Ctrl-t Added following mapping to the vimrc file -- map :tabnew In vim we can shift tabs using [tabnumber]gt and in gvim we can also use the more familiar Ctrl-[pageUp/pageDown] shortcuts by default.
To know more about Vim's tabpage feature check out the documentation at or :help tabpage from within vim. A good review of some cool features introduced in vim 7.0


Post a Comment

<< Home

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 2.5 License.