vim-maximizer : Maximizes and restores the current window in Vim.
| script karma
Downloaded by 234
Comments, bugs, improvements
script versions (upload new version)
Maximizer lets you maximize split windows and restore them automatically. It is very useful if you like to have many split windows per tab. And also, if the text you are working with does not ...subscribe to the ridiculous Church of 80-character Lines.... It means, while working with Ruby on Rails code. ;) Or just with lengthy HTML files.
Maximizer has only one command:
It is meant to be mapped in many ways by the user himself. See Configuration to get some examples.
Upon the first invocation of the command, Vim-Maximizer saves dimensions and positions of all windows in the current tab, and then it performs maximization of the active window. The second time the command is invoked, Maximizer restores all windows to the previously saved positions and the cycle repeats.
Maximizer is extremely handy with command mappings. The mappings can be defined for normal, insert, and visual modes. Here is the example of the <F3> key usage. You can paste it directly into your .vimrc file.
nnoremap <silent><F3> :MaximizerToggle<CR>
vnoremap <silent><F3> :MaximizerToggle<CR>gv
inoremap <silent><F3> <C-o>:MaximizerToggle<CR>
With these mappings you can hit <F3> any time, not only in normal mode. Other handy situations may include typing some text while you don't fit the current split window or selecting some long lines in the visual mode. Just try it yourself.
Maximizer respects minimal allowed window size, both vertically and horizontally. By default the minimal window height and width are set to 1. You can change those values by tweaking 'winminheight' ('wmh') and 'winminwidth' ('wmw') settings in your .vimrc.
Author and License
Maximizer was written by Szymon Wrozynski. It is licensed under the same terms as Vim itself.
Copyright © 2012 Szymon Wrozynski. See :help license
Place in ~/.vim/plugin/maximizer.vim or in case of Pathogen:
git clone https://github.com/szw/vim-maximizer.git
The most recent version can be found here: https://github.com/szw/vim-maximizer
Click on the package to download.
ip used for rating: 184.108.40.206