<<< Date Index >>>     <<< Thread Index >>>

Re: [Mutt] #2952: <BackSpace> should use terminal settings



#2952: <BackSpace> should use terminal settings

Comment (by Vincent Lefevre):

 {{{
 On 2007-09-11 10:20:16 -0500, Kyle Wheeler wrote:
 > On Tuesday, September 11 at 07:48 AM, quoth Mutt:
 >> But remember that in Mutt, the backspace key is not used in the editor
 >> only, but also in the index, the pager and so on.
 >
 > So what? Should mutt not be consistent? If I have:
 >
 >     bind index <BackSpace> delete-message
 >     bind editor <BackSpace> backspace
 >
 > ...should I not expect that in both cases I am referring to the same
 key?

 Yes. If you notice that this refers to different keys, then there's
 a bug.

 >> And what if some user prefers to use the delete key as erase?
 >
 > Then good for them! They should use stty to set the erase sequence to be
 > ^[[3~.

 First, the sequence sent by the delete key is not necessarily ^[[3~.
 Secondly, this is not sufficient: one also needs to bind <Delete> to
 backspace. And everything works OK.

 > <BackSpace> must be defined by behavior, not by the ink printed on
 > the key, because of course no program can know what's printed on the
 > key.

 No, that's not how the terminfo works. <BackSpace> means the backspace
 key. No more. Just like <Left> means the left key and so on. If you
 want some kind of key aliases based on tty settings, e.g. <tty:erase>,
 <tty:kill> and so on, this could be a new feature in Mutt. But that
 should be more probably an addition to the curses library.
 }}}

-- 
Ticket URL: <http://dev.mutt.org/trac/ticket/2952#comment:>