I want to highlight breakpoint()
- including brackets as keywords in Python files.
I have added these two commands to my .vimrc
:
highlight link PyBreakpoint Keyword
call matchadd("PyBreakpoint", '\<breakpoint\(\)\>')
However, only the breakpoint
word gets matched and highlighted. How could I match the brackets also in order to apply the color to them also?
\(
creates groups. Try:help pattern
. Also, you might want to useafter/syntax/python.vim
and the syntax machinery; matches are somewhat limited