Reputation: 27107
Most people use alt+TAB to switch between applications on their desktop.
This question is about switching between two windows in Visual Studio Code.
I am used to use ctrl-e to switch between two files in PyCharm and Chrome (via plugin Quick Tab).
Now I would like to do the same in vs-code.
The short cut ctrl-e opens the change file dialog. But if I hint "enter", I stay in the same file. I would have to use the down-arrow key to change the file.
Since I can blindly switch between two files in PyCharm and Chrome with ctrl-e ENTER, I would like to do the same in vs-code. How can I configure it this way?
Upvotes: 5
Views: 3025
Reputation: 3361
I found workbench.action.showAllEditorsByMostRecentlyUsed
to be the most like JetBrains Rider / Intellij although a extra 'Down' keystroke is needed afterwards. It shows the most-recently-used editors and does not disappear when I release the shortcut chord.
Steps:
workbench.action.showAllEditorsByMostRecentlyUsed
in the search at topCtrl+e
Ctrl+e
bindings if necessaryUpvotes: 1
Reputation: 182781
In your keybindings.json:
File > Preferences > Keyboard Shortcuts. "Open Keyboard Shortcuts" (top right).
{
"key": "ctrl+e",
"command": "workbench.action.quickOpenPreviousRecentlyUsedEditorInGroup"
},
{
"key": "ctrl+tab",
"command": "-workbench.action.quickOpenPreviousRecentlyUsedEditorInGroup"
},
See this issue: https://github.com/Microsoft/vscode/issues/6923
Upvotes: 5