summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2019-03-14 06:33:43 +0000
committernicm <nicm@openbsd.org>2019-03-14 06:33:43 +0000
commitedcf3982bfd9a14aa4d2b2cd3dbea63fd8d27508 (patch)
treebc86967973f7e3c0e526b750395d5e7d78f6ea95
parentUse non-blocking allocation in dwc2_allocx() to make (diff)
downloadwireguard-openbsd-edcf3982bfd9a14aa4d2b2cd3dbea63fd8d27508.tar.xz
wireguard-openbsd-edcf3982bfd9a14aa4d2b2cd3dbea63fd8d27508.zip
Add actual HPA (\033[`), the existing one is CHA. From Marc Reisner.
-rw-r--r--usr.bin/tmux/input.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/tmux/input.c b/usr.bin/tmux/input.c
index 66620b7691a..c64d40d4b6c 100644
--- a/usr.bin/tmux/input.c
+++ b/usr.bin/tmux/input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: input.c,v 1.147 2019/03/13 07:34:36 nicm Exp $ */
+/* $OpenBSD: input.c,v 1.148 2019/03/14 06:33:43 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -272,6 +272,7 @@ static const struct input_table_entry input_csi_table[] = {
{ 'S', "", INPUT_CSI_SU },
{ 'X', "", INPUT_CSI_ECH },
{ 'Z', "", INPUT_CSI_CBT },
+ { '`', "", INPUT_CSI_HPA },
{ 'b', "", INPUT_CSI_REP },
{ 'c', "", INPUT_CSI_DA },
{ 'c', ">", INPUT_CSI_DA_TWO },
@@ -1471,7 +1472,7 @@ input_csi_dispatch(struct input_ctx *ictx)
case INPUT_CSI_HPA:
n = input_get(ictx, 0, 1, 1);
if (n != -1)
- screen_write_cursormove(sctx, n - 1, -1, 0);
+ screen_write_cursormove(sctx, n - 1, -1, 1);
break;
case INPUT_CSI_ICH:
n = input_get(ictx, 0, 1, 1);
@@ -1540,7 +1541,7 @@ input_csi_dispatch(struct input_ctx *ictx)
case INPUT_CSI_VPA:
n = input_get(ictx, 0, 1, 1);
if (n != -1)
- screen_write_cursormove(sctx, -1, n - 1, 0);
+ screen_write_cursormove(sctx, -1, n - 1, 1);
break;
case INPUT_CSI_DECSCUSR:
n = input_get(ictx, 0, 0, 0);