-
Notifications
You must be signed in to change notification settings - Fork 5
[Android strings.xml] Problem with apostrophe handling #235
Comments
When editing the string in the translation web UI, I see:
I populated the data from already translated strings (see the bug description for an example), so the problem appears to be:
Item (2) is correct, but is causing round-tripping issues due to item (1). |
Hi Reece, I believe this is the correct behavior. The Android .strings format is pretty peculiar with quotes: http://developer.android.com/guide/topics/resources/string-resource.html Search for this phrase:
And you will find some useful examples that show what works and what doesn't. Thanks |
The examples in the Escaping apostrophes and quotes section do not show escaped apostrophes with enclosing quotes -- e.g. These strings originated from the Google eyes-free project which uses both forms of escaping together. This was developed by Google engineers. |
Exactly. Either your string should say: <string name="engine_settings" msgid="15960710549009350">"Configuració d'eSpeak TTS"</string> Or it should say: <string name="engine_settings" msgid="15960710549009350">Configuració d\'eSpeak TTS</string> Believe me, Google engineers make mistakes too :-) Thanks |
Likewise, a properly escaped string in strings.xml such as:
gets changed into this after I do a tx push -t and a tx pull:
which the android build then fails on. I also notice that my < and > get changed into < and &rt; which also shouldn't happen and which will just silently (with no build error) result in < and > appearing in the UI. |
Hi,
If a string contains an escaped apostrophe (
\'
), it gets modified to\\'
(e.g. after runningtx pull
) which causes build errors when building the Android application in Eclipse. For example:gets converted to:
Thanks,
Reece
The text was updated successfully, but these errors were encountered: