The what now?

Yup. ded. It's a nice editor, and it's comfortable to use under PWB/UNIX. It's in my setup of that system on the PDP-11/23+, and since I made a few changes, I thought I should describe the important ones here.

The editor was designed and implemented by Richard Bornat, who wanted something more suitable for writers than ed(1), and had the idea that he could make something that let him edit "a picture of the text" instead of the text itself. Since there was nothing to model it on, it's got a lot of interesting features. The above referenced paper is a good read, as is the man page. Note that I haven't updated the man page with the changes described below.

The version of ded I'm using was one I found in the TUHS archive, in this tape image.

ded was hard-coded for the terminals that were in use at QMC when it was made, and the choice of terminal type is made at compile time. I've added basic support for ANSI terminals, and use the result in xterms. The basic set of arrow keys, page up and down, home and end, all work as expected. I've changed most of the rest. The emacs control keys a, e, f, b, p, n, and k do the expected, and ctrl-w deletes backward to the beginning of the line. I've let ctrl-z go to and clear the command line, and ctrl-x hop back and forth between the text and command line, Ctrl-c is the "special" key, so ctrl-c ctrl-p goes to the top of the screen, etc. Ctrl-v is the "control" command, which inserts the special character that controls line breaks and literal entry of control keys, and ctrl-r repeats the current command in the command line. During global text replacement, space bar means accept and continue, rubout means reject and continue, and y and n mean accept and reject, respectively, and stop. As for the rest, read the source. :)

(The source is in my PWB/UNIX snapshot image.)