Created
August 15, 2018 22:50
-
-
Save aerosol/75b0287bd40d69b51b5db83acebaba7b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function! WinZoomToggle() abort | |
if !exists('w:WinZoomIsZoomed') | |
let w:WinZoomIsZoomed = 0 | |
endif | |
if w:WinZoomIsZoomed == 0 | |
execute "tabedit %" | |
let w:WinZoomIsZoomed = 1 | |
elseif w:WinZoomIsZoomed == 1 | |
execute "tabclose" | |
let w:WinZoomIsZoomed = 0 | |
endif | |
endfunction | |
nmap <leader>z :call WinZoomToggle()<cr> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment