![]() ![]() The upside is that you can rest easy knowing that you're 1-0 in the fight against Microsoft's marketing department for control of your keyboard.Īnyway, the script is a relatively short bit of C++: It's not super intrusive, but it's enough to notice. If your PC takes a second to load the startup apps, it will close any File Explorer windows you have open. The only downside is that because we're restarting explorer, when this program runs on startup, it will flash the desktop black for a split second before restarting. And if you restarted Explorer, it would reregister the hotkeys when it starts back up. Unfortunately, closing Explorer isn't a very viable solution, as you'd be stuck without a usable computer. This means if you can close the program that registered the hotkeys, you can disable them. However, when programs exit, they automatically deregister their hotkeys. You can't register hotkeys that have already been registered by another program. But, if you create a program that runs RegisterHotKey, you'll find that it won't work. Our first thought is to override the Office hotkeys by registering our own. Since Explorer is always open, the hotkeys will be permanent. It's an integral part of Windows, so it makes sense to register hotkeys here hotkeys created with RegisterHotKey will automatically deregister when the process that registered them closes. Under the hood, the Office Key hotkeys are registered this way by Explorer, the process that's responsible for your desktop, taskbar, and File Explorer. In Windows, system-wide hotkeys must be registered with the operating system using the RegisterHotKey system function. Of course, you'll also need to remap the other keys, T, Y, O, P, D, L, X, N, and Space, so the full script is much longer: ![]() This script matches Office+W and sends back the corrected sequence, which solves the issue of Word opening. The character sequence " #^!+" is AutoHotkey shorthand for Windows, Control, Alt, and Shift, respectively. SetWorkingDir %A_ScriptDir% Ensures a consistent starting directory. #NoEnv Recommended for performance and compatibility with future AutoHotkey releases. Just save the text as an AutoHotKey script and run it: The following script will remap Office+W to Shift+Control+Alt+W. REG ADD HKCU\Software\Classes\ms-officeapp\Shell\Open\Command /t REG_SZ /d rundll32 Right-click your Start button and click "PowerShell" to open it: Before we get started with AutoHotkey, there is one registry tweak you'll need to enable by running the following command in PowerShell. There are, however, a few tweaks you can do yourself to either remap the key or turn the shortcut off altogether. Naturally, the fact that you can no longer press Hyper+Y without being taken to the marketing page for Yammer has made Hyper key users fairly upset. There's no option in Settings, no registry tweak, and no group policy. Currently, there's no built-in way to turn off these shortcuts. Unfortunately, out of the 27 available letter keys and spacebar, 10 of them are in use by the Office key shortcuts, with the possibility of Microsoft adding more in the future. Most people repurpose Caps Lock, but the Office key would replace the useless Right Windows key and turn it into something useful. Having a dedicated Hyper key on your keyboard would be great.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |