When I use different layouts to support different screens , should I use dp or px .
Asked
Active
Viewed 297 times
0
-
This answer might help: http://stackoverflow.com/a/12976956/450534 – Siddharth Lele Oct 27 '12 at 09:31
2 Answers
1
dp is best because it adjust itself according to the screen size of the device.It varies from device to device but less then pixel.So, always go for dp.

Jagdeep Singh
- 1,200
- 1
- 16
- 34
1
Always use dp instead of px. There are three distinct but linked concepts to understand here: screen density (pixels per inch/centimeter, or commonly known as DPI from dots per inch in printers), physical screen size (in inches or centimeters) and number of pixels (also known as resolution, in pixels).

Community
- 1
- 1

Hardik Joshi
- 9,477
- 12
- 61
- 113