-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add terminal_colors for neovim #93
Conversation
Neovim has support for embedded terminals. However, the colors do not inherit from the parent shell settings, and end up looking funky. This commit adds 16 color support for Neovim's terminal. See: neovim/neovim#2897 (comment)
will the pr fix this issue? |
@wsdjeg I'm not quite sure what you are saying. |
I confirm this pr, fixes #104 (comment) |
You should probably switch to single quoted strings like the rest of the file. |
let g:terminal_color_11 = "#fabd2f" | ||
|
||
" neutral_blue + bright_blue | ||
let g:terminal_color_4 = "#458588" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
color four should same as vim's status line color,now it is blue,you can try run irssi
,which is a irc client,then you will see the status line backgrould color is blue.
Great! It works for me. |
any update on this if it's going to be merged or when? |
I think this should not be added to vim colorschem.terminal buffer should has same color with origin terminal. I use different color for neovim buffer and terminal. |
That's what I did for now, I added it to my |
@ahmedelgabri I know what you mean,but in neovim, terminal buffer is different from origin vim buffer, it should has same option as in terminal, such as hotkey, colors and so on, it will make neovim's terminal buffer become a really terminal. BTW, I do not see any colorscheme add this g:var into its repos. |
@wsdjeg What if you are using a GUI such as Nyaovim and you just want an embeded terminal in it? We call this embeded because it's a part of neovim but not of the terminal we use. So neovim should control it, just like the embeded terminal in IntelliJ, Sublime and so on. Besides, even in the terminal, does everything look the same as in a real terminal? Maybe not. Without these g:var things, some parts are in colors from terminal's theme while others from neovim's, which terns out that it looks just so wiered. |
@wsdjeg Or maybe we can make this an option? If you want it, enable it, else, do nothing. |
@zhranklin it should same as the terminal, if not that is due to your terminal has some different setting for this colors, for example I use termite, the config file is |
BTW,I think a good plugin, even if a colorschem should has strong default, and the default option should not make too many people anoiying. |
also, a very importent thing is, terminal buffer will load user's |
@wsdjeg Well the foreground and background colors are not the same as in the terminal, which make some texts even difficult to recognize (in my terminal), but maybe you are right in some ways. Now the thing is nyaovim doesn't has any way to config the value of ANSI colors. What if I want a theme on the terminal? In this case the proper 'default' should be following the color theme. And in case of considering the integrity of the appearance of neovim, some people would also want to follow the colors from the theme in the neovim. |
@zhranklin see talk in #neovim irc channel, the maintainer of neovim justinmk also do not think we should add the g:var into colorsheme, |
terminal should has its's own colorscheme, it will be better for other apps, most of the terminal has config file for user to set the colors,, such gnome-terminal , st, lilyterm and so on,BTW, I am using termite, it is also very easy to set the color. |
@wsdjeg I would be agree with you now. I think it will be better if neovim use the foreground and background colors which are from the terminal in its embedded terminal, but not from the colorscheme's. Otherwise, some terminal-colored texts can't be seen clearly with vim-theme-colored background. |
@zhranklin I do not think neovim terminal can detect the foreground and background colors of other terminals. you should set yourself,because each terminal has its own config file, for example if you have gnome-terminal and termite in your PATH, you can open these two terminal, the should has different colors, it is due to all the terminal has same init file like |
Neovim doesn't have to know about the setting of foreground and background. Just show the plain text without color, then the terminal will make it in default foreground and background. |
it is feature, please read |
@wsdjeg I know what you mean. So I think it easy for neovim to just show texts in terminal's foreground and background, which isn't what we see in neovim's embedded terminal. |
Did you try |
@zhranklin ok, I see, in terminal buffer, if you do not set these g:var, all text has same colors as the origin terminal except the bg and fg. |
I will try these, thanks! 2016年5月21日 09:48,Wang Shidong notifications@github.com写道: @zhranklinhttps://github.com/zhranklin ok, I see, in terminal buffer, if you do not set these g:var, all text has same colors as the origin terminal except the bg and fg. — |
With the hopes of getting this merged, could it not be hidden behind a feature flag? That way it's completely opt-in and it wont mess with anyone's neovim terminal unnecessarily.
|
Yes, I agree.
is a good idea |
Merged |
Neovim has support for embedded terminals. However, the colors do not inherit from the parent shell settings, and end up looking funky. This commit adds 16 color support for Neovim's terminal.
See: neovim/neovim#2897 (comment)