Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

After doing a search in Vim, I get all the occurrences highlighted.

(在Vim中进行搜索后,我将所有出现的事件突出显示。)

How can I disable that?

(如何禁用它?)

I now do another search for something gibberish that can't be found.

(我现在再次搜索找不到的乱码。)

Is there a way to just temporarily disable the highlight and then re-enable it when needed again?

(有没有一种方法可以暂时禁用突出显示,然后在需要时重新启用它?)

  ask by Gabriel Solomon translate from so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
432 views
Welcome To Ask or Share your Answers For Others

1 Answer

To turn off highlighting until the next search:

(要关闭高亮显示直到下一次搜索:)

:noh

Or turn off highlighting completely:

(或完全关闭突出显示:)

set nohlsearch

Or, to toggle it:

(或者,要切换它:)

set hlsearch!

nnoremap <F3> :set hlsearch!<CR>

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...