summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2026-11-16 02:17:20 +0000
committertv <tv@krebsco.de>2026-11-16 04:14:05 +0100
commit46b7e0bf69817975273dd8d3c5dfb3eb8f951c6c (patch)
tree16492aaed9f758b6c40bbd5b892dd93b1106def6
parent03046ee6c7279da313e2e156ced4c350488be5ee (diff)
scan: return ESC [ alone as \ESC[
Alt-[ sends ESC [ and nothing else. scan returned that as ScanKey "\ESC", dropping the [. Now it is ScanKey "\ESC[", like ESC followed by any other character.
-rw-r--r--src/Scanner.hs1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/Scanner.hs b/src/Scanner.hs
index 3383920..2f89a75 100644
--- a/src/Scanner.hs
+++ b/src/Scanner.hs
@@ -67,7 +67,6 @@ scanCS h = do
inters <- zeroOrMore h intermediateByte params
s <- reverse <$> zeroOrOne h finalByte inters
case s of
- "\ESC[" -> return $ ScanKey "\ESC" -- TODO move this to scanESC
"\ESC[M" -> scanX10MousePayload h
'\ESC' : '[' : '<' : payload | Just m <- sgrMouse payload -> return m
_ -> return $ ScanKey s