Closed neerajbadlani closed 2 years ago
Just encounter a similar problem which comes from vim-lsp-cxx-highlight set its own color.
My solution is linking these syntax groups defined by vim-lsp-cxx-highlight into the common highlight groups.
" In vim-lsp-cxx-highlight/syntax/lsp_cxx_highlight.vim
" Syntax Highlighting:
"
" Custom Highlight Groups
" if g:lsp_cxx_hl_light_bg
" hi default LspCxxHlGroupEnumConstant ctermfg=Magenta guifg=#573F54 cterm=none gui=none
" hi default LspCxxHlGroupNamespace ctermfg=Yellow guifg=#3D3D00 cterm=none gui=none
" hi default LspCxxHlGroupMemberVariable ctermfg=Black guifg=Black
" else
" hi default LspCxxHlGroupEnumConstant ctermfg=Magenta guifg=#AD7FA8 cterm=none gui=none
" hi default LspCxxHlGroupNamespace ctermfg=Yellow guifg=#BBBB00 cterm=none gui=none
" hi default LspCxxHlGroupMemberVariable ctermfg=White guifg=White
" endif
hi default link LspCxxHlGroupEnumConstant Constant
hi default link LspCxxHlGroupNamespace Type
hi default link LspCxxHlGroupMemberVariable Identifier
I just sent a pull request #62 to solve this.
You can override the custom groups in syntax/lsp_cxx_highlight.vim without modifying the plugin. There's a reason why highlight
has the argument default
, it's to allow plugins to define a default and the user can override them.
" Link to another highlight group
hi link LspCxxHlGroupEnumConstant Constant
" or set a specific color
hi LspCxxHlGroupEnumConstant ctermfg=Magenta guifg=#573F54 cterm=none gui=none
Note the lack of default
after hi
.
Describe the bug Colors doesnt look right
To Reproduce Install Plugin
Expected behavior Configurable Colors ?
Screenshots Before :
After :
Configuration (Fill this out):
vimrc
orinit.vim
that you think are relevant to vim-lsp-cxx-highlight NoneLog File: Enable logging by adding these lines:
Then post the contents of the log file:
Additional context Add any other context about the problem here.