|
From: sfeam (E. Merritt) <eam...@gm...> - 2011-03-20 22:19:55
|
On Sunday, March 20, 2011, Bastian Märkisch wrote: > > >On Sunday, March 20, 2011, Hans-Bernhard Bröker wrote: > >> On 18.03.2011 10:39, Bastian Märkisch wrote: > >> > > >> > Currently the builtin readline causes gnuplot to terminate > >> > if ^D (DEL) is entered on an empty line. > >> > >> That's been the default behaviour of Unix command line shells since the > >> beginning of time(). Some let you change that, some don't. > >> > >> > Would the following > >> > trivial change have any negative side effect? > >> > >> I suspect it would surprise some long-time users. > > > >Including me :-) > >That's what ^D is supposed to do. It means "End of File". > > > > Ethan > > Ok. The problem is that the builtin readline maps the DEL key > to ^D on Windows. So "DEL" terminates gnuplot there. So you > can accidentally close gnuplot while editing. From the top of the file readline.c /* NANO-EMACS line editing facility * printable characters print as themselves (insert not overwrite) * ^A moves to the beginning of the line * ^B moves back a single character * ^E moves to the end of the line * ^F moves forward a single character * ^K kills from current position to the end of line * ^P moves back through history * ^N moves forward through history * ^H and DEL delete the previous character * ^D deletes the current character, or EOF if line is empty * ^L/^R redraw line in case it gets trashed * ^U kills the entire line * ^W kills last word * LF and CR return the entire line regardless of the cursor postition * EOF with an empty line returns (char *)NULL * * all other characters are ignored */ Curiosly, the full information on ^D is not given in the help file. |