RTL Arabic problems with rich text

8 months 1 day ago #4030 by nzgreg
hey Frank,

we're having problems with RTL / Arabic and rich text. It looks like rich text is being reversed when it shouldn't before being applied to a Text Mesh Pro field. We're seeing problems with normal data that has been imported via csv, and trying to use things like prefixes, eg. adding a <sprite name="xxx"> in a prefix doesn't work.

Are you aware of problems like this with the current version v2.8.13f2 and are any fixes being worked on? We've been trying to swap the character ordering depending on LocalizationManager.IsRight2Left etc. but it's whack-a-mole, one problem gets fixed and just shifts problems to another method further down the chain.

Thanks for any info.


// greg

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

7 months 3 weeks ago - 7 months 3 weeks ago #4039 by nzgreg
Update: We have tested replacing the I2 Arabic fixer (looks like it was based on https://github.com/Konash/arabic-support-unity ) with methods from https://github.com/mnarimani/RTLTMPro .

The glyphs have slightly better rendering in some cases, some things like text containing paragraphs with \n etc. render in the expected order instead of being fully reversed, and some rich text is preserved instead of being reversed in body copy.

We also added some fixes for using rich text in prefixes and suffixes in the Localize component.

We are still hitting some strange errors like the first time a scene is entered the TextMesh Pro fields are changing from left-aligned to right-aligned in Arabic as expected, but the next time the scene is entered they do not change alignment. I think we are probably hitting an Awake/Start race somewhere with the language selection and I2 checking the language and saving/updating the original and intended alignment of textfields.
Last edit: 7 months 3 weeks ago by nzgreg. Reason: working around spam protection

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

Time to create page: 1.115 seconds
Template by JoomlaShine