Jump to content

Questions concerning some hotkey issues

Recommended Posts

Posted (edited)

Hello folks!

I have some questions and comments concerning what I consider some "hotkey issues" in AutoIt, so I hope I don't get misinterpreted here, especially because I'll use some similar scripting languages just as a matter of comparison, and the post is quite long, so I hope you have the patience to read it.

1) In some fullscreen applications (like games and bank apps, for example), HotKeySet doesn't work at all.
However, _IsPressed inside a loop works as expected, but as we all know, if something breaks the flow of the loop (like a MsgBox, for example), _IsPressed have to wait until the next iteration of the loop, so I think there's the whole purpose of using a HotKeySet independently outside of any loop.

(I'm using MsgBox here just to show the inconvenience of use _IsPressed instead of HotKeySet)

This theoretically should work, but it doesn't in those particular cases I described above:

HotKeySet("{F11}", "Test")

Func Test()
   MsgBox(0, "", "Test")

This partially works, but of course, stops in the MsgBox waiting for another loop:

While True
   If _IsPressed("7A") Then
      MsgBox(0, "", "Test")

2) Another question is about the limitation of HotKeySet the F12 key. The help file states that "F12 is also reserved by Windows, according to its API", so I would like to know why another similar scripting languages like Lua and AutoHotkey can do that without any problems. Isn't an AutoIt limitation instead of a Windows API reservation?

3) Just to cite another example, I have a nice Logitech Gaming keyboard with the 12 standard F keys, and plus more 12 G keys, so I'm able to map those extra keys as F13-F24, supported natively by Lua scripting through the Logitech Gaming Software, or externally by AutoHotKey.
My question is why HotKeySet doesn't support F13-F24, despite _IsPressed has that functionality?

4) I'm an avid Photoshop amateur user, but I don't like the way Adobe hardcode the modifier keys in their software, so I use to remap Ctrl, Shift, Alt and Win keys the way I want, but unfortunately, AutoIt doesn't have a remap function, so I have to use "that another scripting language" to do that.
Assuming that remap is quite different than hotkey, any reason for AutoIt not supporting remapping natively?

5) I eventually use the MouseOnEvent UDF by MrCreator to circumvent the fact AutoIt doesn't support mouse buttons as hotkeys, but the UDF has some limitations as well, so my question is why AutoIt doesn't have a function similar to HotKeySet for mouse buttons?

If you're still reading, I appreciate your effort and thank you in advance!
Any comments, as always, are very welcome...

Edited by RegiOween

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now