View Measurement Units in Android
In this tutorial we see Some Android Measurements such as px(Pixels)- Actual pixels or dots on the screen, in (Inches) – Physical size of the screen in inches, mm (Millimeters) – Physical size of the screen in millimeters, pt (Points) – 1/72 of an inch, dp (Density-independent Pixels) – An abstract unit that is based on the physical density of the screen. This unit is relative to a 160 dpi screen, so one dp is one pixel on a 160 dpi screen. The ratio of dp-to-pixel will change with the screen density, but not necessarily in direct proportion. “dip” and “dp” are same., sp (Scale-independent Pixels) – Similar to dp unit, but also scaled by the user’s font size preference.