Android text size really different on 2 different "normal" screens -
I specify the size of the text like 12sp
and in the text box of 100dp
. In one case (3.2in, 320x480 mdpi) the thing looks good, in the second (Nexus 4) text is too big and it does not fit in the box
Why is it so? I thought that 'SP' was independent of the density.
dp or dive density-free pixel It is, alias, automatically enhanced on the pixel density of the device's screen.
sp is a scale-independent pixel - essentially similar to a DP, but also factor in users' font-size settings (which can change in system settings).
It may be that your other testing tool, compared to a different font-size setting in your Nexus 4,
if you do not scale with the user's font-size setting If you want, you can simply use DP as your font-size value.
Comments
Post a Comment