I use Canvas.drawText () to write text on a user view. I want to add a background 9 patch for text, so I need to know the borders of the text. The text is provided by the user, so it is not fixed.
Right now I'm using a monospace font, and I managed to create a size that doesn't look so bad, but in my hand I would prefer to use a different font.
android canvas
Xgouchet
source share