Draw on canvas on different screen resolutions and densities

2.1k views Asked by At

I have the following situation: I want to draw an rectangle on a canvas and inside the rectangle a text of a certain size. How can I make the rectangle have 1/4 width of the screen on all screen sizes, and how can I know what setTextSize to give to the inside text in order to not exceed the rectangle boundaries ? I have read http://developer.android.com/guide/practices/screens_support.html but I'm not fully clear with the concepts.

0

There are 0 answers