How would one go about modifying the colour of vim's tab bar?
I have tried using
:hi TabLineFill ctermbg=N
which does change the colour of the tab bar's background to the colour that 'N' signifies, but this is all I have managed to glean from Googling. I had a look at :help cterm-colors
, but I did not gain much more of an understanding from it.
Would I be able to use this highlight facility to change the colour of an active tab's foreground and background, and an inactive tab's foreground and background? If so, how would I go about doing this?
You can do the following, for example:
:hi TabLineFill ctermfg=LightGreen ctermbg=DarkGreen :hi TabLine ctermfg=Blue ctermbg=Yellow :hi TabLineSel ctermfg=Red ctermbg=Yellow
This line affects the window counter per tab:
:hi Title ctermfg=LightBlue ctermbg=Magenta
Garish colours chosen to highlight what each of the items changes.
I find that looking at $VIMRUNTIME/colors/*.vim
really helps when playing with highlighting.
Note that these change the colours for Vim running in a console. If you want to change the colours for GVim, you need to use guibg
, guifg
, et cetera. For example:
:hi TabLineFill guifg=LightGreen guibg=DarkGreen ctermfg=LightGreen ctermbg=DarkGreen
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