Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 367776 - Swing: Missing Mnemonics on special characters
Summary: Swing: Missing Mnemonics on special characters
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Scout (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-03 11:44 EST by Bruno Koeferli CLA
Modified: 2021-08-19 11:02 EDT (History)
3 users (show)

See Also:
mvi: luna+


Attachments
Patch to identify special characters as mnemonics (604 bytes, patch)
2012-01-03 11:44 EST, Bruno Koeferli CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bruno Koeferli CLA 2012-01-03 11:44:14 EST
Created attachment 208948 [details]
Patch to identify special characters as mnemonics

Build Identifier: 3.7.0.2011-Jun 2011

PROBLEM DESCRIPTION:
In Swing Mnemonics on special characters (f.e. äöüÄÖÜéÉ...) will not be recognized, but SWT will do.

EVALUATION:
The problem is located in the class StringUtility, presumably in the Regex pattern
MNEMONIC_PATTERN. This pattern is used to identify the Mnemonic character as well as to remove the Mnemonic from a string. The manual identification is only needed in Swing, SWT can handle these identification by its own.

PROPOSED SOLUTION:
The MNEMONIC_PATTERN has to be adjusted to also match special characters as äöü... The attached patch basically allows every character which is not a whitespace or an ampersand (&) itself.

Reproducible: Always
Comment 1 Judith Gull CLA 2013-04-15 08:47:14 EDT
Thanks for the patch. It looks good to me. Please add tests for the changed method (StringUtility.getMnemonic).
Comment 2 Jeremie Bresson CLA 2013-09-12 07:54:10 EDT
Change opened by Matthias Nick for develop branch:
https://git.eclipse.org/r/16322/
Comment 3 Matthias Villiger CLA 2013-09-12 10:36:00 EDT
pushed commit c2db2766826bf9cc3fffb25d35fa644d799c69ec (http://git.eclipse.org/c/scout/org.eclipse.scout.rt.git/commit/?h=develop&id=c2db2766826bf9cc3fffb25d35fa644d799c69ec)

Thanks Matthias & Bruno for the contribution!

Available with scout 3.10 M2 or nightly version >= 2013-09-13

@Bruno: Can you verify the change with one of these version please?
Comment 4 Bruno Koeferli CLA 2013-10-10 08:12:13 EDT
Tested with version 3.10.0.20131004-1128
Comment 5 Matthias Zimmermann CLA 2014-07-01 03:20:53 EDT
Shipped with Eclipse Luna Release