From 85a534fb8a6cb0c6d83850f6bc0bac7630828170 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Wed, 14 Dec 2016 00:34:53 +0000 Subject: [PATCH] Support inserting esc characters through As requested in #960 --- src/keys.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/keys.cc b/src/keys.cc index 11b2ad93e..c9031732f 100644 --- a/src/keys.cc +++ b/src/keys.cc @@ -27,6 +27,8 @@ Optional 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;