From owner-freebsd-hackers Tue Mar 25 06:57:24 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id GAA16354 for hackers-outgoing; Tue, 25 Mar 1997 06:57:24 -0800 (PST) Received: from ui-gate.utell.co.uk (ui-gate.utell.co.uk [194.200.4.253]) by freefall.freebsd.org (8.8.5/8.8.5) with ESMTP id GAA16345 for ; Tue, 25 Mar 1997 06:57:09 -0800 (PST) Received: from shift.lan.awfulhak.org (shift.utell.net [97.3.0.21]) by ui-gate.utell.co.uk (8.7.6/8.7.3) with ESMTP id OAA28308; Tue, 25 Mar 1997 14:57:03 GMT Received: from shift.lan.awfulhak.org (localhost [127.0.0.1]) by shift.lan.awfulhak.org (8.8.5/8.8.5) with ESMTP id OAA00459; Tue, 25 Mar 1997 14:56:27 GMT Message-Id: <199703251456.OAA00459@shift.lan.awfulhak.org> X-Mailer: exmh version 1.6.9 8/22/96 To: freebsd-hackers@freebsd.org cc: Andrew Gierth Subject: Re: Backspace = ^H Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Tue, 25 Mar 1997 14:56:27 +0000 From: Brian Somers Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk 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 ; 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 ; 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> <5h8905$lj1@ui-gate.utell.co.uk> From: Andrew Gierth 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 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