I see that in Tools -> Options -> Keyboard you can set Keyboard shortcuts for a large number of tasks. I tried searching for "Close" and these are the results, amongst a few others:
If I set File.Close to be Ctrl+W (Honestly, why doesn't Microsoft innately support such a universal shortcut is beyond me) it mostly works, however if I have both the code-behind and the Designer view open for a form, it closes both tabs. Should I be setting a different command, or am I stuck with this? It's a small inconvenience, but it really irritates me.
I don't know if it's the same in VS2010, but in VS2012 this command is called "Window.CloseDocumentWindow" and it is mapped to Ctrl+F4 by default, to mirror Alt+F4 for closing application-level windows.
I believe the Ctrl+W shortcut was first brought to Microsoft Windows by Adobe Photoshop, a carry-over from Apple OS X, where Adobe seems to have remapped all of the ⌘ command+* shortcuts to Ctrl+*. On OS X, ⌘ command+W only closes windows, but the application stays resident. One uses ⌘ command+Q to quit applications, instead. As the window is the application in Windows, Ctrl+W is kind of a misnomer, but it has gotten more popular for some applications like web browsers to support it.
Given the market dominance of MS Windows over Apple OS X for desktop operating systems, it would seem that the F4-style shortcuts are "more universal" than the W/Q ones.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With