summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/input.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2009-10-13 15:23:13 +0000
committernicm <nicm@openbsd.org>2009-10-13 15:23:13 +0000
commitd30da15def24a15fa9068db87f5d40079248f9ec (patch)
treebedcc16f06db0ea2bc76fedbf04ab7281e50dcb4 /usr.bin/tmux/input.c
parentWRKOBJDIR defaults changed (obj -> pobj) (diff)
downloadwireguard-openbsd-d30da15def24a15fa9068db87f5d40079248f9ec.tar.xz
wireguard-openbsd-d30da15def24a15fa9068db87f5d40079248f9ec.zip
Handle DECCOLM by just emulating its side-effect of clearing the screen.
Diffstat (limited to 'usr.bin/tmux/input.c')
-rw-r--r--usr.bin/tmux/input.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/usr.bin/tmux/input.c b/usr.bin/tmux/input.c
index b34cb6554eb..2a039900675 100644
--- a/usr.bin/tmux/input.c
+++ b/usr.bin/tmux/input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: input.c,v 1.16 2009/10/12 16:59:55 nicm Exp $ */
+/* $OpenBSD: input.c,v 1.17 2009/10/13 15:23:13 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -1185,6 +1185,10 @@ input_handle_sequence_sm(struct input_ctx *ictx)
screen_write_kcursormode(&ictx->ctx, 1);
log_debug("kcursor on");
break;
+ case 3: /* DECCOLM */
+ screen_write_cursormove(&ictx->ctx, 0, 0);
+ screen_write_clearscreen(&ictx->ctx);
+ break;
case 25: /* TCEM */
screen_write_cursormode(&ictx->ctx, 1);
log_debug("cursor on");
@@ -1257,6 +1261,10 @@ input_handle_sequence_rm(struct input_ctx *ictx)
screen_write_kcursormode(&ictx->ctx, 0);
log_debug("kcursor off");
break;
+ case 3: /* DECCOLM */
+ screen_write_cursormove(&ictx->ctx, 0, 0);
+ screen_write_clearscreen(&ictx->ctx);
+ break;
case 25: /* TCEM */
screen_write_cursormode(&ictx->ctx, 0);
log_debug("cursor off");