Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 26 Mar 1997 11:54:25 GMT
From:      brian@shift.lan.awfulhak.org (Brian Somers)
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: Backspace = ^H
Message-ID:  <199703261154.LAA11351@shift.lan.awfulhak.org>
References:  <5h2c01$4i2@reader.seed.net.tw> <5h6e83$1mk@ui-gate.utell.co.uk> <E7KvDC.ILE@nemesis.lonestar.org> <5h8905$lj1@ui-gate.utell.co.uk> <87g1xkqe8d.fsf@erlenstar.demon.co.uk> <5h9m3l$1ih@gurney.zeta.org.au>

next in thread | previous in thread | raw e-mail | index | archive | help

[This message is going to comp.unix.bsd.freebsd.misc and freebsd-hackers!]

In article <5h9m3l$1ih@gurney.zeta.org.au>,
	andrew@gurney.zeta.org.au (Andrew Reilly) writes:
> In article <87g1xkqe8d.fsf@erlenstar.demon.co.uk>,
> 	Andrew Gierth <andrew@erlenstar.demon.co.uk> writes:
> 
>> From a user's point of view, and assuming a PC keyboard, there are two keys
>> to consider; the <- (backspace) key, and the "Delete" key. Normal user
>> expectations require <- to behave as a *destructive* backspace, and "Delete"
>> to be 'delete character forward' (kdch1 in terminfo-speek). This can best be
>> achieved by having <- generate DEL, having "Delete" generate an escape 
>> sequence, and defaulting to 'stty erase ^?'. (Which is what I have done on
>> my system, and have done in the past to many other Unix flavours, terminals
>> and terminal emulators.) This leaves ^h free, which keeps Emacs happy. 
>> Having "Delete" generate ^h is insane, and likely to confuse people 
>> considerably.
> 
> Yes, but which escape sequence, and how do you do that?
> 
> I've discovered that using xmodmap to make the "<-" key
> return "Delete" makes emacs happy, but Netscape and other
> Motif-style applications insist on "BackSpace".  So what's
> one to do?

I believe (now) that the correct way is to have BS as 0x08 -
conflicting with emacs.  The ASCII standard (man ascii)
says very specifically that BS=0x08 and DEL=0x7f, so unless
this is changed, we're stuck with it.

Now, assuming people want to use BS to rubout characters (I'm
sure that much is standard these days!!?!), emacs has made a bad
choice for the help binding.  Anyone that thinks that emacs
is correct (it makes more sense IMHO) will have to go to
whatever standards committee governs the ascii chart and convince
them first.  As this will not happen (anyone care to bet?),
emacs is wrong from a "standards" perspective and should bind
the help system to something like ^x^h (suggested by Terry
Lambert on freebsd-hackers@freebsd.org where this discussion
is also being flogged to death).

That said, FreeBSD's default erase character is 0x7f and roots
..profile changes it to 0x08 so that things work.  I propose
that I change this so that erase = ^h by default and there's
no stty in roots .profile.  At least this would make things
consistent - and may stiffle the frequency of this discussion
as things will work "out of the box".  I'll co-ordinate with
Jordan (the maintainer of the emacs port) a patch to change
the default help key binding to ^x^h (now that's gonna cause
some "controversial" arguments!) - assuming he agrees.

Assuming that nobody has any serious objections to me doing
this, I'll make the mods to FreeBSD-current (3.0).

Anyone that subsequently changes things so that erase = ^? to
get emacs to work with the default key bindings will almost
definitely already know what they're doing (*shrug*) and will
have the insite to do a "man ascii" before bringing this up
again - more than I can say for myself !.

-- 
Brian <brian@awfulhak.demon.co.uk> <brian@freebsd.org>
      <http://www.awfulhak.demon.co.uk>;
Don't _EVER_ lose your sense of humour !



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199703261154.LAA11351>