summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2016-12-14 00:34:53 +0000
committerMaxime Coste <mawww@kakoune.org>2016-12-14 00:34:53 +0000
commit85a534fb8a6cb0c6d83850f6bc0bac7630828170 (patch)
treef833acbe1514e3858ede2619be8eb9cb67bf2abe /src
parent735b1e1dc51d5d565ec4dd5aca88d013ee5c88c8 (diff)
Support inserting esc characters through <c-v>
As requested in #960
Diffstat (limited to 'src')
-rw-r--r--src/keys.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/keys.cc b/src/keys.cc
index 11b2ad93..c9031732 100644
--- a/src/keys.cc
+++ b/src/keys.cc
@@ -27,6 +27,8 @@ Optional<Codepoint> Key::codepoint() const
return '\n';
if (*this == Key::Tab)
return '\t';
+ if (*this == Key::Escape)
+ return 0x1B;
if (modifiers == Modifiers::None and key > 27 and
(key < 0xD800 or key > 0xDFFF)) // avoid surrogates
return key;