Reputation: 247
We can highlight different marks in vim using mark.vim but, how can I highlight a line in Vim?
For example:
Line One
Line Two
Line Three
I let the cursor on line one, I highlight line one
, the whole line is highlighted.
Then I type jj
to move to line 3, the line one is highlighted too, but didn't disappear.
Upvotes: 5
Views: 11851
Reputation: 172778
If you're looking for the permanent highlighting of the current line, following along with the cursor, that's a built-in feature of Vim since version 7.0. To activate this, put the following into your ~/.vimrc
:
set cursorline
Upvotes: 5
Reputation: 4821
Use v
to get into visual mode. <shift>v
will highlight the entire line and <ctrl>v
will take you into visual block mode so you can highlight columns.
Upvotes: 9