]> git.r.bdr.sh - rbdr/dotfiles/blob - vim/plugin/ZoomWinPlugin.vim
Delete a bunch of stuff, better arrange submodules
[rbdr/dotfiles] / vim / plugin / ZoomWinPlugin.vim
1 " ZoomWin: Brief-like ability to zoom into/out-of a window
2 " Author: Charles Campbell
3 " original version by Ron Aaron
4 " Date: Jan 16, 2009
5 " Version: 23e ASTRO-ONLY
6 " History: see :help zoomwin-history {{{1
7 " GetLatestVimScripts: 508 1 :AutoInstall: ZoomWin.vim
8
9 " ---------------------------------------------------------------------
10 " Load Once: {{{1
11 if &cp || exists("g:loaded_ZoomWinPlugin")
12 finish
13 endif
14 if v:version < 702
15 echohl WarningMsg
16 echo "***warning*** this version of ZoomWin needs vim 7.2"
17 echohl Normal
18 finish
19 endif
20 let s:keepcpo = &cpo
21 let g:loaded_ZoomWinPlugin = "v23"
22 set cpo&vim
23 "DechoTabOn
24
25 " ---------------------------------------------------------------------
26 " Public Interface: {{{1
27 if !hasmapto("<Plug>ZoomWin")
28 nmap <unique> <c-w>o <Plug>ZoomWin
29 endif
30 nnoremap <silent> <script> <Plug>ZoomWin :set lz<CR>:silent call ZoomWin#ZoomWin()<CR>:set nolz<CR>
31 com! ZoomWin :set lz|silent call ZoomWin#ZoomWin()|set nolz
32
33 au VimLeave * call ZoomWin#CleanupSessionFile()
34
35 " ---------------------------------------------------------------------
36 " ZoomWin: toggles between a single-window and a multi-window layout {{{1
37 " The original version was by Ron Aaron.
38 " This function provides compatibility with previous versions.
39 fun! ZoomWin()
40 call ZoomWin#ZoomWin()
41 endfun
42
43 " ---------------------------------------------------------------------
44 " Restore: {{{1
45 let &cpo= s:keepcpo
46 unlet s:keepcpo
47 " ---------------------------------------------------------------------
48 " Modelines: {{{1
49 " vim: ts=4 fdm=marker