In vim, is it possible to highlight a search pattern without moving the cursor?
For example, if I want to find m_depthTable
I could do:
/m_depthTable
and that will highlight all instances of m_depthTable
, but it will also move to the next occurance.
I want to highlight without moving. Possible?
You could do a substitute command with the n flag. This won't move the cursor or do the substitute.
:s/pattern//n
just
/pattern<enter>
then press ``
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With