Bug 550757 - Key binding popup doesn't show sequence
Summary: Key binding popup doesn't show sequence
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.13   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.22 RC1   Edit
Assignee: Mickael Istria CLA
QA Contact:
URL:
Whiteboard:
Keywords: usability
Depends on:
Blocks:
 
Reported: 2019-09-04 15:18 EDT by Mickael Istria CLA
Modified: 2021-11-16 01:52 EST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mickael Istria CLA 2019-09-04 15:18:26 EDT
I've got the (very cool) "show key bindings when command is invoked" turned on, using Eclipse SDK I20190904-0605.
If I hit `Alt+Shift+Q Q` to get the "Show view" dialog, then the popup only show "Q - show view".
The first part of the sequence is missing.
Comment 1 Eclipse Genie CLA 2021-08-25 14:09:34 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 2 Mickael Istria CLA 2021-08-25 18:32:44 EDT
This is still an issue.
Comment 3 Matthias Becker CLA 2021-08-26 02:07:54 EDT
This seems to be an issue that we have two "normal" characters here ("Q").
Other shortcuts that include 4 keypresses with 3 modifiers but only one normal character like the "Quick Search..." ("Option, Shift, Command, L" on macOS) are displayed correctly. 

The same issue exists for Run As > JUnit Test ("Option, Command, X, T").

The problem seems to be be in the command framework because the ShowKeysListener (that is registered to show the key-binding) is not called only after the second "Q" is triggered.
Comment 4 Mickael Istria CLA 2021-08-26 02:50:42 EDT
(In reply to Matthias Becker from comment #3)
> This seems to be an issue that we have two "normal" characters here ("Q").
> Other shortcuts that include 4 keypresses with 3 modifiers but only one
> normal character like the "Quick Search..." ("Option, Shift, Command, L" on
> macOS) are displayed correctly. 

I'm under the impression that it's not about character or not character, but more about the popup showing only the last key event of the binding sequence.
Eg if shortcut would be "F1 F2" as a sequenxe (not "F1+F2" as a single keystroke combination) popup would show only F2 as the last hit of the sequence.

> The problem seems to be be in the command framework because the
> ShowKeysListener (that is registered to show the key-binding) is not called
> only after the second "Q" is triggered.

I think the problem is that the popup just shows the event that completed the sequence and doesn't show the whole KeyBinding. The command framework has API to retrieve thw whole keybonding for a sequence, the popup may not use them well.
Comment 5 Matthias Becker CLA 2021-08-26 03:22:19 EDT
(In reply to Mickael Istria from comment #4)
> The command framework has API to retrieve thw whole keybonding for a sequence, > the popup may not use them well.

Can you tell me that API?
Comment 6 Mickael Istria CLA 2021-08-26 03:38:08 EDT
(In reply to Matthias Becker from comment #5)
> Can you tell me that API?

IBindingServer.getBindingsFor(command)
Comment 7 Mickael Istria CLA 2021-11-15 10:52:51 EST
One good example here is the Show View command (Window > Show View... > Others...); with keybinding popup on:
* Trigger it with mouse: popup says Alt+Shift+Q Q
* Trigger it with Alt+Shift+Q Q shortcut: popup says just Q
Comment 8 Eclipse Genie CLA 2021-11-15 11:08:23 EST
New Gerrit change created: https://git.eclipse.org/r/c/platform/eclipse.platform.ui/+/187739
Comment 9 Matthias Becker CLA 2021-11-16 01:16:04 EST
(In reply to Eclipse Genie from comment #8)
> New Gerrit change created:
> https://git.eclipse.org/r/c/platform/eclipse.platform.ui/+/187739

Thanks for taking care.