Skip to content

Commit

Permalink
fix(highlight): add list highlight before VimEnter
Browse files Browse the repository at this point in the history
Closes #4665
  • Loading branch information
chemzqm committed Sep 2, 2023
1 parent fab88b2 commit 654083c
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions plugin/coc.vim
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ function! s:Enable(initialize)
endif
endfunction

function! s:static_highlight() abort
function! s:StaticHighlight() abort
hi default CocSelectedText ctermfg=Red guifg=#fb4934 guibg=NONE
hi default CocCodeLens ctermfg=Gray guifg=#999999 guibg=NONE
hi default CocUnderline term=underline cterm=underline gui=underline guisp=#ebdbb2
Expand Down Expand Up @@ -495,7 +495,8 @@ function! s:static_highlight() abort
hi default link CocFloatDividingLine CocVirtualText
endfunction

call s:static_highlight()
call s:StaticHighlight()
call s:AddAnsiGroups()

function! s:Highlight() abort
if coc#highlight#get_contrast('Normal', has('nvim') ? 'NormalFloat' : 'Pmenu') > 2.0
Expand Down Expand Up @@ -559,8 +560,6 @@ function! s:Highlight() abort
exe 'hi default link CocInlayHint'.name.' CocInlayHint'
endfor

call s:AddAnsiGroups()

if get(g:, 'coc_default_semantic_highlight_groups', 1)
let hlMap = {
\ 'Namespace': ['@namespace', 'Include'],
Expand Down

0 comments on commit 654083c

Please sign in to comment.