[TIMOB-16815] iOS / Android: Internationalization Unicode Prefix Parity
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | Low |
| Status | Open |
| Resolution | Unresolved |
| Affected Version/s | Release 3.2.2 |
| Fix Version/s | n/a |
| Components | iOS |
| Labels | android, i0S, internationalization, parity |
| Reporter | Paul Hamilton |
| Assignee | Unknown |
| Created | 2014-03-27T19:58:57.000+0000 |
| Updated | 2018-09-20T19:35:14.000+0000 |
Description
When trying to display unicode characters in the i18n strings.xml file iOS requires a capital 'U', android requires a lowercase 'u'. If not provided the typed characters show up.
example a non breaking space with code 00A0,
\u00A0 - android
\U00A0 - iOS
no known workaround with internationalization, as it doesn't allow if/else code branches. Ideally, both would allow both.
Moving this ticket to engineering as I can reproduce this issue with a simple test case. iOS and Android platforms expect a differ unicode prefix. Strings.xml file (i18n/en directory)
app.js file:<?xml version="1.0" encoding="UTF-8"?> <resources> <string name="u_str">Testing no-breaking space \u00A0</string> <string name="U_str">Testing no-breaking space \U00A0</string> </resources>var win = Titanium.UI.createWindow({ backgroundColor : '#fff' }); win.add(Titanium.UI.createLabel({ top: 100, color : '#333', text : L('u_str'), })); win.add(Titanium.UI.createLabel({ top: 200, color : '#333', text : L('U_str'), })); win.open();