I know we have measureText
in canvas and get the width of any string. Sometimes, before I render a text on a canvas, I need to know where overflow occurs. I think I can do that with multiple calls of measureText
. But it doesn't look efficient.
If there's a built-in method like measureText
for what I'm asking(even draft only for now), that would be the best.
If there isn't, what is the common practice for this problem?