From: Oleg Broytman Date: Thu, 21 Aug 2014 08:37:25 +0000 (+0400) Subject: Redraw screen to restore cursor and xterm title X-Git-Url: https://git.phdru.name/?a=commitdiff_plain;h=e0b3af196fc0530f97b34473ea48fa623c7be1ee;p=dotfiles.git Redraw screen to restore cursor and xterm title Redraw screen on BufWinEneter instead of BufReadPost. --- diff --git a/.vimrc b/.vimrc index f7404f7..422f97d 100644 --- a/.vimrc +++ b/.vimrc @@ -565,6 +565,8 @@ endif function! AutoEncoding() if &modified && &fileencoding != "" call SetupEncoding(&fileencoding) + else + redraw endif autocmd! auto-encoding augroup! auto-encoding @@ -723,14 +725,5 @@ command! UName call Uname() endif " ---------- -augroup redraw-once -autocmd! -" Redraw screen after all macros in ~/.vimrc and ~/.vim/ -autocmd BufReadPost * redraw -" Remove the redraw autocommand (it's only needed once) and the group -autocmd BufReadPost * autocmd! redraw-once -autocmd BufReadPost * augroup! redraw-once -augroup END - " This has to go to the very end of ~/.vimrc to allow reading the .vimrc set secure " safer working with script files in the current directory