Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Feature Request Add justify to -unity-text-align

Discussion in 'UI Toolkit' started by curtispelissier, Jan 2, 2023.

  1. curtispelissier

    curtispelissier

    Joined:
    Jul 26, 2019
    Posts:
    39
    Hello,

    I found that the text align propery does not include the "justify" option like CSS does.

    upload_2023-1-2_16-15-56.png

    It is only possible by adding the tag `<align="justified">[...]</align>` in every texts that require it. This is really heavy to do that because, combining that to localizations, I need to go after every single text, localize it and by the same time adding the tag manually (by script or in the translation entry itself).

    Please, will it be possible to add this option? It is the exact same problem than `text-transform`, UI Toolkit allows to uppercase or lowercase texts by tags only.
     
    vejab, oscarAbraham and ontrigger like this.
  2. vejab

    vejab

    Joined:
    Dec 21, 2021
    Posts:
    85
    I totally need this as well. In every game I play, there are dialogues, tool-tips or descriptions that are written with justified texts. Yet, unity doesn't support this, it's really weird.
    I use the tag '<align="justified">' but its implementation is wrong. Instead of spacing out words like in HTML or libreoffice and probably everywhere else, Unity puts a space between each characters making the text very ugly and hard to read. :(
     
  3. joseGuate97

    joseGuate97

    Joined:
    Mar 1, 2018
    Posts:
    55
    Pumping this post. I'd like to have this option too. I am surprised this is not supported.

    P.S. Overall, UI Toolkit has worked great so far on our project! Much better and more productive than the old UI system.
     
  4. vejab

    vejab

    Joined:
    Dec 21, 2021
    Posts:
    85
    This has been fixed btw : https://issuetracker.unity3d.com/is...too-big-when-using-align-equals-justified-tag