From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: miha--- via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#51297: 28.0.60; [PATCH] Update termcap/terminfo to indicate 16-color support Date: Wed, 20 Oct 2021 10:29:27 +0200 Message-ID: <87y26om74o.fsf@miha-pc> References: <5317d810-ac3c-23e3-e017-a057406ec6b8@gmail.com> Reply-To: miha@kamnitnik.top Mime-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26258"; mail-complaints-to="usenet@ciao.gmane.io" To: Jim Porter , 51297@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Oct 20 10:27:17 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1md6wO-0006cv-Il for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 20 Oct 2021 10:27:17 +0200 Original-Received: from localhost ([::1]:33982 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1md6wL-0001zz-H1 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 20 Oct 2021 04:27:13 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45030) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1md6vD-0001CC-7o for bug-gnu-emacs@gnu.org; Wed, 20 Oct 2021 04:26:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:41099) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1md6vC-0007Sa-TL for bug-gnu-emacs@gnu.org; Wed, 20 Oct 2021 04:26:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1md6vC-0007Od-QO for bug-gnu-emacs@gnu.org; Wed, 20 Oct 2021 04:26:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: miha@kamnitnik.top Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 20 Oct 2021 08:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51297 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 51297-submit@debbugs.gnu.org id=B51297.163471834128394 (code B ref 51297); Wed, 20 Oct 2021 08:26:02 +0000 Original-Received: (at 51297) by debbugs.gnu.org; 20 Oct 2021 08:25:41 +0000 Original-Received: from localhost ([127.0.0.1]:52644 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1md6uq-0007Nt-Of for submit@debbugs.gnu.org; Wed, 20 Oct 2021 04:25:41 -0400 Original-Received: from kamnitnik.top ([209.250.245.214]:38368) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1md6uo-0007Nl-Vy for 51297@debbugs.gnu.org; Wed, 20 Oct 2021 04:25:39 -0400 Original-Received: from localhost (BSN-77-156-43.static.siol.net [193.77.156.43]) by kamnitnik.top (Postfix) with ESMTPSA id D7E129C707; Wed, 20 Oct 2021 08:25:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kamnitnik.top; s=mail; t=1634718338; bh=Kmf2UdlInza8uvDkhIEVyI6gVAtMhVVYvTbA/fmjHi0=; h=From:To:Subject:In-Reply-To:References:Date:From; b=bM+TEOlDcNbAR55Q+CXrnqsYdLN409KL4zOPvuABPhCn5oN0WIYShpZtjDeLq+99C eYGUwNoMZhgCLFYKrEzXGhTOvjG6M7rnJPo64Jqe6qKtY+sK8/YM+UMbf+7xZztwXi /uSPPdMTxWJjDaaJjCYzgsaGIAev2KqKy7D4HQMlMB+5qV/diVkW1s9GKL+T+bQTX8 DRh2Lnkp61kdiMG1zjkpjcQYzD5W8c14D/N4Gp7oDDYH2uP/nby+ZjoM6GGgklJI+B /37bUGxFbHRKXiIN41/Q//dD5vnHQbV3ikV+rKtbP8EKEbaO2Y9YIuW7RoRoxZRLCs WVWTAQf4Qb6Yw== In-Reply-To: <5317d810-ac3c-23e3-e017-a057406ec6b8@gmail.com> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:217641 Archived-At: --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Jim Porter writes: > In bug#50179, I added support for bright ANSI colors, but neglected to=20 > update the termcap/terminfo settings to indicate this. Attached is a=20 > patch to do so. Note that it doesn't need to be merged into Emacs 29,=20 > since bug#50806 already fixed this when adding 256/24-bit color support. > - colors#8, > + colors#16, True, we now do support 16 colors, but the setab and setaf capnames have to be adjusted as well. For setaf, for example, the first 8 colors are specified with sequences \e[30m - \e[37m, and the next 8 colors are specified with sequences \e[90m - \e[97m. There is a "gap". See the attached patch, which adjusts setab and setaf. > @@ -1584,7 +1584,7 @@ term-termcap-format > :so=3D\\E[7m:se=3D\\E[m:us=3D\\E[4m:ue=3D\\E[m:md=3D\\E[1m:mr=3D\\E[7m:m= e=3D\\E[m\ > :UP=3D\\E[%%dA:DO=3D\\E[%%dB:LE=3D\\E[%%dD:RI=3D\\E[%%dC\ > :kl=3D\\EOD:kd=3D\\EOB:kr=3D\\EOC:ku=3D\\EOA:kN=3D\\E[6~:kP=3D\\E[5~:@7= =3D\\E[4~:kh=3D\\E[1~\ > -:mk=3D\\E[8m:cb=3D\\E[1K:op=3D\\E[39;49m:Co#8:pa#64:AB=3D\\E[4%%dm:AF=3D= \\E[3%%dm:cr=3D^M\ > +:mk=3D\\E[8m:cb=3D\\E[1K:op=3D\\E[39;49m:Co#16:pa#64:AB=3D\\E[4%%dm:AF= =3D\\E[3%%dm:cr=3D^M\ > :bl=3D^G:do=3D^J:le=3D^H:ta=3D^I:se=3D\\E[27m:ue=3D\\E[24m\ > :kb=3D^?:kD=3D^[[3~:sc=3D\\E7:rc=3D\\E8:r1=3D\\Ec:" > ;; : -undefine ic As for termcap, I don't think there is a way to specify this gap. I think it's best to just leave this unchanged. In bug#50806, I did adjust the number of colors in termcap, but I could do it because I added a way to specify colors without the gap (with \e[38;2;0m - \e[38;2;15m for setaf). In conclusion, I think we should update the terminfo, changing colors, setab and setaf, and leave term.el unchanged. Patch attached. --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-Update-terminfo-to-indicate-16-color-support.patch Content-Transfer-Encoding: quoted-printable From=20158e84e403017d2bfc73d9dabeb44bb3ba48f4dc Mon Sep 17 00:00:00 2001 From: =3D?UTF-8?q?Miha=3D20Rihtar=3DC5=3DA1i=3DC4=3D8D?=3D Date: Wed, 20 Oct 2021 10:24:19 +0200 Subject: [PATCH] Update terminfo to indicate 16-color support. * etc/e/eterm-color.ti: Indicate 16-color support. Do not merge to master. =2D-- etc/e/eterm-color | Bin 1179 -> 1227 bytes etc/e/eterm-color.ti | 6 +++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/etc/e/eterm-color b/etc/e/eterm-color index bd3f5003ae620db49b89a2c1387b0ba1c836f4f1..06e8dc01ed6c136c3b8a32ae42e= ed81745efd1fb 100644 GIT binary patch delta 109 zcmbQud76`3iqV~c9|$uUD<^UnG74<0z0AZIxH*tnkI~0owZKrd+M-s~MzzEk#7