summaryrefslogtreecommitdiffstats
path: root/input.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@openbsd.org>2013-01-15 23:18:55 +0000
committerNicholas Marriott <nicm@openbsd.org>2013-01-15 23:18:55 +0000
commit44f8e1caffce2e887682c3314ee22becc09e1d3c (patch)
treea63dd217894d16337ba0880077064fadc5e7077f /input.c
parentbc2e4a36df2023a738c433779ba8f1e08b6951fe (diff)
Implement ECH (erase character, CSI X). Reported by Christian Neukirchen.
Diffstat (limited to 'input.c')
-rw-r--r--input.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/input.c b/input.c
index 71ef3b00..7d26a661 100644
--- a/input.c
+++ b/input.c
@@ -135,6 +135,7 @@ enum input_csi_type {
INPUT_CSI_DECSTBM,
INPUT_CSI_DL,
INPUT_CSI_DSR,
+ INPUT_CSI_ECH,
INPUT_CSI_ED,
INPUT_CSI_EL,
INPUT_CSI_HPA,
@@ -167,6 +168,7 @@ const struct input_table_entry input_csi_table[] = {
{ 'L', "", INPUT_CSI_IL },
{ 'M', "", INPUT_CSI_DL },
{ 'P', "", INPUT_CSI_DCH },
+ { 'X', "", INPUT_CSI_ECH },
{ 'Z', "", INPUT_CSI_CBT },
{ 'c', "", INPUT_CSI_DA },
{ 'c', ">", INPUT_CSI_DA_TWO },
@@ -1143,6 +1145,9 @@ input_csi_dispatch(struct input_ctx *ictx)
break;
}
break;
+ case INPUT_CSI_ECH:
+ screen_write_clearcharacter(sctx, input_get(ictx, 0, 1, 1));
+ break;
case INPUT_CSI_DCH:
screen_write_deletecharacter(sctx, input_get(ictx, 0, 1, 1));
break;