Ctrl-W could close window

Have a suggestion for "Everything"? Please post it here.
Post Reply
johnson
Posts: 2
Joined: Tue Jun 02, 2009 10:39 am

Ctrl-W could close window

Post by johnson »

Small suggestion: the keyboard shortcut Ctrl-W could be mapped to close the current window (in addition to the cumbersome Alt-F4).

Thanks for the tool!
johnson
Posts: 2
Joined: Tue Jun 02, 2009 10:39 am

Re: Ctrl-W could close window

Post by johnson »

Heh, I just noticed Ctrl-W was already used for "Match Whole Words".
David
Developer
Posts: 430
Joined: Tue Mar 17, 2009 1:42 am

Re: Ctrl-W could close window

Post by David »

Custom keyboard mappings is on my "Things to do" list.
Function
Posts: 15
Joined: Fri Jun 05, 2009 9:13 pm

Re: Ctrl-W could close window

Post by Function »

For now you can do a workaround with AutoHotKey (Which, by the way is an incredibly useful app)

You can write a script like this:

Code: Select all

 $^w::
  IfWinActive, Everything
  {
    Send, !{F4}
    return
  }
  Send, ^w
  return
What this does is makes a global hotkey for Ctrl + W. If the Everything window is active, it closes it. If any other window is active, it allows the Ctrl + W hotkey to pass through.

If you're unfamiliar with AutoHotKey (AHK) it's a tiny macro program that gives you full control over windows and your other programs. From the site:
AutoHotkey is a free, open-source utility for Windows. With it, you can:

Automate almost anything by sending keystrokes and mouse clicks. You can write a mouse or keyboard macro by hand or use the macro recorder.
Create hotkeys for keyboard, joystick, and mouse. Virtually any key, button, or combination can become a hotkey.
Expand abbreviations as you type them. For example, typing "btw" can automatically produce "by the way".
Create custom data-entry forms, user interfaces, and menu bars. See GUI for details.
Remap keys and buttons on your keyboard, joystick, and mouse.
Respond to signals from hand-held remote controls via the WinLIRC client script.
Run existing AutoIt v2 scripts and enhance them with new capabilities.
Convert any script into an EXE file that can be run on computers that don't have AutoHotkey installed.
tonne
Posts: 2
Joined: Fri May 01, 2009 11:22 am

Re: Ctrl-W could close window

Post by tonne »

Or even simpler (still AutoHotkey):

Code: Select all

#IfWinActive,Everything
^w::send !{f4}
#IfWinActive
Function
Posts: 15
Joined: Fri Jun 05, 2009 9:13 pm

Re: Ctrl-W could close window

Post by Function »

I always have trouble with #IfWinActive but yeah, that is a very good and simple way to do that.
Post Reply