Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I like the close program keyboard shortcut in Mac OS X which is + Q. Nice and convenient for hand placement. In Windows however, the equivalent shortcut is Alt + F4, a little awkward.

Is there a way to change the default keyboard shortcut to Alt + Q or Ctrl + Q? I'm using Windows 7.

share|improve this question
4  
Alt+F4 closes windows, not programs. You can probably cook something up in AutoHotkey, but since Windows program commands don't always show up in menus, you might lose some commands that are executed using Ctrl/Alt+Q –  Daniel Beck Feb 25 '11 at 20:19
    
Alt+F4 will close a program for me. I just checked the 'Quit' command in Word and it's Alt+F4. Perhaps a registry edit? Not sure where to look though. –  zm15 Feb 25 '11 at 20:20
4  
If programs close when their last window is closed, then yes, Alt+F4 closes programs if you use it to close their last open window. But it's not generally a "quit program" shortcut. There's no such thing as the Keyboard Shortcuts preferences pane in OS X on Windows. Your only hope is input redirection (like I suggested) or a third-party tool. –  Daniel Beck Feb 25 '11 at 20:40
    
In my Windows, ALT+F4 also closes the whole program, even if it has more than one document/window opened. STRG+F4, however, closes a single document window. This is applicable to most, if not any, programs I use on Windows. –  Martin Apr 26 '11 at 14:07

2 Answers 2

up vote 14 down vote accepted
+25

Get AutoHotKey. Open Notepad and paste the following:

^q::Send !{F4}
return

Save it as an .ahk file, run it and try it out. If it works, stick it in your startup folder and you are good to go. The above code simply maps Ctrl + Q to Alt + F4.

If you want it to be Alt + Q, then replace the ^ with a !

If you can't get AutoHotKey, I've compiled the above script for you and uploaded it here:

http://dl.dropbox.com/u/26194020/CtrlQ.exe

Download and enjoy.

By the way - you do know that Ctrl + W closes a window in any application already, right?

share|improve this answer
4  
Ctrl+W is merely a common shortcut that has been adopted by many programs. It is not defined by Windows and doesn't work in all, or even most, applications. –  Hugh Allen Apr 28 '11 at 12:25
    
Share and enjoy. –  muntoo May 2 '11 at 0:11

To change Windows to suite a Mac user, see this article : Key Remapping in Windows.
It contains an Autohotkey script that maps many Windows keys to their Mac equivalents.

To build a new keyboard layout, see The Microsoft Keyboard Layout Creator, with which you can manipulate all keys and their combinations.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.