mirror of https://github.com/nirenjan/dotfiles.git
Rework long-lines plugin to use colorcolumn
This will always highlight characters that exceed the 80 character limit with ErrorMsg, but will also highlight the 81st column, so the user knows when to break.vimbundler
parent
29929266eb
commit
5c6495c981
|
@ -16,9 +16,11 @@
|
|||
" NOTE:
|
||||
" This file will highlight all characters from column 81 onwards
|
||||
"
|
||||
" Nirenjan Krishnan nirenjan@gmail.com 2008/12/16
|
||||
" Nirenjan Krishnan nirenjan@gmail.com 2013/01/19
|
||||
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
|
||||
match LineTooLong '\%>80v.\+'
|
||||
highlight LineTooLong cterm=bold ctermbg=red guibg=LightYellow
|
||||
if exists('+colorcolumn')
|
||||
set colorcolumn=81
|
||||
endif
|
||||
|
||||
autocmd BufWinEnter * let w:m2=matchadd('ErrorMsg', '\%>80v.\+', -1)
|
||||
|
|
Loading…
Reference in New Issue