unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Kaushal Modi <kaushal.modi@gmail.com>
To: "Rami Ylimäki" <rami.ylimaki@vincit.com>
Cc: Emacs developers <emacs-devel@gnu.org>,
	Tino Calancha <tino.calancha@gmail.com>
Subject: Re: Black and white emacs -nw (WAS: Re: [PATCH v3 0/4] Support 24-bit terminal colors.)
Date: Sun, 19 Feb 2017 15:21:31 +0000	[thread overview]
Message-ID: <CAFyQvY3CtJt5nG-4GenctCWZp-5W0cKg-AGwqSa5seUPFRV-ww@mail.gmail.com> (raw)
In-Reply-To: <CAHmfpf_aMGfkt8YZi5__ndJP-FJ8eOK-Y_SFWkALL-RWZMJdGQ@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2207 bytes --]

On Sun, Feb 19, 2017 at 7:43 AM Rami Ylimäki <rami.ylimaki@vincit.com>
wrote:

>
> XTerm supports the direct color mode escape sequences, but approximates
> colors. See
> https://gist.github.com/XVilka/8346728#parsing-ansi-colour-sequences-but-approximating-them-to-256-palette
> and https://gist.github.com/XVilka/8346728#now-supporting-truecolour for
> details.
>
> Note that if you want to use XTerm, then using TERM=xterm-256color with
> Emacs is enough, because 24-bit colors are approximated anyway.
>

Thanks for that explanation; it helps understand why the colors don't
exactly look as in 24-bit mode. But that is much better than 256 colors! :)


> I did not do a full bootstrap. But it still seems to work in uxterm in
> tmux configured for 24-bits.
> But it doesn't work directly in an xterm terminal.
>
> What debug information can I provide from the direct xterm session or
> xterm+tmux session?
>
>
> I haven't used tmux before, but I was able to make Emacs work in direct
> color mode with following steps:
>

Wow! I cannot thank you enough! I really appreciate the effort you went
through to help me get this working.


> * Use a terminal that supports 24-bit colors (gnome-terminal).
>

Thanks. I will try that. But for now, with your fixed terminfo with Tc, it
works great in xterm too.


> * Compile tmux from https://github.com/tmux/tmux.git. The version
> provided with Ubuntu doesn't support Tc-flag.
>



> * Use following terminfo source (add the Tc-flag and use semicolon
> separators for tmux):
>
> $ cat terminfo-24bit.src
>
> # Use semicolon separators.
> xterm-24bits|xterm with 24-bit direct color mode,
>         use=xterm-256color,
>         Tc,
>
> setb24=\E[48;2;%p1%{65536}%/%d;%p1%{256}%/%{255}%&%d;%p1%{255}%&%dm,
>
> setf24=\E[38;2;%p1%{65536}%/%d;%p1%{256}%/%{255}%&%d;%p1%{255}%&%dm,
>

Thank you! This fixed the color anomaly I reported in my last email.


>  * Compile the terminfo source, run tmux, set your TERM to xterm-24bits,
> check that Tc is supported:
>
> $ tmux info | grep Tc
>  199: Tc: (flag) true
>
> * Finally run Emacs under tmux.
>

Thanks again! :)
-- 

Kaushal Modi

[-- Attachment #2: Type: text/html, Size: 5821 bytes --]

  reply	other threads:[~2017-02-19 15:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-14 15:58 [PATCH v3 0/4] Support 24-bit terminal colors Rami Ylimäki
2017-02-14 15:58 ` [PATCH v3 1/4] Remove unused terminal color pair count Rami Ylimäki
2017-02-14 15:58 ` [PATCH v3 2/4] Support 24-bit terminal colors Rami Ylimäki
2017-02-14 15:58 ` [PATCH v3 3/4] Let user turn 24-bit terminal colors on Rami Ylimäki
2017-02-14 15:58 ` [PATCH v3 4/4] Update documentation regarding 24-bit TTY colors Rami Ylimäki
2017-02-18 11:07 ` [PATCH v3 0/4] Support 24-bit terminal colors Eli Zaretskii
2017-02-19  2:22   ` Tino Calancha
2017-02-19  3:14     ` Black and white emacs -nw (WAS: Re: [PATCH v3 0/4] Support 24-bit terminal colors.) Kaushal Modi
2017-02-19  3:20       ` Kaushal Modi
2017-02-19  6:22         ` Tino Calancha
2017-02-19  7:33           ` Kaushal Modi
2017-02-19 12:43             ` Rami Ylimäki
2017-02-19 15:21               ` Kaushal Modi [this message]
2017-02-26  0:49     ` [PATCH v3 0/4] Support 24-bit terminal colors Charles Strahan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAFyQvY3CtJt5nG-4GenctCWZp-5W0cKg-AGwqSa5seUPFRV-ww@mail.gmail.com \
    --to=kaushal.modi@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=rami.ylimaki@vincit.com \
    --cc=tino.calancha@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).