summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@openbsd.org>2013-04-11 07:27:27 +0000
committerNicholas Marriott <nicm@openbsd.org>2013-04-11 07:27:27 +0000
commitcbee283c26968304b473e2191d2bb5f52208b58d (patch)
treedf886a0fca426b4ec2240ab990fabfbc8e41743e
parent9fcda95a6f55f017536cdf24366754a2304c1059 (diff)
Send an SGR0 after turning on modifyOtherKeys to fix Terminal.app which
treats \033[>4;1m and \033[4;1m (bold+underline). Reported & tested by otto@.
-rw-r--r--tty.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tty.c b/tty.c
index bffddac6..74988eb3 100644
--- a/tty.c
+++ b/tty.c
@@ -220,7 +220,7 @@ tty_start_tty(struct tty *tty)
tty_puts(tty, "\033[?1000l\033[?1006l\033[?1005l");
if (tty_term_has(tty->term, TTYC_XT))
- tty_puts(tty, "\033[c\033[>4;1m\033[?1004h");
+ tty_puts(tty, "\033[c\033[>4;1m\033[?1004h\033[m");
tty->cx = UINT_MAX;
tty->cy = UINT_MAX;
@@ -283,7 +283,7 @@ tty_stop_tty(struct tty *tty)
tty_raw(tty, "\033[?1000l\033[?1006l\033[?1005l");
if (tty_term_has(tty->term, TTYC_XT))
- tty_raw(tty, "\033[>4m\033[?1004l");
+ tty_raw(tty, "\033[>4m\033[?1004l\033[m");
tty_raw(tty, tty_term_string(tty->term, TTYC_RMCUP));