DELETE/BACKSPACE key paradox on RS/6000

Irvin Lustig ijlustig at phoenix.Princeton.EDU
Thu Mar 7 03:25:24 AEST 1991


In article <1991Mar5.154645.10479 at cs.utk.edu>, jxt at cpdws1.ctd.ornl.gov (Tolliver J S) writes:
|> Hi!
|> I have an RS/6000. 
|> 
|> I claim, but am willing to be convinced otherwise, that the terminfo entry for
|> a vt100 is wrong. That it should deal with the ASCII 177 sent by the delete
|> key on a VT100 (or an emulator) "correctly" and make it behave as the "erase"
|> character without messing with stty erase in .profile or .login.
|> 
|> Is there a way to do this? How? Is it a good idea? Why or why not?
|> 
|> Many thanks,
|> Johnny Tolliver
|> Oak Ridge National Laboratory
|> jxt at ornl.gov

We had the same problem here at Princeton.  The problem is that the vt100
entry in terminfo (see /usr/lib/terminfo/dec.ti) sets the key 
kdch1=\177, which means that your delete key is interpreted as *delete*,
which is fine and dandy, except that all DEC LK201 keyboards don't have
a convenient backspace key, and the delete key on those keyboards *is* the
backspace key.  Our solution for our machine at Princeton was to create
a new terminal type vt100-p, which had everything the vt100 had, except
left out the kdch1 definition.  Then everything worked fine, but I still
have to put stty erase DEL in my .login to get things to work right.  
(Here DEL is the delete character inputted into vi.)  I now supply
all of our users with a .login that tests where they're coming from
and sets the terminal type appropriately.

Note that the presence of kdch1 causes vi to map delete to the x command.
You can verify this by typing :map in vi.

	-Irv Lustig
	Assistant Professor
	Dept. of Civil Engineering and Operations Research
	Princeton University
	irv%basie at princeton.edu



More information about the Comp.unix.aix mailing list