File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 1
1
" Vim auto-load script
2
2
" Author: Peter Odding <peter@peterodding.com>
3
- " Last Change: September 26 , 2011
3
+ " Last Change: September 29 , 2011
4
4
" URL: http://peterodding.com/code/vim/notes/
5
5
6
6
" Note: This file is encoded in UTF-8 including a byte order mark so
7
7
" that Vim loads the script using the right encoding transparently.
8
8
9
- let g: xolox #notes#version = ' 0.11.5 '
9
+ let g: xolox #notes#version = ' 0.11.6 '
10
10
11
11
function ! xolox#notes#shortcut () " {{{1
12
12
" The "note:" pseudo protocol is just a shortcut for the :Note command.
@@ -712,7 +712,9 @@ function! xolox#notes#highlight_names(force) " {{{3
712
712
let titles = filter (xolox#notes#get_titles (1 ), ' !empty(v:val)' )
713
713
call map (titles, ' s:words_to_pattern(v:val)' )
714
714
call sort (titles, ' s:sort_longest_to_shortest' )
715
- syntax clear notesName
715
+ if hlexists (' notesName' )
716
+ syntax clear notesName
717
+ endif
716
718
execute ' syntax match notesName /\c\%>2l\%(' . escape (join (titles, ' \|' ), ' /' ) . ' \)/'
717
719
let b: notes_names_last_highlighted = localtime ()
718
720
call xolox#misc#timer#stop (" notes.vim %s: Highlighted note names in %s." , g: xolox #notes#version , starttime)
You can’t perform that action at this time.
0 commit comments