How to make custom images appear in text

Not sure why my previous question was deleted but I was having quite a bit of trouble getting “quad” and “material” tags to work in TMP Pro, basing it on this previous question/answer about how to add icons in text.

In fact it seems as though quad and material tags don’t do anything at all in TMP Pro text, and the text always just renders those tags as literal original text instead of trying to do anything with the tags.

I was able to solve this by using the “sprite” tag via this tutorial instead of material or quad tag, and I wanted to document this in case it helps people in the future.

Unity documentation claims quad/material are supported alongside bold, italic, color etc.

What I found is while most of those tags work, including color, the “quad” and “material” don’t seem to do anything at all.

The answer is to use “sprite” tags instead of “quad” or “material”. I used this tutorial as well as an online sprite atlas maker, to create the sprite atlas.