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.
NetBeans IDE Dev (Build 200703201900) 1.6.0; Java HotSpot(TM) Client VM 1.6.0-b105 Windows XP version 5.1 running on x86 en_GB (nb); Cp1252 Description: ============ have jFrame e.g contained jLabel. Text of jLabel has special character e.g. Degrees [°] - displayed in design, in source code there this text is represented as escape sequence - "Degrees [\u00b0]: " Problem, when user wants this form internationalize through i18n wizard. Wizard works just with source code and doesn't recognize, "Degrees [\u00b0]: " represents special character and considers it as string. It causes that form can't load correct value from bundle. Another point: wizard should also offer user correct key value - "Degrees [°] " during replacing - instead of "Degrees [\u00b0]: "
Confirmed, accepted.
now in resource bundle there is special character represented as \\uxxxx but generated code (for key) which load value from properties contains only one backslash => not possible to run the application. i18n is done by wizard
This bug manifests only if all of the following conditions are met: - automatic internationalization is turned off in the form editor - the user runs additonal internationalization of a form element's text - the element's text contains at least one non-ASCII character There is a workaround possible - either use the automatic internalization of a text in the form editor (in the customizer of the element's "text" property, select item "Resource Bundle" from the combo-box) or enter the element's text as a custom code (in the customizer, select item "Custom Code") and then internationalize using the Internationalize... action. It is not a regression - it is present both in NB 5.5 and NB 5.5.1 (latest build). The bug is not so easy to fix (so I removed the SIMPLEFIX keyword) and it is quite risky to attempt to fix it that late in the development cycle for M9.
note for me: after fix, verify it together with issue 101732
Fixed in the trunk. The I18n wizard now recognizes both Unicode escape sequences and octal escape sequences and handles them as equivalent characters. Modified files: i18n/src/org/netbeans/modules/i18n/java/JavaI18nSupport.java (1.20) properties/src/org/netbeans/modules/properties/Element.java (1.37) properties/src/org/netbeans/modules/properties/UtilConvert.java (1.18) Added test classes: i18n/test/unit/src/org/netbeans/modules/i18n/java/JavaI18nSupportTest.java (1.1 - new file) properties/test/unit/src/org/netbeans/modules/properties/ElementTest.java (1.1 - new file) Diffs: http://i18n.netbeans.org/source/browse/i18n/src/org/netbeans/modules/i18n/java/JavaI18nSupport.java?r1=1.19&r2=1.20&diff_format=u http://properties.netbeans.org/source/browse/properties/src/org/netbeans/modules/properties/Element.java?r1=1.36&r2=1.37&diff_format=u http://properties.netbeans.org/source/browse/properties/src/org/netbeans/modules/properties/UtilConvert.java?r1=1.17&r2=1.18&diff_format=u http://i18n.netbeans.org/source/browse/i18n/test/unit/src/org/netbeans/modules/i18n/java/JavaI18nSupportTest.java?rev=1.1&content-type=text/vnd.viewcvs-markup http://properties.netbeans.org/source/browse/properties/test/unit/src/org/netbeans/modules/properties/ElementTest.java?rev=1.1&content-type=text/vnd.viewcvs-markup
Product Version: NetBeans IDE Dev (Build 20071012030351) Java: 1.6.0_02; Java HotSpot(TM) Client VM 1.6.0_02-b05 System: Windows XP version 5.1 running on x86; Cp1252; en_GB (nb) Description: ============ now i18n wizard drop all strings which contains escape sequences and doesn't offer them like strings which should be replaced. Therefore I have to reopen this issue
This bug is really fixed, with the exception of strings in guarded blocks, as reported in bug #114874. While trying to reproduce this bug, I found that if I put a non-internationalized string (with a Unicode sequence) outside of the guarded block and run the Internationalization wizard, the wizard correctly translates (almost) all non-internationalized strings, even those in the guarded block.
verified on Product Version: NetBeans IDE 6.0 Beta 2 (Build 200710212201) Java: 1.6.0_02; Java HotSpot(TM) Client VM 1.6.0_02-b05 System: Windows XP version 5.1 running on x86; Cp1252; en_GB (nb)