Skip to content

Instantly share code, notes, and snippets.

@todesking
Created September 27, 2010 12:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save todesking/598976 to your computer and use it in GitHub Desktop.
Save todesking/598976 to your computer and use it in GitHub Desktop.
More vivid, interactive vim
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