From 16f989bd0dcf1e6ff538edad92d203b0860b62ad Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Mon, 11 Feb 2013 18:27:03 +0100 Subject: immediate editing command to rubout current string param when not in string-state, is self inserting (unlike traditional TECO where it would clear your entire commandline) --- src/cmdline.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src') diff --git a/src/cmdline.cpp b/src/cmdline.cpp index a1f8e44..aabf9e5 100644 --- a/src/cmdline.cpp +++ b/src/cmdline.cpp @@ -176,6 +176,15 @@ process_edit_cmd(gchar key) *insert = '\0'; break; + case CTL_KEY('U'): + if (States::is_string()) { + while (strings[0] && strlen(strings[0]) > 0) + undo.pop(macro_pc--); + cmdline[macro_pc] = '\0'; + *insert = '\0'; + } + break; + case CTL_KEY('T'): if (States::is_string()) { const gchar *filename = last_occurrence(strings[0]); -- cgit v1.2.3