3
在Sublime中,我可以轻松设置一个更复杂的热键,让我按Enter键退出引号和括号。它在这里如下:如何设置热键将光标移出引号/括号?
// Move out of single and double quotes with `Enter`
{
"keys": ["enter"],
"command": "move",
"args": {"by": "characters", "forward": true},
"context": [
{ "key": "following_text", "operator": "regex_match", "operand": "(?:\"|').*", "match_all": true },
{ "key": "preceding_text", "operator": "regex_contains", "operand": "(?:\"|')", "match_all": true }
]
},
在VS代码中,有没有什么办法可以实现这一点?这在keybindings.json
移动光标,但它不活跃时,我也不想。谢谢。
{ "key": "enter", "command": "cursorRight",
"when": "editorTextFocus" }
嗨,罗布,我以前试过了扩展,但不在其语境意识方面工作得不错。它实际上有一个意想不到的副作用,就是作为一个制表符,而不仅仅是一个制表符,这使得不可能在以引号开头的行的开头添加新的制表符间距。 [问题5](https://github.com/albertromkes/tabout/issues/5) – cvax