about summary refs log tree commit diff stats
path: root/src/kilo.c
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2021-11-13 23:27:51 -0800
committerKartik K. Agaram <vc@akkartik.com>2021-11-13 23:27:51 -0800
commit812b930815102eacd34a6f8a84ec790986a67e60 (patch)
treecfcaead082ab34093b0db1f3146634a022bf2bdb /src/kilo.c
parentd79e394a30c99950c74573baab5937ade6529d4a (diff)
downloadteliva-812b930815102eacd34a6f8a84ec790986a67e60.tar.gz
ctrl-u to clear response in go menu
Diffstat (limited to 'src/kilo.c')
-rw-r--r--src/kilo.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/kilo.c b/src/kilo.c
index edf3617..257261a 100644
--- a/src/kilo.c
+++ b/src/kilo.c
@@ -954,6 +954,9 @@ static void editorGo(lua_State* L) {
               editorRefreshBuffer();
             }
             return;
+        } else if (c == CTRL_U) {
+          query[0] = '\0';
+          qlen = 0;
         } else if (isprint(c)) {
             if (qlen < CURRENT_DEFINITION_LEN) {
                 query[qlen++] = c;