diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2015-12-31 05:30:46 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2015-12-31 05:30:46 -0800 |
commit | 51322f6c66d153d2f008a227c5e517f6fb34dbab (patch) | |
tree | e1df325a64c7c570e72f0dec8e7f2c765fc2b7b2 /txr.1 | |
parent | de3c3e1d083d4fde847505b4626467e2cb8d4cd6 (diff) | |
download | txr-51322f6c66d153d2f008a227c5e517f6fb34dbab.tar.gz txr-51322f6c66d153d2f008a227c5e517f6fb34dbab.tar.bz2 txr-51322f6c66d153d2f008a227c5e517f6fb34dbab.zip |
linenoise: submit and stay in history.
* linenoise/linenoise.c (struct lino_state): New member
save_hist_idx.
(edit): If save_hist_idx is set, jump to that history position
and clear it. Handle ENTER in extended (Ctrl-X) mode
similarly to regular ENTER, but setting save_hist_idx.
* txr.1: Documented.
Diffstat (limited to 'txr.1')
-rw-r--r-- | txr.1 | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -38256,6 +38256,20 @@ Navigating to a history line manually using the up and down arrow keys (or Ctrl-P/Ctrl-N) has the same net effect same as locating that line using Ctrl-R search. +.NP* Submit and Stay in History + +Normally when the Enter key is used on a recalled history line, +the next time the listener is re-entered, it jumps back to the +newest history position where a new line is about to be composed. + +The alternative command sequence Ctrl-X, Enter provides a useful alternative +behavior. After the submitted line is processed, the listener doesn't jump to +the newest history position. Instead, it stays in the history, advancing +forward by one position to the successor of the submitted line. + +Ctrl-X, Enter can be used to conveniently submit a range of lines +from the history, one by one, in their original order. + .NP* Insert Previous Word The equivalent command sequences Ctrl-X, w and Ctrl-X, Ctrl-W insert |