aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugin/vim-under-the-cursor.vim6
1 files changed, 4 insertions, 2 deletions
diff --git a/plugin/vim-under-the-cursor.vim b/plugin/vim-under-the-cursor.vim
index 66e661d..cc31e36 100644
--- a/plugin/vim-under-the-cursor.vim
+++ b/plugin/vim-under-the-cursor.vim
@@ -45,13 +45,15 @@ function! HighlightWordUnderCursor()
45 exec 'syntax clear ' . l:color 45 exec 'syntax clear ' . l:color
46 exec 'syntax match ' . l:color . ' /\#' . l:q . '\>/' 46 exec 'syntax match ' . l:color . ' /\#' . l:q . '\>/'
47 else 47 else
48 silent! call matchadd('Underline', '\<'.l:currentword.'\>', -1, w:m1) 48 silent! call matchadd('Underlined', '\<'.l:currentword.'\>', -1, w:m1)
49 endif 49 endif
50 endif 50 endif
51endfunction 51endfunction
52 52
53" set updatetime=100 53" set updatetime=100
54highlight! Underline cterm=underline gui=underline 54
55" see `:help group-name`
56highlight! Underlined cterm=underline gui=underline
55autocmd CursorMoved,InsertLeave,TextChanged * call HighlightWordUnderCursor() 57autocmd CursorMoved,InsertLeave,TextChanged * call HighlightWordUnderCursor()
56 58
57" vim: expandtab tabstop=4 sw=4 59" vim: expandtab tabstop=4 sw=4
..