Search Unity

TextMesh Pro TextMesh Pro issue when using Font Asset Creator to create an atlas with emoji from a text file

Discussion in 'UGUI & TextMesh Pro' started by lucianv, Oct 10, 2018.

  1. lucianv

    lucianv

    Joined:
    Oct 7, 2014
    Posts:
    5
    I am having an issue when trying to create a font atlas with emoji from a text file.
    When putting an emoji () in a text file and trying to use the text file as a source for the atlas, TextMesh Pro is reporting 2 missing characters - the surrogate pair D83D, DE00 and nothing is added to the atlas.
    Using the hexadecimal value (1F600) and Unicode range as source, works fine, and the emoji is added to the atlas.
    Also using a text file saved as UTF32 as a source doesn't seem to work in TextMesh Pro.
    Is this case supported by TextMesh Pro, using characters in a text file that have their unicode value larger than FFFF?

    I am using the latest version of TextMesh Pro from the asset store (1.2.2) in Unity 2017.4.10f1 on a Mac OS High Sierra.
    The font used is the emojione-svg.otf from here: https://github.com/emojione/emojione/tree/master/extras/fonts#emojione-svg-based-color-fonts

    Thanks
     
  2. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,595
    I'll take a look at the text file feature to make sure it properly handles surrogate pairs.

    In terms of UTF32, C# strings only support 16bit characters so no UTF32 there for us. Stuck with surrogate pairs for a while.
     
  3. lucianv

    lucianv

    Joined:
    Oct 7, 2014
    Posts:
    5
    Any updates on this issue?
     
  4. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,595
    On my list of features to improve / add.

    I am getting ready for Unite in LA next week so I won't get to look into this until I am back. Having said that, I think you'll be interested what I'll be showing at Unite next week.
     
  5. lucianv

    lucianv

    Joined:
    Oct 7, 2014
    Posts:
    5
    Thanks for your reply. I'll be watching unity's youtube channel and blog for Unite LA next week.