From owner-freebsd-hackers Tue Mar 25 02:22:58 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id CAA03398 for hackers-outgoing; Tue, 25 Mar 1997 02:22:58 -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 CAA03391 for ; Tue, 25 Mar 1997 02:22:51 -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 KAA22793 for ; Tue, 25 Mar 1997 10:22:33 GMT Received: (from brian@localhost) by shift.lan.awfulhak.org (8.8.5/8.8.5) id KAA28724; Tue, 25 Mar 1997 10:21:57 GMT Date: Tue, 25 Mar 1997 10:21:57 GMT Message-Id: <199703251021.KAA28724@shift.lan.awfulhak.org> Mime-Version: 1.0 X-Newsreader: knews 0.9.8 Reply-To: brian@awfulhak.demon.co.uk, brian@utell.co.uk Organization: Awfulhak Ltd. References: <5h2c01$4i2@reader.seed.net.tw> <5h6e83$1mk@ui-gate.utell.co.uk> From: brian@shift.lan.awfulhak.org (Brian Somers) Subject: Re: Backspace = ^H Newsgroups: comp.unix.bsd.freebsd.misc Cc: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=us-ascii Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk In article , uhclem@nemesis.lonestar.org (Frank Durda IV) writes: > Brian Somers (brian@shift.lan.awfulhak.org) wrote: >: What's the argument for BS=^h ? > >: Surely everyone agrees that since the dawn of time, dumb terminals >: have sent ^? for the BS key. > > Only if you bought them from DEC after 1979, circa VT100. > > I've got (or had) a Beehive, ADM-3, Teleray 1060, Teleray 11M, ACT-V, > a genuine DEC VT50, DEC VT52, DEC LA36 (DECwriter II), DEC LA120 > (DECwriter III), a GE Terminet KSR printer, Radio Shack DT-1, and a > Wyse 75 (aka DT-100) AND ALL of these produce 0x08 when you hit the > backspace key, just like the Teletype ASR33/35/37s all did, > the original DUMB terminals. So did the Singer terminals and a dozen > brands long forgotten. Few, if any, had an option for changing what > code the backspace key produced away from 0x08. > > Even Hayes AT-compatible modems recognize 0x08 as a backspace by default, > not ^?. > > Sending ^? for as a substitute for backspace came along much later in > isolated equipment and as such is incompatible. > > That's why in the ASCII chart 0x08 is called BACKSPACE. :-) > > Frank Durda IV |"The Knights who say "LETNi" > or uhclem%nemesis@rwsystr.nkn.net | demand... A SEGMENT REGISTER!!!" > |"A what?" > or ...letni!rwsys!nemesis!uhclem |"LETNi! LETNi! LETNi!" - 1983 > I didn't realize this (any dumb terminals I've seen have been vt100, vt200 and vt220s, and looking in /etc/termcap (on 2.2) we've got 19 occurences of ^h and 1 of ^? :( Still, I prefer the ^? idea, mainly for emacs reasons (are there *any* other reasons?), but it's a pain in the ass getting syscons & X to work like this on every machine. The interresting "inconsistency" here is that the default erase character is ^? and the default keyboard maps send ^? from the DEL key - implying that it's "normal" to press DEL to rubout :( Then, to compound matters, the default .profile comes with an stty erase ^h (implying that someone decided it wasn't normal after all but didn't want to disturb the status-quo too much) ! I think we should have no stty in any .profile, and either of the following: * The Backspace key sending ^? and a default stty erase char of ^? * The Backspace key sending ^h and a default stty erase char of ^h The DEL key would send whatever the Backspace key doesn't. (I'd prefer BS=^?, DEL=^h) Anything that deviates from the "default" needs to be stty'd in a .profile somewhere. -- Brian Don't _EVER_ lose your sense of humour !