Re: problem with backspace key in xterm-256color
- To: mutt-users@xxxxxxxx
- Subject: Re: problem with backspace key in xterm-256color
- From: Kyle Wheeler <kyle-mutt@xxxxxxxxxxxxxx>
- Date: Sun, 15 Jun 2008 16:55:18 -0500
- Comment: DomainKeys? See http://domainkeys.sourceforge.net/
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed; d=memoryhole.net; h=date :from:to:subject:message-id:references:mime-version:content-type :in-reply-to; s=default; bh=X0fqx0Q0cY1KVxCuZWpaJoL7vG0=; b=JMDE p675bvnnTcbP8KVptzH9f/GcVDll57orPr6ChAJD5umbVIfWw8Z01iqbsDx5AXnV QbLLH45lbG3+lXmPFbApn3bM+93zQhfyyWyLDTjmxBi/cW9+/QFKVIu4CGyKVHTy JeISmQ+pkzxYLgOlaiU25UQ01/LMxMB6xmi9EDI=
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=memoryhole.net; b=cz1S/LKyEYen2oGDXuEynx/CL3n/kAnJNxA/Wrs+ntCQdookOodvXO8IvpMXd7zFAToXxMqJ9Q7AfpI4KNl+nuNPN79FeM+tOm3aGhtIUQDtDau/AhnJEeK5HD1+VHUtoZnRsR1o3Fx58va7Gm0vwXPixsNVJILewBE+ENGG8nc=; h=Received:Received:Date:From:To:Subject:Message-ID:Mail-Followup-To:References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To:OpenPGP:User-Agent;
- In-reply-to: <20080615211139.GA5197@xxxxxxxxxxxxxxx>
- List-post: <mailto:mutt-users@mutt.org>
- List-unsubscribe: send mail to majordomo@mutt.org, body only "unsubscribe mutt-users"
- Mail-followup-to: mutt-users@xxxxxxxx
- Openpgp: id=CA8E235E; url=http://www.memoryhole.net/~kyle/kyle-pgp.asc; preference=signencrypt
- References: <20080615211139.GA5197@xxxxxxxxxxxxxxx>
- Sender: owner-mutt-users@xxxxxxxx
- User-agent: Mutt/1.5.18 (2008-06-02)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Sunday, June 15 at 05:11 PM, quoth Marianne Promberger:
> I'm running mutt in xfce4-terminal, which supports 256 colors, but I
> have to manually set xfce4-terminal in its preferences dialogue to
> identify as "xterm-256color" for mutt to display my 256-color colors.
> So far, so good.
Hrmf. The XFCE folks *really* ought to provide their own termcap file.
Telling your applications to pretend that it's a different terminal
(e.g. an xterm) is practically guaranteed to get you incorrect
behavior in some respect.
> Now I've noticed that with TERM=xterm-256color, mutt doesn't
> recognize the backspace key in the index or the pager (I have
> bindings for <backspace> in the .muttrc, but it says "key not
> bound"). When I set TERM to "xterm", the backspace key works fine.
Interesting... does the terminal actually alter what it emits? In
other words, when you press control-V backspace, what shows up in your
shell, and does what shows up change based on the TERM setting? If
not, is your termcap perhaps different? Try these two commands:
infocmp -1 -L xterm | grep key_backspace
infocmp -1 -L xterm-256color | grep key_backspace
They *should* be the same, but if they're not on your system, that
would explain your problem (both should print out
"key_backspace=^H,").
> In the "Advanced" tab of my xfce4-terminal settings, I have a
> setting for "backspace key generates ..." with the options -
> Auto-detect - ASCII DEL - Escape Sequence - Control-H
Uy. I wonder what "auto-detect" is actually doing.
> Only if I set this to "Control-H" does mutt recognize the backspace
> key while TERM is set to xterm-256color.
Which suggests that the auto-detection isn't actually working very
well.
> However, in that case, my editor (jed) doesn't recognize the
> backspace anymore as such,
That suggests that jed is using different terminal libraries than
mutt. I bet you can get them to agree on the backspace character by
simply ensuring that both of them use the same terminal libraries. If
memory serves, jed requires slang---since mutt can be compiled with
slang (the default is ncurses), try that.
> Googling, I just found this long thread:
> http://bugs.mutt.org/trac/ticket/2952
> but if there were practical solutions therein I failed to grasp them.
Just as there are several different bits and bobs of software that
have to agree on these conventions (such as which byte is emitted for
a backspace), there are several different ways to solve a problem when
they disagree.
~Kyle
- --
Computers are useless. They can only give you answers.
-- Pablo Picasso
-----BEGIN PGP SIGNATURE-----
Comment: Thank you for using encryption!
iEYEARECAAYFAkhVj8YACgkQBkIOoMqOI17gPACfcfHq+baKh2wI7uQ22LsNFufC
2Y0An0qi+8cQjKOSoXxOz31NJUI9wfam
=EMRO
-----END PGP SIGNATURE-----