Keyboard shortcut for show/hide the lower pane (Er

2019-07-09 08:57发布

Is there any keyboard shortcut or alternative way to show/hide the lower pane (Error List, Output, Watch etc. tabs) in Visual Studio. I am looking for something similar to Ctrl + R in Microsoft SQL Management Studio which toggles the Results pane.

I understand I can pin/unpin, resize or move around the lower pane but it is not very convenient. I like the fact that when I am typing code, Visual Studio on-the-fly shows the any coding errors, but for that I have to keep the Errors pane pinned, but that reduces my coding window, specially when working on single-monitor systems or on laptops. If I keep it unpinned, then I have to every now and then click on the Error List tab to check.

enter image description here

3条回答
SAY GOODBYE
2楼-- · 2019-07-09 09:15

I haven't changed much from the default setup and on mine shortcuts currently exist for:

  • Ctrl+Alt+O - display the output window
  • Ctrl+-\,Ctrl+E - display Error window

They don't toggle though as far as I know.

查看更多
Emotional °昔
3楼-- · 2019-07-09 09:23

There is Hot Windows extension that provides additional commands for tool windows management.

查看更多
beautiful°
4楼-- · 2019-07-09 09:24

There is no command in VS2017 for toggle the tool window. For me, I install the macro extension, write a script for hiding all tool windows and binds a shortcut key to this macro.

Here is the steps:

1) First, you will need to install the Macros for Visual Studio

2) Then in macro explorer, Tools> Macro> Macro Explorer, add this macro:

var windows = dte.Windows;    
for (var i = 1; i <= windows.Count; i++) {
    var window = windows.Item(i);

    // Check that this is a tool window and not a document
    if (window.Document == null && window.Visible) {
        window.Activate();
        dte.ExecuteCommand("Window.Hide");
    }
}

3) Set this macro as macro command 1 in macro explorer.

4) Finally, in Tools> Options> Environment> Keyboard, assign the "Tool.MacroCommand1" to your favorite keyboard shortcut.

Peronsally, I configure Alt + * for showing/ hiding tool windows

  • Alt + `: Tool MacroCommand1 (for hide all tool window)
  • Alt + 1: View Solution explorer
  • Alt + 2: View Bookmark
  • Alt + 3: View Find results
  • Alt + 4: View Output
  • Alt + 5: View Call heirarchy
  • Alt + 6: View Task List
查看更多
登录 后发表回答