From 7ab462f2bdea5e1142ceb24706382145e5a9ca6a Mon Sep 17 00:00:00 2001 From: Wez Furlong Date: Fri, 9 Feb 2018 16:03:09 -0800 Subject: [PATCH] fixup alt-KEY to send escape rather than set bits --- term/src/lib.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/term/src/lib.rs b/term/src/lib.rs index aafa17bff..463a9fa1f 100644 --- a/term/src/lib.rs +++ b/term/src/lib.rs @@ -1249,7 +1249,10 @@ impl TerminalState { buf.as_str() } (Char(c), _, ALT, ..) if c <= 0xff as char => { - buf.push((c as u8 | 0x80) as char); + // TODO: add config option to select 8-bit vs. escape behavior? + //buf.push((c as u8 | 0x80) as char); + buf.push(0x1b as char); + buf.push(c); buf.as_str() } (Char(c), ..) => {