-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Guard setting g:terminal_ansi_colors for <=256 colors terminal emulators #66
Comments
It looks like we use the same binary in the same terminal emulator. That is quite convenient ;-). In the screenshot above, both Terminal.app windows are started with a custom profile intended to match default 256c xterm. On the right window is the output of one of those shell scripts that you can find online. The jarring colors are, as expected, those defined at the terminal emulator level. On the left, you have Vim with Apprentice and the same shell script executed in This is really surprising to me because:
Since I am not in "GUI mode" and After experiencing with:
I get this output: where #11AAFF appears to be averaged to #00AFFF, which would be the hexadecimal notation of the closest color in the xterm palette. So it looks like the doc is not quite up-to-date with what is really going on : Weird. I guess something like this would work:
|
@craigmac I just pushed a fix to master, could you try it? |
Works as intended, thank you for putting so much time into looking at this, much appreciated! |
I'm using the latest MacVim which also provides a
/Applications/MacVim.app/Contents/bin/vim
TUI version. The issue is that on Terminal.app using that TUI when we open a:term
the colors are off because even though:version
reports '+termguicolors' Terminal.app cannot do that. My suggestion would be to guard setting the ansi colors somehow. I have Terminal.app using the Apprentice palette as well, that's how I noticed the difference when opening a terminal buffer (blue becomes purple-y)For now, I've just commented out the defined terminal ansi colors in apprentice.vim and let my terminal palette (set to Apprentice) handle it. I'm not sure how you'd fix it, I first thought about adding:
But in my example above it would still pass. Maybe you'd have to do something like:
But then you might end up having to add a bunch of exceptions like this.
The text was updated successfully, but these errors were encountered: