After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 310400 - Clear/Cancel stock item mnemonic clash
Clear/Cancel stock item mnemonic clash
Status: RESOLVED WONTFIX
Product: gtk+
Classification: Platform
Component: .General
2.7.x
Other All
: Normal minor
: ---
Assigned To: gtk-bugs
gtk-bugs
AP4, aklapper[mnemonics]
Depends on:
Blocks:
 
 
Reported: 2005-07-14 18:37 UTC by Vincent Noel
Modified: 2013-02-03 21:46 UTC
See Also:
GNOME target: ---
GNOME version: 2.11/2.12



Description Vincent Noel 2005-07-14 18:37:33 UTC
The 'Clear History' dialog has 2 problems :
* the dialog has a title
* the two buttons (Cancel/Clear) have the same mnemonic.
Comment 1 Vincent Noel 2005-07-15 15:55:50 UTC
The mnemonic clash is apparently done in eel :

dialog = eel_create_question_dialog (prompt,
					     detail,
					     _("Clear History"), 
					     GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
					     GTK_STOCK_CLEAR, RESPONSE_FORGET,
					     GTK_WINDOW (window));

eel should check the mnemonics of buttons in the dialog and correct them in case
of clash.
Comment 2 Christian Neumair 2005-07-15 21:01:54 UTC
Nah. Randomly changing mnemonics isn't very user-friendly, particularly wrt
stock items and i18n. The two mnemonics for the clear and cancel GTK+ stock
items simply shouldn't clash.
Comment 3 Owen Taylor 2005-07-15 21:05:30 UTC
So, uh, GTK+ can only have 26 stock items?
Comment 4 Alan Horkan 2005-07-16 21:18:45 UTC
There is a school of thought which says Esc should always Cancel so you do not
need to have a mnemonic for it.  This is something I happen to agree with.  

> So, uh, GTK+ can only have 26 stock items?

Good point.  The problem is developers need a way to override conflicting
mnemnonics without destroying the advantages of being able to use the stock
labels and their stock translations.  

Two items having the same mnemonic causes problems but it fails in a fairly safe
way, instead of taking the action you cycle through the avaiable actions with
the same mnemonic.  For this reason I wouldn't rush to any solution which
automatically corrects mnemnonics because it could cause more problems than it
solves.  

(There may also be potential to redesign how this all works and avoid the issue
entirely.)
Comment 5 Calum Benson 2005-07-18 14:52:54 UTC
I guess it wouldn't hurt to go through the stock items and make sure the ones
that are known to (or are likely to) appear in the same window at the same time
in our core applications have different mnemonics, where possible, if nobody's
done this already.  Other than that, it's probably not a particularly big deal.  

(I do happen to agree with Alan that having mnemonics for OK and Cancel is
redundant, looks a bit ugly, and I'd be surprised if enough people worth caring
about ever used them.  But we debated it pretty thoroughly at the time and the
pro-mnemonic faction won, so I'm not in any hurry to thrash that one out again...)
Comment 6 Calum Benson 2006-04-26 16:58:36 UTC
Apologies for spam-- marking AP4 to reflect accessibility impact.
Comment 7 Calum Benson 2006-04-26 17:11:50 UTC
Apologies for spam... ensuring Sun a11y folks are cc'ed on all current accessibility bugs.
Comment 8 Matthias Clasen 2013-02-03 21:46:24 UTC
closing some old bugs