Wednesday, January 2

Useful Hotkey Script

This post is only tangentially related to the purpose of this blog but I find it to be pretty useful nonetheless.

I came across this pretty convenient utility a while ago for writing scripts for your desktop. There are innumerable applications where this tool may be used to speed up or automate particularly repetitive tasks on the computer. The highlight of this post is a particular script that enables re-sizing, closing, minimizing, and maximizing windows with the ALT key and mouse. It also includes what I considered to be a pretty creative implementation that the author terms as the "double-alt".

All of these hotkeys involve a combination of the ALT key and some mouse button. The purpose is to enable manipulation of windows in a way that doesn't require precision. Any window may be re-positioned by holding ALT, left clicking anywhere inside the desired window, and dragging to the desired location. Any window may be re-sized by holding ALT, right clicking inside the window, and dragging to the desired size. This is effectively a corner-drag that selects the nearest corner rather than requiring you to surgically select each corner and re-size. One useful characteristic (or annoying, depending on the context) is the fact that these resize operations do not involve selecting the window as active. In other words, an inactive window may be resized or moved without changing it to the active window.

The last three hotkeys involve double-tapping (and holding) the ALT button and using the left, right, and center mouse buttons to minimize, maximize/restore, and close windows respectively. The double-alt takes a little bit of getting used to, but once you incorporate it into your habits, it becomes a lot easier than clicking on a window's minimize, close, and restore icons.

One might argue that WINDOW+D or ALT+F4 are good enough for the purposes of minimization and closing. One thing to note about the double-alt method in this script is that it will modify any visible window on the screen. If you want to close or eliminate a window that has popped up but isn't active, you will have to select it before using ALT+F4 whereas, if you want to be done with it immediately, double-alt click can be enormously convenient.

Alt+Left Mouse Click (Hold)

Drag Window

Alt+Right Mouse Click (Hold)

Resize Window

Double-Alt Left Mouse Click

Minimize Window

Double-Alt Right Mouse Click

Maximize/Restore Window

Double-Alt Middle Mouse Click

Close Window

No comments:

Post a Comment