mirror of
https://github.com/osyo-manga/vim-brightest.git
synced 2025-11-08 11:33:54 -05:00
Improve clear highlight.
This commit is contained in:
@@ -72,6 +72,10 @@ endfunction
|
|||||||
|
|
||||||
let s:old_enable_window_all = g:brightest#enable_highlight_all_window
|
let s:old_enable_window_all = g:brightest#enable_highlight_all_window
|
||||||
function! brightest#hl_clear()
|
function! brightest#hl_clear()
|
||||||
|
if empty(s:Highlight.hl_list())
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
" call s:Highlight.as_windo().disable_all()
|
||||||
if g:brightest#enable_highlight_all_window
|
if g:brightest#enable_highlight_all_window
|
||||||
\ || s:old_enable_window_all
|
\ || s:old_enable_window_all
|
||||||
call s:Highlight.as_windo().disable_all()
|
call s:Highlight.as_windo().disable_all()
|
||||||
@@ -262,6 +266,7 @@ function! s:is_enable_on_cursorhold()
|
|||||||
return g:brightest#enable_on_CursorHold && get(b:, "brightest_enable_on_CursorHold", 1)
|
return g:brightest#enable_on_CursorHold && get(b:, "brightest_enable_on_CursorHold", 1)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
function! brightest#on_CursorHold()
|
function! brightest#on_CursorHold()
|
||||||
if s:is_enable() && s:is_enable_on_cursorhold()
|
if s:is_enable() && s:is_enable_on_cursorhold()
|
||||||
call brightest#highlighting()
|
call brightest#highlighting()
|
||||||
|
|||||||
Reference in New Issue
Block a user