Reputation: 31871
Is there some way to get the real screen-size or DPI of the device? I have certain elements in my application which are not usable if the display is too small and need to switch to a different presentation and/or omit the elements.
Upvotes: 3
Views: 665
Reputation: 7316
Short answer: No. There's (currently) no way to accurately design for the web using physical units.
Longer answer: you can only try to rely on the size of a "CSS Pixel" being roughly the same between devices, since device manufacturers have a vested interest in preserving the usability of sites when they have "high" pixel densities (~> 90 dpi).
A couple of notable exceptions:
Upvotes: 1