Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Make AutoHotKey ignore Alt as menu key

Tags:

autohotkey

I'm trying to use autohotkey to simulate elements of Mac keyboard on a PC (Windows) keyboard. My muscle memory reaches for the Command key for simple tasks like copying and pasting, so I'd like to remap the left alt+letter key combinations to appropriate ctrl+letter.

<!c::Send ^c

Most of the time it works fine, except for part of the time in IE and Office applications. When pressing the left Alt, it screws with the office ribbon/menus (i.e. the menu bar shows in IE, or ribbon letters start appearing in Office 2010), and the ctrl+letter combination fired does not reach destination.

I've read the AHK FAQ + forums, tried a couple of options with UP and $ modifiers to the hotkey, but it did not fix the problem. Any ideas?

like image 691
ttarchala Avatar asked Dec 18 '12 14:12

ttarchala


1 Answers

This prevents the left-hand side Alt key from activating the menu bar for most applications (under Windows 7 and AutoHotkey 1.1.11.01):

~LAlt Up:: return

It doesn't work with Internet Explorer but I don't use IE often anyway. :)

BTW, I also killed the annoying start menu popup via:

~LWin Up:: return
~RWin Up:: return
like image 166
zengabor Avatar answered Oct 06 '22 07:10

zengabor