After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 754521 - COLORTERM=truecolor
COLORTERM=truecolor
Status: RESOLVED FIXED
Product: vte
Classification: Core
Component: general
git master
Other All
: Normal minor
: vte-0-44
Assigned To: VTE Maintainers
VTE Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-09-03 13:16 UTC by Egmont Koblinger
Modified: 2017-02-20 13:24 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Egmont Koblinger 2015-09-03 13:16:02 UTC
Now that we finally got rid of COLORTERM, is it time to bring it back?

Slang-2.3.1 will check for this to figure out if the terminal supports true colors – due to terminfo not being able to provide this info.

http://lists.jedsoft.org/lists/slang-users/2015/0000020.html
Comment 1 Christian Persch 2015-09-03 17:25:17 UTC
I guess they don't want to use VTE_VERSION to detect this?

I'm ok-ish with adding this back, so go ahead if you want :-) (Let's put it in the same place where we set TERM.)

(BTW:

   ct = getenv ("COLORTERM");

   if (ct != NULL)
     {
        /* Allow easy mechanism to override inadequate termcap/terminfo files. */
        SLtt_Use_Ansi_Colors = 1;
#if SLTT_HAS_TRUECOLOR_SUPPORT
        if ((0 == strcmp(ct, "truecolor")) || (0 == strcmp(ct, "24bit")))
          Has_True_Color = 1;
#endif
     }

Since they're now using COLORTERM to get info about terminal features not available from terminfo, it's a bit disappointing they don't allow forward-compatibility with future extensions, e.g. by using a whatever-separated list of tokens, instead of just strcmp'ing the *whole* string for an exact match.)
Comment 2 Egmont Koblinger 2015-09-04 19:46:12 UTC
(In reply to Christian Persch from comment #1)

> I guess they don't want to use VTE_VERSION to detect this?

I think it's kind of a reasonable decision. Quite a few terminals already support true colors; it's a better approach for the terminal (or other settings) to advertise it than trying to maintain and recognize all those terminals in every library or app that goes for truecolor support.

> Since they're now using COLORTERM to get info about terminal features not
> available from terminfo, it's a bit disappointing they don't allow
> forward-compatibility with future extensions, e.g. by using a
> whatever-separated list of tokens, instead of just strcmp'ing the *whole*
> string for an exact match.)

On one hand I agree with this; on the other hand can you imagine anywhere further than true color support in the foreseeable future? Anyway, I'll share your idea with Slang's author and let's see what he does.
Comment 3 Christian Persch 2015-09-26 18:13:06 UTC
(In reply to Egmont Koblinger from comment #2)
> On one hand I agree with this; on the other hand can you imagine anywhere
> further than true color support in the foreseeable future? Anyway, I'll
> share your idea with Slang's author and let's see what he does.

I don't have a usecase now, but it's always best to future proof, IMO. Anyway, what was their reply?
Comment 4 Egmont Koblinger 2015-09-27 16:22:01 UTC
No response. (See the link above.) Maybe I should've asked it in a standalone mail :)
Comment 5 Christian Persch 2016-02-13 12:35:45 UTC
Alright.
Comment 6 Egmont Koblinger 2016-10-31 23:28:50 UTC
Just for the record:

slang-2.3.1 is out now.

I've filed this feature request for konsole and iterm2 too:

https://bugs.kde.org/show_bug.cgi?id=371919
https://gitlab.com/gnachman/iterm2/issues/5294
Comment 7 Egmont Koblinger 2017-02-19 22:23:07 UTC
FYI: emacs just integrated truecolor support; they went for introducing a new terminfo capability. It's indeed a nicer approach than $COLORTERM, although would require ncurses actually shipping such terminfo descriptions (which I find unlikely to happen, but let's hope).

http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=e463e57
Comment 8 Egmont Koblinger 2017-02-20 13:24:14 UTC
Cont'd in bug 778958.