Same line diffs are hard to make of
bitigchi opened this issue · 10 comments
It looks like you aren’t running with True Colour. Can you try running set termguicolors
?
It all went grey after set termguicolors
.
It all went grey after set termguicolors.
Sounds like your environment does not support True Color. Can you try with a new iTerm profile without tmux or anything like that, with the terminal type set to xterm-256color
(change that from iTerm > Preferences… > Profiles > > Terminal > Terminal Emulation > Report terminal type), with an up-to-date Vim with only this in the config:
filetype plugin indent on
syntax enable
set termguicolors
colorscheme xcodedark
Can you also make sure that you don’t have anything like export TERM=xyz
in your shell configuration, because the terminal emulator is meant to do that itself and might mess it up.
Well, this is weird, because my terminal is/was already set to 256 colours. iTerm2 settings are fine, and this was my .vimrc
regarding colour and syntax. I tried with a new profile and the results were the same.
if &t_Co > 1
syntax enable
endif
colorscheme xcodedark
set t_Co=256
Do you get a different highlighting with a same line diff?
set t_Co=256
This is a Bad Idea because it forces Vim to use the limited 256-colour palette rather than something else. Vim works out what colour palette it has available automatically and makes use of it. Did you remove this line during testing?
Just for purposes of demonstration, here is the famous Solarized colourscheme with True Colour:
and here it is without:
Screenshots from solarized8.
Okay, update. This one worked, and the colours are much more beautiful now. I can get proper orange line highlighting in iTerm2, but not in tmux, I'm gonna poke that a little bit more now! Closing, and thanks for the assistance. Nice!
Edit: After an iTerm restart, tmux works fine too!
tmux works fine too!
Glad you managed to get it working in your preferred environment!