tags:

views:

136

answers:

1

Hello.

VIM can be configured to highlight current line via :hi cursorline guibg=green and set cursorline commands. But if I enable tabs display via:

:hi specialkey guifg=grey guibg=grey
:set listchars="tab"
:set list

Cursor line highlight will corrupt tabs display:

alt text

Any hints how i can avoid corruption so may tabs are highlighted with one color and cursor line is highlighted with another color without any ^I displayed at intersection?

+2  A: 

Try setting listchars without the quotes:

:set listchars=tab:>-

This shows the tab as >------- instead of ^I, which I think is what you were asking. When the cursor is on the line with the tab, the whole line is displayed in the cursorline colour.

It appears that the cursorline colour takes precedence over the specialkey colour, which is consistent with your screenshot.

Greg Hewgill
Maybe it's somehow possible to use space character for displaying tabs in different color? syntax is `tab:xy`, but how to specify space for `x` and `y`? Maybe some escape notation?
Eye of Hell
Ah, i found this out:`:set listchars=tab\ \ ,`You can edit your answer for further search.
Eye of Hell