comparison src/globals.h @ 31241:ee50174810ac v9.0.0954

patch 9.0.0954: cannot detect whether modifyOtherKeys is enabled Commit: https://github.com/vim/vim/commit/c255b789653120979eacdf8bb8eca02487753a8e Author: Bram Moolenaar <Bram@vim.org> Date: Sat Nov 26 19:16:48 2022 +0000 patch 9.0.0954: cannot detect whether modifyOtherKeys is enabled Problem: Cannot detect whether modifyOtherKeys is enabled. Solution: Use XTQMODKEYS introduced by xterm version 377 to request the modifyOtherKeys level. Update the keycode check results.
author Bram Moolenaar <Bram@vim.org>
date Sat, 26 Nov 2022 20:30:03 +0100
parents dcde141f2d1e
children d8e7d725a666
comparison
equal deleted inserted replaced
31240:9779faf6478c 31241:ee50174810ac
1372 EXTERN int reg_executing INIT(= 0); // register being executed or zero 1372 EXTERN int reg_executing INIT(= 0); // register being executed or zero
1373 // Flag set when peeking a character and found the end of executed register 1373 // Flag set when peeking a character and found the end of executed register
1374 EXTERN int pending_end_reg_executing INIT(= 0); 1374 EXTERN int pending_end_reg_executing INIT(= 0);
1375 1375
1376 // Set when a modifyOtherKeys sequence was seen, then simplified mappings will 1376 // Set when a modifyOtherKeys sequence was seen, then simplified mappings will
1377 // no longer be used. 1377 // no longer be used. To be combined with modify_otherkeys_state.
1378 EXTERN int seenModifyOtherKeys INIT(= FALSE); 1378 EXTERN int seenModifyOtherKeys INIT(= FALSE);
1379
1380 // The state for the modifyOtherKeys level
1381 typedef enum {
1382 // Initially we have no clue if the protocol is on or off.
1383 MOKS_INITIAL,
1384 // Used when receiving the state and the level is not two.
1385 MOKS_OFF,
1386 // Used when receiving the state and the level is two.
1387 MOKS_ENABLED,
1388 // Used after outputting t_KE when the state was MOKS_ENABLED. We do not
1389 // really know if t_KE actually disabled the protocol, the following t_KI
1390 // is expected to request the state, but the response may come only later.
1391 MOKS_DISABLED,
1392 // Used after outputting t_KE when the state was not MOKS_ENABLED.
1393 MOKS_AFTER_T_KE,
1394 } mokstate_T;
1395
1396 // Set when a response to XTQMODKEYS was received. Only works for xterm
1397 // version 377 and later.
1398 EXTERN mokstate_T modify_otherkeys_state INIT(= MOKS_INITIAL);
1379 1399
1380 // The state for the Kitty keyboard protocol. 1400 // The state for the Kitty keyboard protocol.
1381 typedef enum { 1401 typedef enum {
1382 // Initially we have no clue if the protocol is on or off. 1402 // Initially we have no clue if the protocol is on or off.
1383 KKPS_INITIAL, 1403 KKPS_INITIAL,