相关疑难解决方法(0)

如何设置热键将光标移出引号/括号?

在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 }
        ]
    },
Run Code Online (Sandbox Code Playgroud)

在VS Code中,有没有办法实现这个目标?这keybindings.json会移动光标,但是当我不想要时它也是活动的.谢谢.

    { "key": "enter",    "command": "cursorRight",
                         "when": "editorTextFocus" }
Run Code Online (Sandbox Code Playgroud)

visual-studio-code

6
推荐指数
1
解决办法
1248
查看次数

标签 统计

visual-studio-code ×1