Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Mar 1997 14:56:27 +0000
From:      Brian Somers <brian@shift.lan.awfulhak.org>
To:        freebsd-hackers@freebsd.org
Cc:        Andrew Gierth <andrew@erlenstar.demon.co.uk>
Subject:   Re: Backspace = ^H
Message-ID:  <199703251456.OAA00459@shift.lan.awfulhak.org>

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

I thought this might contribute to the discussion:

------- Forwarded Message

Return-Path: andrew@erlenstar.demon.co.uk
Received: from ui-gate.utell.co.uk (ui-gate.utell.net [97.0.0.89])
	by shift.lan.awfulhak.org (8.8.5/8.8.5) with ESMTP id OAA00336
	for <brian@shift.utell.net>; Tue, 25 Mar 1997 14:30:55 GMT
Received: from relay-11.mail.demon.net (relay-11.mail.demon.net 
[194.217.242.137]) by ui-gate.utell.co.uk (8.7.6/8.7.3) with SMTP id OAA27768 
for <brian@utell.co.uk>; Tue, 25 Mar 1997 14:30:54 GMT
Received: from erlenstar.demon.co.uk ([194.222.144.22])
          by relay-10.mail.demon.net  id aa1020993; 25 Mar 97 14:19 GMT
Received: (from andrew@localhost) by erlenstar.demon.co.uk (8.8.3/8.8.3) id 
NAA24689; Tue, 25 Mar 1997 13:43:15 GMT
Newsgroups: comp.unix.bsd.freebsd.misc
Cc: brian@awfulhak.demon.co.uk, brian@utell.co.uk
Subject: Re: Backspace = ^H
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>
From: Andrew Gierth <andrew@erlenstar.demon.co.uk>
Organization: disorganised
X-Mayan-Date: Long count = 12.19.4.0.8; tzolkin = 11 Lamat; haab = 11 Cumku
X-Attribution: AG
Date: 25 Mar 1997 13:43:14 +0000
Message-ID: <87g1xkqe8d.fsf@erlenstar.demon.co.uk>
Lines: 38
X-Newsreader: Gnus v5.3/Emacs 19.34
In-Reply-To: brian@shift.lan.awfulhak.org's message of 25 Mar 1997 10:21:57 GMT
Posted-To: comp.unix.bsd.freebsd.misc

The following message is a courtesy copy of an article
that has been posted as well.

>>>>> "Brian" == Brian Somers <brian@shift.lan.awfulhak.org> writes:

 Brian> I think we should have no stty in any .profile, and either of the
 Brian> following:

 Brian> * The Backspace key sending ^? and a default stty erase char of ^?
 Brian> * The Backspace key sending ^h and a default stty erase char of ^h

 Brian> The DEL key would send whatever the Backspace key doesn't.

 Brian> (I'd prefer BS=^?, DEL=^h)

DEL=^h ?? You have *got* to be kidding.

This whole debate (which gets thrashed out regularly in comp.emacs) always
originates from a confusion between destructive and non-destructive 
backspaces. The ASCII BS character (0x08) is, from the point of view of an
output device, an instruction to move back one position, non-destructively.
The ASCII DEL (0x7f) is an artifact of paper tape; a character can be erased
from a tape by punching all the holes out, leaving a DEL, which is then 
ignored. (A vestige of this remains in some systems where DEL can be used 
for padding instead of NUL.) It's no more correct to use ^h as a destructive
backspace than any other control character, whereas DEL has always been
associated with the concept of "delete last input character".

>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.

- -- 
Andrew.

------- End of Forwarded Message






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