This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 84103 - I18N - Matisse Automatic Internationalization doesn't help to translate mnemonics
Summary: I18N - Matisse Automatic Internationalization doesn't help to translate mnemo...
Status: NEW
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 5.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@guibuilder
URL: http://form.netbeans.org/JavaOne/#aut...
Keywords: I18N
Depends on:
Blocks:
 
Reported: 2006-09-04 00:23 UTC by siryes
Modified: 2013-05-24 08:50 UTC (History)
3 users (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
Example project with manually corrected Bundle.properties (to test, add new component to the form and try to localize its mnemonic property) (12.49 KB, application/octet-stream)
2006-09-04 00:27 UTC, siryes
Details

Note You need to log in before you can comment on or make changes to this bug.
Description siryes 2006-09-04 00:23:23 UTC
While testing "Matisse Update Pack for NetBeans 5.0" I've found Automatic
Internalization a very useful feature. However, while it works perfectly for
"text" property of components (JLabel, JButton, etc.) the support for
"mnemonic" / "displayedMnemonic" properties is sub-optimal.

Consider a simple form for entering a person's name and surname:

- en_US: JLabel     (text: Name)    (mnemonic: N)
         JTextField
         JLabel     (text: Surname) (mnemonic: S)
         JTextField
         JButton    (text: OK)      (mnemonic: O)
         JButton    (text: Cancel)  (mnemonic: C)

- pl_PL: JLabel     (text: Imię)    (mnemonic: I)
         JTextField
         JLabel     (text: Nazwisko)(mnemonic: N)
         JTextField
         JButton    (text: OK)      (mnemonic: O)
         JButton    (text: Anuluj)  (mnemonic: A)

As it is now only one mnemonic is easily settable. True, the editor can be
persuaded to create an internationalized mnemonic after pressing ellipsis
[...] button. However when additional locales are present (default, en_US
and pl_PL for example) I've encountered a quirk that the mnemonic key
"NewJFrame.jLabel1.mnemonic" was not created for all locales.

In this case I needed to switch to the Files view, locate Bundle.properties
and add missing mnemonic keys/values manually. However, switching between
design locales doesn't update component mnemonics, even though they are
different in every locale.

So, two related issues are here:
 (1) please make translation of mnemonics easier
 (2) remember to update the mnemonics when switching between design locales
Comment 1 siryes 2006-09-04 00:27:02 UTC
Created attachment 33545 [details]
Example project with manually corrected Bundle.properties (to test, add new component to the form and try to localize its mnemonic property)
Comment 2 Tomas Pavek 2010-08-19 14:16:50 UTC
Changing the mnemonics with switching the design locale works for me in current builds. Auto internationalization not working for mnemonics is a missing feature, complicated by the fact that there are two related properties for mnemonics: mnemonic and displayedMnemonicIndex.

There is simply a missing feature in Swing that would allow to define the mnemonics directly in the text (e.g. like "Save &As").
Comment 3 schulte2004 2013-05-24 08:50:04 UTC
Please enable support for automatic internationalization of properties 'mnenomic' and 'displayedMnenomicIndex' when enabling 'Automatic Internationalization' for a form. In Netbeans 7.3, the editor of those properties needs to be switched to 'Internationalized Mnenomics' and 'Internationalized Index' manually and all data has to be filled in manually then.