bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unexpected behaviour with TERM=xterm-direct


From: Thomas Dickey
Subject: Re: Unexpected behaviour with TERM=xterm-direct
Date: Thu, 7 Mar 2019 20:00:51 -0500
User-agent: Mutt/1.5.23 (2014-03-12)

On Fri, Mar 08, 2019 at 03:37:54AM +0300, Hudd wrote:
> Hello.
> 
> I discovered xterm-direct and decided to play with it a little bit. I'd
> setup some color pairs, then ran the program, but all colours were black.
> 
> At first I thought that I'd setup colours incorrectly or maybe xterm-direct
> was just broken, but after some experimenting and digging around I realized
> that it interprets the index in color pair as an RGB value, and colours
> weren't actually black, just very dark red :).

actually not that - it uses an _index_ for the first 8 values,
and RGB for the rest.  (I could have done some other limit for
the index, but 8 is "ANSI").
 
> I wonder whether this is intentional? I think most programs assume that it

yes.

> is always an index, and not an RGB value. Should I detect TERM=xterm-direct
> and use different code to setup color pairs in such case? Though probably

yes

-- 
Thomas E. Dickey <address@hidden>
https://invisible-island.net
ftp://ftp.invisible-island.net

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]