I’m trying to use Render Text to Texture using Canvas Render 2d, and so far, I’m able to draw text, and use the resulting texture in a dynamic material instance.
However, currently, I’ve only been able to draw text to the middle of the canvas. If the text is short, it wastes space around it, and if it’s too long it will continue to flow off of the canvas, which won’t work for what I need.
Is there a way to make sure that no matter how long the entry text is, it gets stretched horizontally and vertically to fit exactly to the edges of the canvas?
A visual is attached, which hopefully helps explain it better! Left is currently what I have, right is the desired result.
Thanks if you can point me in the right direction!