Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question Text styling

Discussion in 'UI Toolkit' started by stassius, Oct 2, 2022.

  1. stassius

    stassius

    Joined:
    May 5, 2017
    Posts:
    15
    Hello! I have a long text in the Label. And I want parts of it to be styled.
    I already figured out that some rich text tags like <i> and <b> work. <color=green> works, but <color=grey> doesn't.
    1. Where can I find the full list of supported tags?
    2. How can I apply a particular style from USS to a part of the text?
     
  2. HugoBD-Unity

    HugoBD-Unity

    Unity Technologies

    Joined:
    May 14, 2018
    Posts:
    492
    Hi @stassius!

    We've recently released new documentation for how text works in UITK.

    1. Here's our current doc on Rich Text Tags. Keep in mind it's still a work in progress, and some tags are missing.
    2. We currently don't support styling sections of the text with USS. It's part of our long-term plan, though. In the meantime, you can create custom tags using the Text Style Sheets.

    Let us know if you have feedback on the documentation. We are continuously looking to improve it.