0

I use the solution from this question to display tabs with litlle ⸱ characters. It works but they appear on a lighter gray background than the dark gray background I am using. It is quite distracting as unimportant information is highlighted.

Is there a way to avoid that ? What should I do ?

I am using vim with the beloved solarized8 theme. I have the same behavior on Gnome Terminal, Terminator and Alacritty.

Thanks in advance.

4
  • 2
    Read :help 'listchars' (almost at the end).
    – Matt
    May 5 at 15:00
  • 1
    And/or :help hl-SpecialKey.
    – filbranden
    May 5 at 15:02
  • Thanks @Matt and filbranden. From what I understand tabs are now highlighted as specified by the SpecialKey group. How do I make them higlighted as the NonText group for example ?
    – cassepipe
    May 5 at 15:47
  • 2
    @cassepipe :h 'hl' (Vim only, not supported in Neovim).But, I think, it' more common to set it up the other way round (i.e. to change colorscheme / SpecialKey colors). I'm pretty sure there were many similar questions asked already.
    – Matt
    May 5 at 17:07
1

The lazy way is to put hi SpecialKey ctermbg=NONE in your .vimrc after calling in your favorite colorscheme.

Else you can read this gist and learn some true vim wizardry : https://gist.github.com/romainl/379904f91fa40533175dfaec4c833f2f

Why SpecialKey ? The answer resides at the end of the :help 'listchars' section of the help pages.

1

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.