Created
July 17, 2014 20:22
-
-
Save hparra/67df971dfce5742a72e5 to your computer and use it in GitHub Desktop.
User KeyBindings to reset emacs-style tabs when using Sublemacs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ "keys": ["tab"], "command": "insert_best_completion", "args": {"default": "\t", "exact": true} }, | |
{ "keys": ["tab"], "command": "insert_best_completion", "args": {"default": "\t", "exact": false}, | |
"context": | |
[ | |
{ "key": "setting.tab_completion", "operator": "equal", "operand": true } | |
] | |
}, | |
{ "keys": ["tab"], "command": "replace_completion_with_next_completion", "context": | |
[ | |
{ "key": "last_command", "operator": "equal", "operand": "insert_best_completion" }, | |
{ "key": "setting.tab_completion", "operator": "equal", "operand": true } | |
] | |
}, | |
{ "keys": ["tab"], "command": "reindent", "context": | |
[ | |
{ "key": "setting.auto_indent", "operator": "equal", "operand": true }, | |
{ "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, | |
{ "key": "preceding_text", "operator": "regex_match", "operand": "^$", "match_all": true }, | |
{ "key": "following_text", "operator": "regex_match", "operand": "^$", "match_all": true } | |
] | |
}, | |
{ "keys": ["tab"], "command": "indent", "context": | |
[ | |
{ "key": "text", "operator": "regex_contains", "operand": "\n" } | |
] | |
}, | |
{ "keys": ["tab"], "command": "next_field", "context": | |
[ | |
{ "key": "has_next_field", "operator": "equal", "operand": true } | |
] | |
}, | |
{ "keys": ["tab"], "command": "commit_completion", "context": | |
[ | |
{ "key": "auto_complete_visible" }, | |
{ "key": "setting.auto_complete_commit_on_tab" } | |
] | |
}, | |
{ "keys": ["shift+tab"], "command": "insert", "args": {"characters": "\t"} }, | |
{ "keys": ["shift+tab"], "command": "unindent", "context": | |
[ | |
{ "key": "setting.shift_tab_unindent", "operator": "equal", "operand": true } | |
] | |
}, | |
{ "keys": ["shift+tab"], "command": "unindent", "context": | |
[ | |
{ "key": "preceding_text", "operator": "regex_match", "operand": "^[\t ]*" } | |
] | |
}, | |
{ "keys": ["shift+tab"], "command": "unindent", "context": | |
[ | |
{ "key": "text", "operator": "regex_contains", "operand": "\n" } | |
] | |
}, | |
{ "keys": ["shift+tab"], "command": "prev_field", "context": | |
[ | |
{ "key": "has_prev_field", "operator": "equal", "operand": true } | |
] | |
} | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment