aboutsummaryrefslogtreecommitdiff
path: root/console/display.c
diff options
context:
space:
mode:
Diffstat (limited to 'console/display.c')
-rw-r--r--console/display.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/console/display.c b/console/display.c
index ac9ef92f..42920268 100644
--- a/console/display.c
+++ b/console/display.c
@@ -1195,6 +1195,12 @@ handle_esc_bracket (display_t display, char op)
break;
case 'D': /* ECMA-48 <CUB>. */
/* Cursor left: <cub>, <cub1>. */
+ if (!parse->params[0] && user->cursor.col == 0)
+ {
+ /* This implements the <bw> functionality. */
+ user->cursor.row--;
+ user->cursor.col = user->screen.width;
+ }
user->cursor.col -= (parse->params[0] ?: 1);
limit_cursor (display);
break;