Airsaid / AndroidLocalizePlugin

:earth_asia: Android localization plugin. supports multiple languages and multiple translators.
https://plugins.jetbrains.com/plugin/11174-androidlocalize
Apache License 2.0
590 stars 91 forks source link

Not ignoring parts of strings marked to ignore #18

Closed scudderfish closed 4 years ago

scudderfish commented 5 years ago

Please ensure you have given all the following requested information in your report.

Please select the affected platforms

Version of Plugin and IDE

Issue details

According to https://developer.android.com/guide/topics/resources/localization, it should be possible to mark sections to be not translated with </xliff:g>, such as number placeholders and embedded format strings. However the plugin doesn't honour that.

Attempting to translate this

<string name="configuration_error_explaination">Your controller reported the following configuration error:<xliff:g>\n\n%1$s\n\n</xliff:g>Go into the Tuning section, fix the problem and power cycle your controller.</string>

into French gives

<string name="configuration_error_explaination">Votre contrôleur a signalé l'erreur de configuration suivante: <xliff: g> \ n \ n% 1 $ \ n \ n </ xliff: g> Allez dans la section Tuning, fixer le cycle de problème et la puissance de votre contrôleur.</string>

Which breaks the \n and the formatted number.

Airsaid commented 4 years ago

HI, you can update to V1.4, which adds support for the xliff:g tag.