From nobody@FreeBSD.org  Wed Nov 23 13:50:33 2011
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id D24BC106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 23 Nov 2011 13:50:33 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id C2F1C8FC17
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 23 Nov 2011 13:50:33 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id pANDoXmu081837
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 23 Nov 2011 13:50:33 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id pANDoXhN081836;
	Wed, 23 Nov 2011 13:50:33 GMT
	(envelope-from nobody)
Message-Id: <201111231350.pANDoXhN081836@red.freebsd.org>
Date: Wed, 23 Nov 2011 13:50:33 GMT
From: Stefan Bethke <stb@lassitu.de>
To: freebsd-gnats-submit@FreeBSD.org
Subject: termcap is missing kB entry for xterm
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         162787
>Category:       conf
>Synopsis:       termcap is missing kB entry for xterm
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    eadler
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov 23 14:00:20 UTC 2011
>Closed-Date:    Mon Nov 19 04:10:21 UTC 2012
>Last-Modified:  Mon Nov 19 04:10:21 UTC 2012
>Originator:     Stefan Bethke
>Release:        FreeBSD 9.0-PRERELEASE
>Organization:
>Environment:
>Description:
Some software, notably dialog(1), can understand back-tab, which is typically bound to Shift-Tab.  syscons produces ^]]Z for Shift-Tab, like many VT100-like terminal (emulators). The plain xterm does not produce this sequence, but ^I for both Tab and Shift-Tab.

For compatibility with xterm-compatible terminal emulators, adding a kB attribute is desirable.
>How-To-Repeat:
On the console,
$ dialog --menu foo 20 60 12 a one b two c three
Hitting Shift-Tab exits from dialog.

>Fix:
Add :kB=\E[Z: to the xterm-basic entry:

Index: share/termcap/termcap.src
===================================================================
--- share/termcap/termcap.src	(revision 227665)
+++ share/termcap/termcap.src	(working copy)
@@ -2825,7 +2825,7 @@
 	:as=\E(0:bl=^G:cd=\E[J:ce=\E[K:cl=\E[H\E[2J:\
 	:cm=\E[%i%d;%dH:cs=\E[%i%d;%dr:ct=\E[3g:dc=\E[P:dl=\E[M:\
 	:ei=\E[4l:ho=\E[H:im=\E[4h:is=\E[!p\E[?3;4l\E[4l\E>:\
-	:kD=\E[3~:kb=^H:ke=\E[?1l\E>:ks=\E[?1h\E=:le=^H:md=\E[1m:\
+	:kD=\E[3~:kb=^H:ke=\E[?1l\E>:ks=\E[?1h\E=:kB=\E[Z:le=^H:md=\E[1m:\
 	:me=\E[m:ml=\El:mr=\E[7m:mu=\Em:nd=\E[C:op=\E[39;49m:\
 	:rc=\E8:rs=\E[!p\E[?3;4l\E[4l\E>:sc=\E7:se=\E[27m:sf=^J:\
 	:so=\E[7m:sr=\EM:st=\EH:\


>Release-Note:
>Audit-Trail:

From: Stefan Bethke <stb@lassitu.de>
To: FreeBSD-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: conf/162787: termcap is missing kB entry for xterm
Date: Wed, 23 Nov 2011 16:35:36 +0100

 Bruca Can reports:
 > That's a much better PR than the one I submitted about the problem =
 last year: http://www.freebsd.org/cgi/query-pr.cgi?pr=3Dbin/151229 :)
 
 
 I suggest to close bin/151229 as a duplicate.
 
 
 --=20
 Stefan Bethke <stb@lassitu.de>   Fon +49 151 14070811
 

From: Garrett Wollman <wollman@hergotha.csail.mit.edu>
To: freebsd-gnats-submit@freebsd.org
Cc:  
Subject: Re: conf/162787: termcap is missing kB entry for xterm
Date: Wed, 23 Nov 2011 11:41:09 -0500 (EST)

 stb@lassitu.de writes:
 
 >Some software, notably dialog(1), can understand back-tab, which is
 >typically bound to Shift-Tab.  syscons produces ^]]Z for Shift-Tab, like
 >many VT100-like terminal (emulators). The plain xterm does not produce
 >this sequence, but ^I for both Tab and Shift-Tab.
 
 My xterm emits ESC [ Z, not TAB, just fine.
 
 xterm-275_2
 WITHOUT_WIDE_CHARS=true
 WITH_LUIT=true
 WITHOUT_256_COLOR=true
 WITHOUT_DEC_LOCATOR=true
 WITHOUT_PCRE=true
 WITHOUT_GNOME=true
 
 -GAWollman
 

From: Thomas Dickey <dickey@his.com>
To: bug-followup@FreeBSD.org, stb@lassitu.de
Cc:  
Subject: Re: conf/162787: termcap is missing kB entry for xterm
Date: Fri, 25 Nov 2011 06:40:41 -0500

 --FCuugMFkClbJLl1L
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 Content-Transfer-Encoding: quoted-printable
 
 The main reason for omitting kB is to keep termcaps within 1023 bytes.
 (some users might care, though ncurses uses a higher limit).
 
 btw, I don't see where this change was checked into svn/cvs, though the diff
 suggests that it was.
 
 --=20
 Thomas E. Dickey <dickey@invisible-island.net>
 http://invisible-island.net
 ftp://invisible-island.net
 
 --FCuugMFkClbJLl1L
 Content-Type: application/pgp-signature; name="signature.asc"
 Content-Description: Digital signature
 Content-Disposition: inline
 
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.9 (GNU/Linux)
 
 iEYEARECAAYFAk7PfrkACgkQcCNT4PfkjtvvKgCg1Fscr0v5Vk8kCUPmimT19Zz3
 mJcAnij1c5GaWkSfeJQBQpyU3oPIdr/v
 =7wce
 -----END PGP SIGNATURE-----
 
 --FCuugMFkClbJLl1L--
Responsible-Changed-From-To: freebsd-bugs->eadler 
Responsible-Changed-By: eadler 
Responsible-Changed-When: Fri Nov 2 00:35:37 UTC 2012 
Responsible-Changed-Why:  
I'll finally deal with this now 

http://www.freebsd.org/cgi/query-pr.cgi?pr=162787 
State-Changed-From-To: open->analyzed 
State-Changed-By: eadler 
State-Changed-When: Fri Nov 2 00:39:58 UTC 2012 
State-Changed-Why:  
awaiting approval or review prior to commit (no action needed from 
submitter) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=162787 
State-Changed-From-To: analyzed->patched 
State-Changed-By: eadler 
State-Changed-When: Thu Nov 15 18:34:46 UTC 2012 
State-Changed-Why:  
committed 

http://www.freebsd.org/cgi/query-pr.cgi?pr=162787 
State-Changed-From-To: patched->closed 
State-Changed-By: eadler 
State-Changed-When: Mon Nov 19 04:10:20 UTC 2012 
State-Changed-Why:  
MFCed 

http://www.freebsd.org/cgi/query-pr.cgi?pr=162787 
>Unformatted:
