Label with Color Background

I need label which can have different background colors for each character. It seems that the default UI Text does not support it. My idea is to use a custom procedural mesh with quads aligned behind each character. I will fill those quads with color to achieve the effect I am after. Is this the correct approach?

add an image first for the background, then add the text as a child of the image gameobject.