aboutsummaryrefslogtreecommitdiff
path: root/tty-term.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2009-01-10 22:28:40 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2009-01-10 22:28:40 +0000
commitee0a7cda880f01771470b2902839c5d6396057c3 (patch)
tree356e4a9bd6b3e2c48c9d204d876a20ec7477b2bc /tty-term.c
parent736117e4e97a1a060777e8469c8091553a09a807 (diff)
downloadrtmux-ee0a7cda880f01771470b2902839c5d6396057c3.tar.gz
rtmux-ee0a7cda880f01771470b2902839c5d6396057c3.tar.bz2
rtmux-ee0a7cda880f01771470b2902839c5d6396057c3.zip
Restore emulation of ich with insert mode.
Diffstat (limited to 'tty-term.c')
-rw-r--r--tty-term.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/tty-term.c b/tty-term.c
index c11e7565..e903d8ce 100644
--- a/tty-term.c
+++ b/tty-term.c
@@ -1,4 +1,4 @@
-/* $Id: tty-term.c,v 1.6 2009-01-10 22:26:08 nicm Exp $ */
+/* $Id: tty-term.c,v 1.7 2009-01-10 22:28:40 nicm Exp $ */
/*
* Copyright (c) 2008 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -96,12 +96,14 @@ struct tty_term_code_entry tty_term_codes[NTTYCODE] = {
{ TTYC_RI, TTYCODE_STRING, "ri" },
{ TTYC_RMACS, TTYCODE_STRING, "rmacs" },
{ TTYC_RMCUP, TTYCODE_STRING, "rmcup" },
+ { TTYC_RMIR, TTYCODE_STRING, "rmir" },
{ TTYC_RMKX, TTYCODE_STRING, "rmkx" },
{ TTYC_SETAB, TTYCODE_STRING, "setab" },
{ TTYC_SETAF, TTYCODE_STRING, "setaf" },
{ TTYC_SGR0, TTYCODE_STRING, "sgr0" },
{ TTYC_SMACS, TTYCODE_STRING, "smacs" },
{ TTYC_SMCUP, TTYCODE_STRING, "smcup" },
+ { TTYC_SMIR, TTYCODE_STRING, "smir" },
{ TTYC_SMKX, TTYCODE_STRING, "smkx" },
{ TTYC_SMSO, TTYCODE_STRING, "smso" },
{ TTYC_SMUL, TTYCODE_STRING, "smul" },
@@ -290,8 +292,11 @@ tty_term_find(char *name, int fd, char **cause)
xasprintf(cause, "terminal does not support dl1 or dl");
goto error;
}
- if (!tty_term_has(term, TTYC_ICH1) && !tty_term_has(term, TTYC_ICH)) {
- xasprintf(cause, "terminal does not support ich1 or ich");
+ if (!tty_term_has(term, TTYC_ICH1) &&
+ !tty_term_has(term, TTYC_ICH) && (!tty_term_has(term, TTYC_SMIR) ||
+ !tty_term_has(term, TTYC_RMIR))) {
+ xasprintf(cause,
+ "terminal does not support ich1 or ich or smir and rmir");
goto error;
}
if (!tty_term_has(term, TTYC_DCH1) && !tty_term_has(term, TTYC_DCH)) {