Search Unity

TextMesh Pro Problem with RTL language (Persian) - Text flow going up instead of going down

Discussion in 'UGUI & TextMesh Pro' started by intellime, Mar 18, 2018.

  1. intellime

    intellime

    Joined:
    Mar 18, 2018
    Posts:
    14
    Hi everyone,

    My problem is weird.
    I created my Font Asset using Font Asset Creator to support my Persian Unicode chars.
    At run time I process the string using RtlFix method of UPersian asset and then give it to TMP UGUI.

    Everything goes well until I input a multi-line text.
    Every word in each line is located correctly and the flow of text is ok in each line. but the first line of the text is located at the lowest part of the textbox and the last line located at the top!!!!
    upload_2018-3-18_20-17-42.png

    Do you have any idea why this happen and how I can fix it?

    Thanks
     
  2. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,595
    Can you provide me with the exact text that I can copy / paste to test this?
     
  3. intellime

    intellime

    Joined:
    Mar 18, 2018
    Posts:
    14
    Sorry dear Stephan for the late reply,
    It is our traditional NOWRUZ holidays so Happy NOWRUZ, everyone!

    The correct shape and flow of the same text in the Word (.docx) is as following picture:
    upload_2018-3-27_12-30-8.png
    The files containing the same text as above in .txt and .docx format is attached.

    Thanks
     

    Attached Files:

  4. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,595
    Thank you for providing the source text. I'll try taking a look today or something tomorrow.
     
  5. intellime

    intellime

    Joined:
    Mar 18, 2018
    Posts:
    14
    Thank you so much dear Stephan!
    I wish you came back with good news. :)
     
  6. intellime

    intellime

    Joined:
    Mar 18, 2018
    Posts:
    14
    codestage and Stephan_B like this.
  7. flors93

    flors93

    Joined:
    Dec 8, 2015
    Posts:
    1

    Hi!
    It is happening the same thing to me, and as the link is broken.. can you share what was the solution?
    Thank you
     
  8. unity_YtoxEhc4Yp4SSw

    unity_YtoxEhc4Yp4SSw

    Joined:
    Mar 1, 2019
    Posts:
    8
    Hi Stephan_B, can you share what was the solution?
     
  9. ESI_GameStudio

    ESI_GameStudio

    Joined:
    May 27, 2020
    Posts:
    3
    Just set "Line spacing" to -1.