Skip to content

Commit

Permalink
Bug fix: Restore highlighting of note names that end in punctuation
Browse files Browse the repository at this point in the history
The old code used \< word boundaries \> so that for example the note name
"git" wasn't highlighed when inside an unrelated word like "digits".
I just found out that this breaks highlighting of note names that
end in punctuation, for example ")".
  • Loading branch information
xolox committed Jul 23, 2011
1 parent cbc894e commit 56e23b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion autoload/xolox/notes.vim
Expand Up @@ -756,7 +756,7 @@ function! xolox#notes#highlight_names(force) " {{{3
call map(titles, 's:words_to_pattern(v:val)')
call sort(titles, 's:sort_longest_to_shortest')
syntax clear notesName
execute 'syntax match notesName /\c\%>2l\<\%(' . escape(join(titles, '\|'), '/') . '\)\>/'
execute 'syntax match notesName /\c\%>2l\%(' . escape(join(titles, '\|'), '/') . '\)/'
let b:notes_names_last_highlighted = localtime()
call xolox#misc#timer#stop("notes.vim %s: Highlighted note names in %s.", g:notes_version, starttime)
endif
Expand Down
2 changes: 1 addition & 1 deletion plugin/notes.vim
Expand Up @@ -11,7 +11,7 @@ if &cp || exists('g:loaded_notes')
finish
endif

let g:notes_version = '0.10.4'
let g:notes_version = '0.10.5'

" Make sure the default paths below are compatible with Pathogen.
let s:plugindir = expand('<sfile>:p:h') . '/../misc/notes'
Expand Down

0 comments on commit 56e23b6

Please sign in to comment.