-
-
Notifications
You must be signed in to change notification settings - Fork 6k
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
[RFC] tui: Add support for true color terminals #2198
Conversation
For anyone wondering, mintty does not support true color: https://code.google.com/p/mintty/issues/detail?id=431 And here's a comprehensive list of true color support across terminals: |
This means the current TUI supports |
Is there any particular reason this is being done with an environment variable? I'm not a huge fan of adding yet another option, but it makes sense over an environment variable in this case IMO. The few env vars |
@pyrohh Neither am I but we need some way to set the option per UI. E.g., ,one TUI may be running in a 16-color terminal, the other in 16-million, both connected to the same Once we figure out a better approach, we can avoid many env vars currently floating around. @rainerborene Yes. |
@justinmk that's a good point, but I wonder if something like that could be automatically detected instead. |
@justinmk In fact I've started to adding true color support in the mintty, but not finished yet (lacking free time hardly) https://github.com/XVilka/mintty/commits/master (see last 3 commits). |
@pyrohh I don't like using environment variables either, but it is better than introduce coupling between the core and the UI. Later I will add support for UI-specific configuration through vimscript variables. |
@XVilka very cool. Thanks for maintaining that gist also! |
@tarruda I see, that certainly makes sense. |
@tarruda My 24-bit-xterm branch allows setting and removing true color support in the running Vim instance which is good should you add this to the vimrc and forget to add checks for terminal not supporting this. About VimL variables: how should this work given that there are no notifications for variable changes? Specifically for this case I would simply check variable on full redraw, but this is slightly worse then 24-bit-xterm variant where |
Also @tarruda has a valid concern which is not solved neither by VimL variables nor by options. Except that if you have some identifier unique to each connected UI (e.g. position of UI in uis or Thus I would suggest using
|
This is enabled by setting the `$NVIM_TUI_ENABLE_TRUE_COLOR` environment variable, eg: ``` $ NVIM_TUI_ENABLE_TRUE_COLOR=1 nvim ```
@ZyX-I one way to enable a running instance is by setting |
@tarruda do you plan on documenting that variable? I'll send a PR for it if not. |
I'd appreciate if you did. While your'e at it, could you also document |
Already on my to-do list :) On March 20, 2015 4:09:51 PM EDT, Thiago de Arruda notifications@github.com wrote:
|
http://lists.schmorp.de/pipermail/rxvt-unicode/2013q3/001834.html Rxvt-unicode refuses to support 'true colour', with the above explanation. Is it worth attempting to use colour in that way, as opposed to this way? |
@woegjiub more than 24 bit colors is useless for Neovim since you cant specify the alpha component in color schemes. I've seen that post and their argument is weak. It can be simplified as "Since terminfo exposes codes of changing the color palette, programs should use that(because its "portable") even though its much hackier and messier than simply specifying the RGB colors directly." Terminfo is not reliable and does not support some new terminal features such as bracketed paste, thats why many terminals follow "xterm compliance" instead of being limited to what is available on terminfo. |
I'm trying this feature with the solarized scheme and works great, but when I open nvim, the colorscheme isn't being loaded. I have to set the colorscheme again, even if it's declared in my .nvimrc. thanks! |
@pacuna I think this is related to how colorschemes are initialized using |
@tarruda yeah that did the trick :D, thanks!! |
This is enabled by setting the
$NVIM_TUI_ENABLE_TRUE_COLOR
environment variable, eg:Close #59