comparison src/globals.h @ 31192:dcde141f2d1e v9.0.0930

patch 9.0.0930: cannot debug the Kitty keyboard protocol with TermDebug Commit: https://github.com/vim/vim/commit/63a2e360cca2c70ab0a85d14771d3259d4b3aafa Author: Bram Moolenaar <Bram@vim.org> Date: Wed Nov 23 20:20:18 2022 +0000 patch 9.0.0930: cannot debug the Kitty keyboard protocol with TermDebug Problem: Cannot debug the Kitty keyboard protocol with TermDebug. Solution: Add Kitty keyboard protocol support to the libvterm fork. Recognize the escape sequences that the protocol generates. Add the 'keyprotocol' option to allow the user to specify for which terminal what protocol is to be used, instead of hard-coding this. Add recognizing the kitty keyboard protocol status.
author Bram Moolenaar <Bram@vim.org>
date Wed, 23 Nov 2022 21:30:04 +0100
parents c02b74b87608
children ee50174810ac
comparison
equal deleted inserted replaced
31191:b8c6d994ce31 31192:dcde141f2d1e
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.
1378 EXTERN int seenModifyOtherKeys INIT(= FALSE); 1378 EXTERN int seenModifyOtherKeys INIT(= FALSE);
1379 1379
1380 // The state for the Kitty keyboard protocol.
1381 typedef enum {
1382 // Initially we have no clue if the protocol is on or off.
1383 KKPS_INITIAL,
1384 // Used when receiving the state and the flags are zero.
1385 KKPS_OFF,
1386 // Used when receiving the state and the flags are non-zero.
1387 KKPS_ENABLED,
1388 // Used after outputting t_KE when the state was KKPS_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 KKPS_DISABLED,
1392 // Used after outputting t_KE when the state was not KKPS_ENABLED.
1393 KKPS_AFTER_T_KE,
1394 } kkpstate_T;
1395
1396 EXTERN kkpstate_T kitty_protocol_state INIT(= KKPS_INITIAL);
1397
1380 EXTERN int no_mapping INIT(= FALSE); // currently no mapping allowed 1398 EXTERN int no_mapping INIT(= FALSE); // currently no mapping allowed
1381 EXTERN int no_zero_mapping INIT(= 0); // mapping zero not allowed 1399 EXTERN int no_zero_mapping INIT(= 0); // mapping zero not allowed
1382 EXTERN int allow_keys INIT(= FALSE); // allow key codes when no_mapping 1400 EXTERN int allow_keys INIT(= FALSE); // allow key codes when no_mapping
1383 // is set 1401 // is set
1384 EXTERN int no_reduce_keys INIT(= FALSE); // do not apply Ctrl, Shift and Alt 1402 EXTERN int no_reduce_keys INIT(= FALSE); // do not apply Ctrl, Shift and Alt