9fans archive / 2001 / 03 / 230 /    prev next

From: "Douglas A. Gwyn" <gwyn@arl...>
Subject: Re: [9fans] sam mod for delete-forward
Date: Mon, 26 Mar 2001 15:37:34 GMT

rob pike wrote:
> I'm nervous about this because rio can't do the same thing, and if you
> get in the habit in sam place you'll be sorry in rio when you kill the
> process.  I regret the different interpretations of ESC and don't want
> to make another mistake like that.

I appreciate the point.  It is a pity that the industry didn't agree on
standard uses for control keystrokes.  Actually DEL is RUBOUT, which
should be ignored since it is where the punched paper tape was
backspaced and overpunched to remove an erroneous character.  ESC is
supposed to introduce a *sequence* of characters.  Etc.  I'm not sure
why the early Unix use of DEL to generate an INTR signal was carried
into Plan 9, but frankly it seems like a poor choice.  ETX (^C) is a
semi-standard for this function, just as DEL deletes
forward in most text processors these days.

I doubt you want to go the X11-init-file route, but it might be
useful to employ *some* sort of functional key map, defaulting to
whatever you think is best.  Then sam, rio, and other apps could be
uniformly coded to test for the key corresponding to the function
Delete-Word-Backward, Delete-Char-Forward, Generate-Signal, etc.
instead of hard-wiring the functions.  I know that hard-wired
functions make it easier to use somebody else's environment, but I
don't think that trumps the desire to be able to switch among Plan 9
and other OSes without having to retrain one's fingers.

I just realized that while preparing this message under Solaris with
Netscape's Compose window, I used DEL for delete-forward several times.