2

One can change the search color of search terms with the Search highlight scheme. Similarly one can change the color of a line in the quickfix window with QuickFixLine.

However, how does one change the colour of the search phrase within listing in the quick fix window?

A picture is worth 1000 word, hence in the following image, I :vimgrep searched for 'buffer', and I underlined some matches in yellow with a screen grab tool, is it possible to highlight them in vim (in particular Neovim)?: enter image description here

4

Two ideas:

  1. If you just want to highlight them, search with /buffer and make sure hlsearch is on. Or, for a more permanent solution, navigate to the quickfix window and use :match Search /buffer/
  2. If you care more about filtering, I would do :packadd cfilter, which provides the :Cfilter command. Then a :Cfilter /buffer/ gives you only entries with buffer, and :colder restores the original. (Of course, given that the original search was buffer, OP won't be able to limit in this way.)
| improve this answer | |
  • Searching within the quick fix window does make it highlight. But then one has to type the search term twice. I wonder if there is anyway to make it automatically search for it upon opening the quickfix window. – run_the_race Apr 11 at 16:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.