Arnold:
OK, that I can understand. It's ages since I
played with
readline, but I think you can preload the buffer it works on
(bash does that, no?) so ed + readline could be made to work
that way.
====
Or, if you have moved beyond the era of simulated glass
teletypes on graphics screens, you could do the editing
in the terminal (program).
It's a real shame the mux/9term way of doing things never
caught on. I suppose it is because so many people are
wedded to programs that require cursor addressing; I'm
glad I never succumbed to that.
I use ed (or its cousin qed a la Toronto) for simple stuff.
Mostly I'll use the traditional commands, but sometimes
I will, in mux/9term style, print a line with p, type
c, edit the line on the screen, pick it up and send it,
type . return.
And of course I can do that sort of thing with any program,
whether or not it is compiled with some magic library.
All this is something of a matter of taste, but I have
sometimes amazed (in a good way) my colleagues with it.
Norman Wilson
Toronto ON