Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 28072

Summary: [KeyBindings] Show key bindings in menus
Product: [Eclipse Project] Platform Reporter: Nikolay Metchev <nikolaymetchev>
Component: UIAssignee: Chris McLaren <csmclaren>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P2 CC: andy.w.freeman, bogofilter+eclipse.org, eclipse-bugs, eduardo_pereira, j.c.yip, markus.kell.r, n.a.edgar, tonny.madsen
Version: 2.1   
Target Milestone: 3.0 M4   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 37667    

Description Nikolay Metchev CLA 2002-12-11 05:58:02 EST
It would be nice in the drop down menus that pop up when you right click in the 
editor to be able to see if any key binding has been assigned to the various 
actions available and exactly which key binding has been assigned to it.
Comment 1 Adam Kiezun CLA 2002-12-11 06:02:13 EST
not sure but that might be against some ui guidelines
asking the platform for an opinion
Comment 2 Simon Arsenault CLA 2002-12-11 13:22:49 EST
Nick/Chris,

Can you comment on this? I've never seen a context menu that shows the shortcut 
keys. If we do want to do this, is there support from the ky binding service?
Comment 3 Nick Edgar CLA 2002-12-11 14:28:33 EST
The MS UI guidelines state: "To enhance spatial efficiency and readability, 
avoid including shortcut keys in shortcut menus."

Idea shows shortcut keys everywhere (pulldown menus, context menus, tooltips 
for toolbar buttons).   The are right-aligned and shown in blue (Windows uses 
left-aligned and doesn't support colour).

VS.NET has an option to show shorcut keys in toolbar tooltips, but never shows 
them in context menus.

I'm not averse to the idea.  It encourages learning how to drive the 
environment by keyboard.  
Comment 4 Sonia Dimitrov CLA 2003-02-20 10:32:03 EST
*** Bug 32188 has been marked as a duplicate of this bug. ***
Comment 5 Ron Baldwin CLA 2003-02-21 02:34:17 EST
Closely related but different:  What about putting shortcut keys in the toolbar
tooltips?  This is very useful and not contrary to any (Windows) UI guidelines.
Comment 6 Nick Edgar CLA 2003-02-21 10:05:42 EST
See bug 15079 for the toolbar case.
Comment 7 Nikolay Metchev CLA 2003-07-10 09:12:51 EDT
any chance this could be addressed for 3.0?
Comment 8 Chris McLaren CLA 2003-09-03 14:34:58 EDT
*** Bug 42356 has been marked as a duplicate of this bug. ***
Comment 9 Jason Yip CLA 2003-09-04 20:21:42 EDT
Any UI guideline that says you shouldn't include shortcut keys in context 
menus, is IMNSHO wrong.

"It encourages learning how to drive the environment by keyboard."

I'm with Nick Edgar on this one.

Comment 10 Jason Yip CLA 2003-09-04 20:24:42 EDT
*** Bug 39154 has been marked as a duplicate of this bug. ***
Comment 11 Chris McLaren CLA 2003-09-05 08:43:29 EDT
i agree that this should happen, and i've made it work with the new commands 
api. its only blocked right now because of a dependancy issue: the commands 
api is in workbench, and ActionContributionItem is in jface. jface does/can 
not have a dependancy on workbench. i expect to move the commands and contexts 
api down to jface shortly to allow us to implement this feature, among others.
Comment 12 Chris McLaren CLA 2003-09-12 14:59:27 EDT
*** Bug 25056 has been marked as a duplicate of this bug. ***
Comment 13 Chris McLaren CLA 2003-09-25 16:51:40 EDT
done in the next build. works automatically by having ActionContributionItems on context menus 
talk to command/key binding archtecture, so nothing is required by the user or plugin developer.

as far as the 'microsoft ui guidelines', i don't think i agree with them. (yes, it is possible..).

personally, just from using it this afternoon, this feature seems pretty nice to have now that its 
there. i didn't put a preference item to make these optional, but i probably should for those that 
find this feature causes too much visual clutter. anyway, give it a try first and let me know.. thanks.