Programming function keys

4 posts / 0 new
Last post
Efher
Efher's picture
Offline
Last seen: 9 months 1 week ago
Joined: 2012-07-20 00:06
Programming function keys

I want to use the function keys in a MUI application.

I have succeeded using the functions keys "alone" (with no qualifier key).
But when I want to use one (or several) qualifier key (shift, alt, ctrl...) it
doesn't works: hiting the keys gives no event...

I'm using the next method:

DoMethod (MUI_object,
MUIM_Notify, MUIA_Window_InputEvent, "F1",
MUIV_Notify_Application, 2, MUIM_Application_ReturnID, KEY_ID);

It works nice.

If I replace F1 using, for example, "Shift-F1" it doesn't works any more...

Any idea?

thomas
thomas's picture
Offline
Last seen: 3 days 5 hours ago
Joined: 2011-05-16 14:23
Re: Programming function keys

You need to use a proper input event descriptor string.

http://wiki.amigaos.net/wiki/Commodities_Exchange_Library#Filter_Objects_and_Input_Description_Strings

"shift f1" should work (with a space instead of a hyphen), but only because rawkey is the default. Fully qualified it would be "rawkey shift f1".

tboeckel
tboeckel's picture
Offline
Last seen: 9 months 1 week ago
Joined: 2011-09-13 12:32
Re: Programming function keys

The correct input event description would be "shift f1" (note the omitted dash).

Efher
Efher's picture
Offline
Last seen: 9 months 1 week ago
Joined: 2012-07-20 00:06
Re: Programming function keys

Thanks for your reply.
It works like you say (a space in place of the '-').

Thanks a lot again.

Log in or register to post comments