Open saneef opened 3 years ago
How did you set the TERM variable?
By the way, what themes are you using in ST and Terminus?
I'm manually setting variables in Terminus settings. Because, choosing theme from Terminus don't change the background color. It stays as a dark color always. 😢 I tried restarting like mentioned in #230; no luck.
{
"256color": false,
"theme": "default",
"unix_term": "xterm-256color",
"user_theme_colors": {
"background": "#fdf6e3",
"black": "#002831",
"blue": "#2176c7",
"brown": "#a57706",
"caret": "#9cc2c3",
"cyan": "#259286",
"foreground": "#657b83",
"green": "#6cbe6c",
"light_black": "#006488",
"light_blue": "#178ec8",
"light_brown": "#b27e28",
"light_cyan": "#00b39e",
"light_green": "#51ef84",
"light_magenta": "#e24d8e",
"light_red": "#f5163b",
"light_white": "#fcf4dc",
"magenta": "#c61c6f",
"red": "#d11c24",
"white": "#eae3cb"
}
}
Using "Default"
@randy3k Sorry, It was my mistake.
{
"256color": false, // 😔 was setting to 'false' instead of 'true'
...
}
Changing to true
fixed the problem.
Also, the background problem, I mentioned above, vanished too. I changed ST Color Scheme and Theme to another one, then set theme back to the one I use. No idea what exactly was the problem.
I could reproduce the above problem even with { "256color": true, "unix_term": "xterm-256color", ...}
. I'm using Sublime Text 3 on macOS.
subl
or subl <path>
.I suspect this is due to the difference value in TERM
variable.
subl
from terminalFrom Sublime Console:
>>> import os
>>> os.popen('echo $TERM').read()
'xterm-256color\n'
>>> import os
>>> os.popen('echo $TERM').read()
'dumb\n'
you also need to edit the setting unix_term
in the settings.
You shouldn't just inspect the $TERM
variable in the Sublime Console. Try printing the $TERM
variable in your shell.
echo $TERM
$ echo $TERM
xterm-256color
you also need to edit the setting
unix_term
in the settings.
This is how I have configured.
{
"256color": true,
"theme": "user",
"unix_term": "xterm-256color",
"user_theme_colors":
{
...
}
}
$ echo $TERM xterm-256color
Even when you launched Sublime Text directly?
Yes, in both cases it is xterm-256color
I just ran into this issue or something like it while using the Monokai Pro ST Theme, Color Scheme, and Terminus theme. I have ..."256color": true, "unix_term": "xterm-256color"...
in my Terminus user settings, and echo $TERM -> xterm-256color
.
As far as I can tell, Terminus is only applying the correct background
colour from the Terminus theme to characters which have a color != foreground
. All other characters and space in the terminal have the ST theme's background PNG texture.
I copied the Monokai Pro theme to the Terminus user settings, set my theme to user, and then set "background": "rgba(0, 0, 0, 0)"
. Now at least the background colours are consistent (though not correct).
Edit: I think that setting the RGBA value doesn't actually work, it just causes some problem and the background colour isn't parsed correctly. So instead, I've just set background
to be the same colour as the ST theme's PNG texture.
Any suggestions to get the correct background colour? Thanks.
See this bug https://github.com/SublimeTextIssues/Core/issues/817 Terminus has a workaround for web color https://github.com/randy3k/Terminus/blob/b9f68ab8f4b3476f81f55c727574393feecf7992/tools/theme_generator.py#L65
I'm seeing the same issue (I think). Also using Monokai Pro, p10k. Have this in my settings:
{
"256color": true,
"unix_term": "xterm-256color",
}
Little unclear from @randy3k last comment - is there something I can change to get the backgrounds consistent?
As a small heads-up for those that use base16-shell or similar methods to set an extended colour-range in their terminals, it seems that Terminus does not support setting colours this way.
base16-shell sets 8 base colours, sets the bright variant to the same values and adds another 6 colours as "accent" colours, which can then be picked up by e.g. vim.
Without this, the accent colours are set in the "bright" colour range between bright black and bright white, but then obviously require base16 colour schemes that are aware of that (i.e. vim themes can work with both variants).
Even setting 256color
to true
and unix_term
to xterm-256color
seems to result in default ANSI-colours being used (which are then transformed into colours from the current Sublime theme), any colour "outside" this range yields unexpected results (in my case, bold characters in the "accent" colour range get a white background instead).
So all this for nothing, I was able to rectify this issue after several tries with
{
"color_scheme_tint": "",
"class": "text_output_control"
}
This is a rule in the Theme Settings file.
I'm using Fish shell with Terminus. Within Terminus some text comes with weird background color, especially auto suggestions in fish.
Looks like it is similar to the 'Terminal panel background issue' in the README, but I'm not using DA UI.
Is there any fix for this on Terminus, or Fish shell side?