Next installment: I separated the “command-as-a-function” representation into separate Command and Args columns, because I found it more readable.
This key binding (to execute the command):
{
"keys": ["ctrl+alt+shift+f4"], // <== What I am using to test the command.
"command": "key_binding_report",
"args": {
// class KeyGroup(IntEnum):
// """ Non-negative values index into ``key_name_groups``. """
// ALL = -2 # Equivalent to specifying all groups >= 0.
// KEY_SEQUENCES = -1 # Multiple-keypress sequences, e.g. ["ctrl+k", "ctrl+u"]
// LETTER_KEYS = 0 # \
// NUMBER_KEYS = 1 # \
// F_KEYS = 2 # \__ These index into ``key_name_groups``.
// SYMBOL_KEYS = 3 # /
// NAMED_KEYS = 4 # /
// KEYPAD_KEYS = 5 # /
// "key_groups": [1],
// "key_names": ["("],
// "key_names": ["enter"],
// "keypress_list": [["ctrl+p"], ["ctrl+shift+p"], ["ctrl+k", "ctrl+u"], ["ctrl+p"], ["ctrl+k", "ctrl+u"], ["alt+r"]],
// "keypress_list": [["enter"]],
// "keypress_list": [["alt+left"]],
"keypress_list": [["\""], ["'"], ["`"]],
// "packages": ["Default"],
// "packages": ["User"],
"limit_to_context": true,
// class Format(IntEnum):
// """ Formats supported by AsciiTable """
// BARE = 0
// OUTLINED = 1
// RESTRUCTUREDTEXT = 2
"format": 2,
// class FlagBits(IntFlag):
// # Output Flags
// INCLUDE_UNBOUND_KEY_COMBINATIONS = 0b00000001 # 1
// INCLUDE_UNTRANSLATED_CONTEXTS = 0b00000010 # 2
// INCLUDE_ENGLISH_CONTEXTS = 0b00000100 # 4
// ADD_PACKAGE_COLUMN = 0b00001000 # 8
// ADD_FILE_COLUMN = 0b00010000 # 16
// ADD_COMMENTS_COLUMN = 0b00100000 # 32
// # Utility Bits
// ANY_CONTEXT = 0b00000010 | 0b00000100
// NONE = 0b00000000 # 0
// ALL = 0b11111111 # 255
// ANY = 0b11111111 # 255
"flags": 31,
},
},
…produces this output (context is a .py file not inside a comment):
KeyBindingReport: Specified Key-Bindings
=========================================
Report generated: 2026-04-29 19:37:15
Key:
- S = Shift
- C = Ctrl
- A = Alt
- (Footnote ref) prefixing command means context is shown in footnote.
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
|Key|S|C|A| Command | Args | Package | File |
+===+=+=+=+=======================+======================+=========+==================================+
| ' | | | | ([1]_) insert_snippet | {'contents': "'$0'"} | Default | Default (Windows).sublime-keymap |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' | | | | ([2]_) insert | {'characters': "'"} | Python | Default.sublime-keymap |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' | | | | ([3]_) insert_snippet | {'contents': "'$0'"} | Python | Default.sublime-keymap |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' |x| | | | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' | |x| | | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' |x|x| | | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' | | |x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' |x| |x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' | |x|x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| ' |x|x|x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " | | | | ([4]_) insert_snippet | {'contents': '"$0"'} | Default | Default (Windows).sublime-keymap |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " | | | | ([5]_) insert | {'characters': '"'} | Python | Default.sublime-keymap |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " | | | | ([6]_) insert_snippet | {'contents': '"$0"'} | Python | Default.sublime-keymap |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " |x| | | | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " | |x| | | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " |x|x| | | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " | | |x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " |x| |x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " | |x|x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
| " |x|x|x| | | | |
+---+-+-+-+-----------------------+----------------------+---------+----------------------------------+
.. [1]
"context": [
{ "key": "setting.auto_match_enabled", "operator": "equal" , "operand": True }
English: Description of ContextCondition,
{ "key": "selection_empty" , "operator": "equal" , "operand": True, "match_all": True }
English: Description of ContextCondition,
{ "key": "following_text" , "operator": "regex_contains" , "operand": '^(?:\t| |\\)|]|\\}|>|$)', "match_all": True }
English: Description of ContextCondition,
{ "key": "preceding_text" , "operator": "not_regex_contains", "operand": "['a-zA-Z0-9_]$", "match_all": True }
English: Description of ContextCondition,
{ "key": "eol_selector" , "operator": "not_equal" , "operand": 'string.quoted.single - punctuation.definition.string.end', "match_all": True }
English: Description of ContextCondition
]
.. [2]
"context": [
{ "key": "setting.auto_match_enabled" }
English: Description of ContextCondition,
{ "key": "selector" , "operand": 'source.python - string.quoted.single' }
English: Description of ContextCondition,
{ "key": "selection_empty" , "match_all": True }
English: Description of ContextCondition
]
.. [3]
"context": [
{ "key": "setting.auto_match_enabled" }
English: Description of ContextCondition,
{ "key": "selector" , "operand": 'source.python - string.quoted.single' }
English: Description of ContextCondition,
{ "key": "selection_empty" , "match_all": True }
English: Description of ContextCondition,
{ "key": "preceding_text" , "operator": "regex_contains", "operand": "(?i:^|[^'\\w\\\\]|\\b[bfru]+)$", "match_all": True }
English: Description of ContextCondition,
{ "key": "following_text" , "operator": "regex_contains", "operand": '^(?:\t| |\\)|]|\\}|\\.|,|:|;|$)', "match_all": True }
English: Description of ContextCondition
]
.. [4]
"context": [
{ "key": "setting.auto_match_enabled", "operator": "equal" , "operand": True }
English: Description of ContextCondition,
{ "key": "selection_empty" , "operator": "equal" , "operand": True, "match_all": True }
English: Description of ContextCondition,
{ "key": "following_text" , "operator": "regex_contains" , "operand": '^(?:\t| |\\)|]|\\}|>|$)', "match_all": True }
English: Description of ContextCondition,
{ "key": "preceding_text" , "operator": "not_regex_contains", "operand": '["a-zA-Z0-9_]$', "match_all": True }
English: Description of ContextCondition,
{ "key": "eol_selector" , "operator": "not_equal" , "operand": 'string.quoted.double - punctuation.definition.string.end', "match_all": True }
English: Description of ContextCondition
]
.. [5]
"context": [
{ "key": "setting.auto_match_enabled" }
English: Description of ContextCondition,
{ "key": "selector" , "operand": 'source.python - string.quoted.double' }
English: Description of ContextCondition,
{ "key": "selection_empty" , "match_all": True }
English: Description of ContextCondition
]
.. [6]
"context": [
{ "key": "setting.auto_match_enabled" }
English: Description of ContextCondition,
{ "key": "selector" , "operand": 'source.python - string.quoted.double' }
English: Description of ContextCondition,
{ "key": "selection_empty" , "match_all": True }
English: Description of ContextCondition,
{ "key": "preceding_text" , "operator": "regex_contains", "operand": '(?i:^|[^"\\w\\\\]|\\b[bfru]+)$', "match_all": True }
English: Description of ContextCondition,
{ "key": "following_text" , "operator": "regex_contains", "operand": '^(?:\t| |\\)|]|\\}|\\.|,|:|;|$)', "match_all": True }
English: Description of ContextCondition
]
If the context is in an .rst file in an “open area” (not in existing text) then it also produces results for the ` (back-quote) key since the reStructuredText Package contains key bindings for it.