Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Single % in format string at res/values/strings.xml #15

Closed
sanvila opened this issue Feb 24, 2014 · 1 comment
Closed

Single % in format string at res/values/strings.xml #15

sanvila opened this issue Feb 24, 2014 · 1 comment

Comments

@sanvila
Copy link

sanvila commented Feb 24, 2014

Hi. There is a single % in res/values/strings.xml which is causing problems to translators using gettext. Should this not be "%%" instead? Please see:

http://lists.gnu.org/archive/html/bug-gettext/2014-02/msg00012.html

Thanks.

@pryds
Copy link
Owner

pryds commented Feb 24, 2014

Thank you for reporting this. It seems the bug is in android2po which I use for converting the Android string resource file (strings.xml) into gettext pot, and back again from translated po files. Android doesn't need escaping of %, so if I use "%%" directly in the xml file, it will appear as "%%" in the English UI.

If a single % in po(t) files causes problems for translators, android2po should convert single % into %% upon export, and %% into % upon import, which it doesn't seem to do, if I'm not mistaken.

I have reported this issue upstream: miracle2k/android2po#26
For now, I'll change the string in question to spell out "percent" instead of just "%".

@pryds pryds closed this as completed Feb 24, 2014
pryds added a commit that referenced this issue Feb 24, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants