Numbers are appearing in Arabic??

4 years 3 months ago #1820 by hengineer
In the latest version the numbers in my Hebrew build are being converted into Arabic numerals like: ٢ ٨ instead of "28"
I notice that in the code there are references to ArabicSupport.ArabicFixer in some of the generic RTL support code which might be the cause of it?

Please Log in or Create an account to join the conversation.

4 years 3 months ago #1821 by Frank
In previous versions the plugin automatically did the conversion, however, from version 2.6.8f3, I added options to avoid the RTL parsing.

By default, the plugin converts latin numbers (123..) to the arabic counter part. I realize that may not be desired, so I added a new feature to the plugin that allows ignoring sections of the text while doing the RTL fixing. Just surround the text with the tag: <ignoreRTL>....</ignoreRTL>
That could be used to ignore numbers or even texts that you want to preserve (especially for names and words in others languages)

See the screenshot preserving the "2".

Said that, adding the ignoreRTL maybe the only way to deal with Foreign Names, but its tedious to add that for every number, so I also added a new toggle in the Localize component, next to the "Max Line Length", ("Ignore Numbers)
When that is unchecked, numbers will be converted to the target language (unless surrorunded with the ignoreRTL tag), when checked, they will be preserved:

In the next release, I'm planning on making the Ignore Numbers checkbox enabled by default, as I can't think on a good case where converting to arabic is a good idea (if they weren't converted already when translating the text). That option is disabled now just because of legacy to avoid breaking projects depending on it.

Hope that helps.

Are you :-) Give I2L 5 stars!
Are you :-( Please lets us know how to improve it!
To get the betas as soon as they are ready, check this out

Please Log in or Create an account to join the conversation.

4 years 3 months ago #1822 by hengineer
This seems like a strange default.
First of all the language I'm using is Hebrew which is RTL but I'm pretty sure it never uses Eastern Arabic numerals.
Secondly, I can see how converting numbers might be useful when using an automatic translation feature (like Google translate) but why replace them in manual translations? I want my translations to appear the way the translator wrote them.

Anyway, for now I'll change the "Ignore Numbers" checkbox to be on by default. Thanks for your help.

Please Log in or Create an account to join the conversation.

Time to create page: 0.288 seconds
Template by JoomlaShine