Permalink
Browse files

Resize focused window to be at least 78 columns

  • Loading branch information...
lmarburger committed Jan 17, 2013
1 parent 52a9ad6 commit 634ca89e9c2ae9cbdcc7dcd87bce21125f8af5e6
Showing with 10 additions and 0 deletions.
  1. +10 −0 vimrc
View
10 vimrc
@@ -168,6 +168,16 @@ augroup PlantUML
autocmd BufLeave *.plantuml nmap <leader>. :call RunTestFile()<CR>
augroup END
+augroup SizeWindow
+ autocmd!
+ autocmd WinEnter * call SizeWindow()
+augroup END
+
+function! SizeWindow()
+ if winwidth(winnr()) < 78
+ exec "vertical resize 78"
+ end
+endfunction
" Shamelessly ripped from Gary Bernhardt's vimrc
" https://github.com/garybernhardt/dotfiles/blob/master/.vimrc

0 comments on commit 634ca89

Please sign in to comment.