Visual Studio Code 中是否有快速更改选项卡功能? [英] Is there a quick change tabs function in Visual Studio Code?

查看:33
本文介绍了Visual Studio Code 中是否有快速更改选项卡功能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当前为我提供下拉选项以选择哪个选项卡的功能太烦人了.是否有可能将其删除,以便选项卡可以像在某些现代网络浏览器中一样工作.

The current function of giving me a dropdown option of which tab to choose is just so annoying. Is there a possibility to remove it so the tabs would work like in some modern web browser.

推荐答案

默认情况下,Visual Studio Code 中的 Ctrl+Tab 按照最近使用的顺序循环切换选项卡.这很令人困惑,因为它取决于隐藏状态.

By default, Ctrl+Tab in Visual Studio Code cycles through tabs in order of most recently used. This is confusing because it depends on hidden state.

Web 浏览器按可见顺序循环浏览选项卡.这更直观.

Web browsers cycle through tabs in visible order. This is much more intuitive.

要在 Visual Studio Code 中实现这一点,您必须编辑 keybindings.json.使用带有 CTRL+SHIFT+P 的命令面板,输入首选项:打开键盘快捷键 (JSON)",然后按 Enter.

To achieve this in Visual Studio Code, you have to edit keybindings.json. Use the Command Palette with CTRL+SHIFT+P, enter "Preferences: Open Keyboard Shortcuts (JSON)", and hit Enter.

然后在文件末尾添加:

[
    // ...
    {
        "key": "ctrl+tab",
        "command": "workbench.action.nextEditor"
    },
    {
        "key": "ctrl+shift+tab",
        "command": "workbench.action.previousEditor"
    }
]

或者,仅循环浏览当前窗口/拆分视图的选项卡,您可以使用:

Alternatively, to only cycle through tabs of the current window/split view, you can use:

[
    {
        "key": "ctrl+tab",
        "command": "workbench.action.nextEditorInGroup"
    },
    {
        "key": "ctrl+shift+tab",
        "command": "workbench.action.previousEditorInGroup"
    }
]

<小时>

或者,您可以使用 Ctrl+PageDown (Windows) 或 Cmd+Option+(Mac).


Alternatively, you can use Ctrl+PageDown (Windows) or Cmd+Option+Right (Mac).

这篇关于Visual Studio Code 中是否有快速更改选项卡功能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆