JDK-7176528 : [macosx] Extra mnemonic keys on JCP button labels in asian locales
  • Type: Bug
  • Component: globalization
  • Sub-Component: translation
  • Affected Version: 7u6
  • Priority: P3
  • Status: Closed
  • Resolution: Cannot Reproduce
  • OS: os_x
  • CPU: x86
  • Submitted: 2012-06-13
  • Updated: 2017-02-16
  • Resolved: 2012-07-19
Related Reports
Relates :  
Description
JRE 7u6 b11 promotion build
Open Java Control Panel in CCJK. Most of the button labels of JCP display mnemonic keys, but those mnemonic keys actually do not work.

Screenshots are at http://bej301328.cn.oracle.com/gatejava/test/jdk1/results/7u6/b11/java-x64-mac.html.

Some examples:
http://bej301328.cn.oracle.com/gatejava/test/jdk1/results/7u6/b11/java-x64-mac/ja_JP/screenshot-12.png
http://bej301328.cn.oracle.com/gatejava/test/jdk1/results/7u6/b11/java-x64-mac/zh_CN/screenshot-12.png

Comments
EVALUATION I tested with b19 in S.Chinese. If I press Alt, then, all of the underlines would show up. When I press Ctrl+Alt+V for sample, the mnemonic would work. Could the submitter please verify again if the mnemonics still doesn't work on your environment?
18-07-2012

EVALUATION The general.cache.view.text property has following values in the Deployment_zh_CN.java file: ----------------------------------------------------------- { "general.cache.view.text", "\u67E5\u770B(V)..." }, { "general.cache.view.text.mnemonic", "VK_V"}, ----------------------------------------------------------- However mnemonic system has been changed to use the '&' symbol in the text property like: ----------------------------------------------------------- { "general.cache.view.text", "&View..." }, ----------------------------------------------------------- So the the mnemonic is not found in the property ----------------------------------------------------------- { "general.cache.view.text", "\u67E5\u770B(V)..." }, ----------------------------------------------------------- because the ampersand has not been found before the 'V' letter. For example the makeButton method in the GeneralPanel class uses the same key for the text and mnemonic. It means it definetly expects that the mnemonic is placed in the text with the preceding ampersand: -------------------------------------------------------- public JButton makeButton(String key) { JButton b = new JButton(getMessage(key)); b.setMnemonic(ResourceManager.getMnemonic(key)); return b; } -------------------------------------------------------- Try set the '&' for all mnemonics in the text for asian locales.
12-07-2012

EVALUATION Mnemonics aren't displayed by default. To show mnemonics on OS X you have to hold down the Alt key. Ctrl + Alt + Mnemonic invokes the mnemonic. I verified that both holding the Alt key displays the underline on the mnemonic and ctrl + alt + key invokes the button when in English. This implies that the mnemonic set with setMnemonic should still work, but in Japanese it does not work. Sending this over to Artem to start, as this is a Swing issue.
15-06-2012

EVALUATION Looks like there's no underline on English dialog as well: http://bej301328.cn.oracle.com/gatejava/test/jdk1/results/7u6/b11/java-x64-mac/en_US/screenshot-21.png Need assistance from Mac exports about mnemonic support on Mac OS X. Starting wiith deployment team and Scott K. If this is not the proper subcategory, please help to redirect. Thanks.
14-06-2012