FAQ  •  Register  •  Login

semantics of "Apply HotKeys from other HotKey set"

Moderator: MiRai

<<

crookedcross

Posts: 23

Joined: Sat Aug 09, 2014 8:04 pm

Post Thu Aug 28, 2014 4:41 am

semantics of "Apply HotKeys from other HotKey set"

In a menu, I am trying to override 1 HotKey in the HotKey set attached to the menu.

So I defined another HK set containing only 1 HK,
and used a "New HotKey Set Action" :
* set the "HotKey Set" to the Set already attached to the menu
* checked "Apply HotKeys from other HotKey set" choosing the new HotKey Set with the 1 key
* and "Apply starting at my HotKey position" = 30 which is the button number of the key I want to override

I have a feeling I am misunderstanding the meaning of the "New HotKey Set Action" options, but I could not find doc on them.
<<

bob

User avatar

League of Extraordinary Multiboxers

Posts: 4586

Joined: Sat Feb 15, 2014 11:14 am

Location: In the dining room, with the lead pipe.

Post Thu Aug 28, 2014 5:00 am

Re: semantics of "Apply HotKeys from other HotKey set"

It wont override a button, it will override the standing HK set that is currently applied to that menu.

Assuming there is currently only one HK set, you can check the standing HK set to see the # column, which at position 30 is the one that in theory will be overridden.

Also, you don't specify what Target you have selected. Presumably it is Window: All w/Current or Window:Current ??

Also, you haven't stated what isn't working. Presumably this is a post to try and fix something that is not working, rather than just a statement of what you are doing and a subtle request for someone to update the documentation.
<<

crookedcross

Posts: 23

Joined: Sat Aug 09, 2014 8:04 pm

Post Thu Aug 28, 2014 6:52 am

Re: semantics of "Apply HotKeys from other HotKey set"

oops, sorry I forgot to mention specifically the problem and was not clear enough about intentions:

I have HotKey Set "HK-grid" attached to menu "grid"
"HK-grid" has 30 keys, and "grid" has 30 buttons.
I want button 30 in grid to be triggered by a different HK from that defined in "HK-grid" item 30
So I tried to attach a new HK Set "HK-esc" at position 30 using "Apply HotKeys from other HotKey set"
(possibly important detail: "HK-grid"'s definition has an item for HK 30, but with no key bound)

The target for the "New HotKey Set Action" is "Window:Current"

The problem is that <escape> is ignored by the menu, and the escape keystroke falls through to the game window.

It wont override a button, it will override the standing HK set that is currently applied to that menu.

So if I have HK set A which has 10 HotKeys
and set B with 10 keys
I attach A to menu. and then use the "Apply HotKeys from other HotKey set" starting at key 5, will that work?
or do they need to be non-overlapping?

the latter would explain my problem.
<<

lax

User avatar

Site Admin

Posts: 7301

Joined: Tue Nov 17, 2009 9:32 pm

Post Thu Aug 28, 2014 7:10 am

Re: semantics of "Apply HotKeys from other HotKey set"

Sounds like you understand the "Hotkey Set Action" to me, and it does what you expect.

Sure it's "not fully documented", but ... http://isboxer.com/wiki/Actions says a Hotkey Set Action can "Attach a Hotkey Set to a Menu, detach a Hotkey Set from any Menu, or copy Hotkeys from another Hotkey Set"

("New" is not literally part of the name of every single kind of Action ISBoxer has, it means you're going to add a new Action to your Step)

Also, rather than replacing individual buttons on your Menu with 1-Hotkey Sets, I might be inclined to use a Do Menu Button Action as part of a Mapped Key instead.

do they need to be non-overlapping?

No that would make this option pretty useless.


I tested what you're doing just now and it works as expected. With the standard config from the QSW, I added a Hotkey Set with exactly one Hotkey in it set to Escape. Then I made a Mapped Key with one Action in it, a Hotkey Set Action, to set the Standard Hotkey Set, to Apply Hotkeys from other Hotkey Set as my new single Hotkey, and I set the Hotkey position to 12. After I hit my Hotkey, button 12 on the Standard Menu (which the Standard Hotkey Set is already applied to) is then activated via Escape instead of =.

You can double check all of the currently-bound Hotkeys via the in-game Inner Space console if you want. You must set a Hotkey for this in your Character Set (I use Alt+`) and then in the console, enter the command "bind -list". This dumps a list of all the Hotkeys configured with at the time.

Before:
Code:
[hotkeyLayout_Standard_btn12] [=] Command (Press): noop ${MenuMan:OnHotkey["Standard",12,1]}
[hotkeyLayout_Standard_btn12] [=] Command (Release): noop ${MenuMan:OnHotkey["Standard",12,0]}

After:
Code:
[hotkeyLayout_Standard_btn12] [Esc] Command (Press): noop ${MenuMan:OnHotkey["Standard",12,1]}
[hotkeyLayout_Standard_btn12] [Esc] Command (Release): noop ${MenuMan:OnHotkey["Standard",12,0]}
<<

crookedcross

Posts: 23

Joined: Sat Aug 09, 2014 8:04 pm

Post Thu Aug 28, 2014 7:49 am

Re: semantics of "Apply HotKeys from other HotKey set"

I will try your recommendation to use a mapped key if I cannot get this to work otherwise.

The reason I want to replace 1 mapped key is:

I have popup menus and a root menu which is not popup.
They share the same HotKey Set allowing me to cascade menus sharing only a small set of keys (described in other thread).
When I popup a menu, I just need to assign the HotKey Set to the new menu, which automatically steals the set from the parent menu. So I do not need to "deactivate" the parent menu first, and this really helps simplify the configuration.

I need a "cancel" button on the popups.
But I don't want the cancel active on the root/parent menu.
So the shared HotKey Set is defined with item 30 existing but with no key bound.
When I popup a child menu, I attach the shared HK Set to the new popup menu, and then attempt to make key 30 <escape>.

Thanks for "bind -list" :D:D:D
and for confirming expected behavior of the action.
If I manage to become an expert on the "HotKey Set Action" is there a way for me to contribute to the doc wiki?
<<

lax

User avatar

Site Admin

Posts: 7301

Joined: Tue Nov 17, 2009 9:32 pm

Post Thu Aug 28, 2014 7:59 am

Re: semantics of "Apply HotKeys from other HotKey set"

is there a way for me to contribute to the doc wiki?

I've added you to the Wiki Contributors usergroup, so you can now edit the wiki
<<

crookedcross

Posts: 23

Joined: Sat Aug 09, 2014 8:04 pm

Post Thu Aug 28, 2014 8:03 am

Re: semantics of "Apply HotKeys from other HotKey set"

Fantastic. Thank you. Now I shall work on becomming an expert.

Return to Menus

Who is online

Users browsing this forum: Google [Bot] and 3 guests