Report unknown CSI r sequences

This commit is contained in:
Kovid Goyal 2017-12-06 00:31:03 +05:30
parent 01324a7ad2
commit c90223e4c8
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C
2 changed files with 7 additions and 7 deletions

View file

@ -221,11 +221,6 @@
// Soft reset
#define DECSTR 'p'
// *Select top and bottom margins*: Selects margins, defining the
// scrolling region; parameters are top and bottom line. If called
// without any arguments, whole screen is used.
#define DECSTBM 'r'
// *Horizontal position adjust*: Same as :data:`CHA`.
#define HPA '`'

View file

@ -649,8 +649,13 @@ dispatch_csi(Screen *screen, PyObject DUMP_UNUSED *dump_callback) {
CALL_CSI_HANDLER1P(save_cursor, 0, '?');
case RC:
CALL_CSI_HANDLER1P(restore_cursor, 0, '?');
case DECSTBM:
CALL_CSI_HANDLER2(screen_set_margins, 0, 0);
case 'r':
if (!start_modifier && !end_modifier) {
// DECSTBM
CALL_CSI_HANDLER2(screen_set_margins, 0, 0);
}
REPORT_ERROR("Unknown CSI r sequence with start and end modifiers: '%c' '%c'", start_modifier, end_modifier);
break;
case DECSCUSR:
CALL_CSI_HANDLER1M(screen_set_cursor, 1);
case SU: