I create a game board with squares. The size of each square (both height and width) is phone_pixel_width/number_of_squares to maximize the size of each square on the game screen depending on resolution (oh and I do not support mdpi devices, thus it does not get to small).
Now my problem is that I also write text in these squares. If I use the same font size for HVGA screens and for WVGA (hdpi-normal) screens the font gets to big on the HVGA (mdpi-normal) screen. I was thinking about being able to select font size depending on its width and could thus adapt the font size perfectly to the calculated square width.
Is there any easy way of doing this (note: I am using TextPaint and not TextView) or do I have to calculate this myself, on the fly so to speak by creating some kind of table at start-up.
Thank you :-)
/ Henrik