aboutsummaryrefslogtreecommitdiff
path: root/tty.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2013-01-17 01:38:21 +0000
committerThomas Adam <thomas@xteddy.org>2013-01-17 01:38:21 +0000
commitde194016ec345db2a2a3e0b0d69080e288623597 (patch)
tree8222c9caa50815342d4ed66f2291c8b986926609 /tty.c
parent675c6b37734a622b4530d35505f897310fdb138c (diff)
parente33ba57c13139bc9ae6e92be169de6dc322e38eb (diff)
downloadrtmux-de194016ec345db2a2a3e0b0d69080e288623597.tar.gz
rtmux-de194016ec345db2a2a3e0b0d69080e288623597.tar.bz2
rtmux-de194016ec345db2a2a3e0b0d69080e288623597.zip
Merge branch 'obsd-master'
Diffstat (limited to 'tty.c')
-rw-r--r--tty.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/tty.c b/tty.c
index 9f414e11..4451e5fc 100644
--- a/tty.c
+++ b/tty.c
@@ -719,6 +719,23 @@ tty_cmd_deletecharacter(struct tty *tty, const struct tty_ctx *ctx)
}
void
+tty_cmd_clearcharacter(struct tty *tty, const struct tty_ctx *ctx)
+{
+ u_int i;
+
+ tty_reset(tty);
+
+ tty_cursor_pane(tty, ctx, ctx->ocx, ctx->ocy);
+
+ if (tty_term_has(tty->term, TTYC_ECH))
+ tty_putcode1(tty, TTYC_ECH, ctx->num);
+ else {
+ for (i = 0; i < ctx->num; i++)
+ tty_putc(tty, ' ');
+ }
+}
+
+void
tty_cmd_insertline(struct tty *tty, const struct tty_ctx *ctx)
{
if (!tty_pane_full_width(tty, ctx) ||