[core] undo XTMODKEYS coming out of alternate screen

pull/2320/head
nick black 3 years ago committed by nick black
parent 7f36bdaba0
commit 5ce1a11bce

@ -341,6 +341,11 @@ init_terminfo_esc(tinfo* ti, const char* name, escape_e idx,
// supported. these ought follow keyboard push and precede kitty keyboard. // supported. these ought follow keyboard push and precede kitty keyboard.
#define XTMODKEYS "\x1b[>2;1m\x1b[>4;1m" #define XTMODKEYS "\x1b[>2;1m\x1b[>4;1m"
// disable key modifier options; this corresponds to a resource value of
// "-1", which cannot be set with the [>m sequence. supposedly, "[>m" by
// itself ought reset all of them, but this doesn't seem to work FIXME.
#define XTMODKEYSUNDO "\x1b[>2n\x1b[>4n"
// these queries can hopefully uniquely and unquestionably identify the // these queries can hopefully uniquely and unquestionably identify the
// terminal to which we are talking. if we already know what we're talking // terminal to which we are talking. if we already know what we're talking
// to, there's no point in sending them. // to, there's no point in sending them.
@ -393,7 +398,7 @@ init_terminfo_esc(tinfo* ti, const char* name, escape_e idx,
// written whenever we switch between standard and alternate screen, or upon // written whenever we switch between standard and alternate screen, or upon
// startup (that's an entry into a screen! presumably the standard one). // startup (that's an entry into a screen! presumably the standard one).
#define KBDENTER KKEYBOARD_PUSH XTMODKEYS KBDSUPPORT #define KBDENTER KKEYBOARD_PUSH XTMODKEYS KBDSUPPORT
#define KBDLEAVE KKEYBOARD_POP // FIXME undo XTMODKEYS! #define KBDLEAVE KKEYBOARD_POP XTMODKEYSUNDO
// enter the alternate screen (smcup). we could technically get this from // enter the alternate screen (smcup). we could technically get this from
// terminfo, but everyone who supports it supports it the same way, and we // terminfo, but everyone who supports it supports it the same way, and we

Loading…
Cancel
Save