Stack Overflow archive
1 score

In Photoshop file font size is 20px what sp will be for this in android? Is its same? means 20px= 20sp or something else?

score
1
question views
17.8K
license
CC BY-SA 3.0

They are different and you should be using sp and not px. Please see this stackoverflow post

sp

Scale-independent Pixels - this is like the dp unit, but it is also scaled by the user's font size preference. It is recommend you use this unit when specifying font sizes, so they will be adjusted for both the screen density and user's preference.

This tool is handy for converting px to sp or dp: http://pixplicity.com/dp-px-converter/

Originally posted on Stack Overflow. Public user contributions are licensed under Creative Commons Attribution-ShareAlike.