Created
September 27, 2010 12:56
-
-
Save todesking/598976 to your computer and use it in GitHub Desktop.
More vivid, interactive vim
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
let s:color='#ff0000' | |
function! s:fire() | |
if s:color == '#ff0000' | |
let s:color = '#0000ff' | |
elseif s:color == '#0000ff' | |
let s:color = '#00ff00' | |
elseif s:color == '#00ff00' | |
let s:color = '#ff0000' | |
endif | |
execute 'highlight Normal guibg='.s:color | |
endfunction | |
autocmd CursorMovedI * call s:fire() | |
autocmd CursorMoved * call s:fire() | |
autocmd CursorHold * call s:fire() | |
autocmd CursorHoldI * call s:fire() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment