I've got a situation where I have to modify some legacy code that uses 
dimensions in inches to use dimensions in dip.

Essentially this has come about because some of the newer high density 
screens (like the Atrix) do not handle their scaling properly and their inch 
values come out half what they should be. e.g. 1in should be scaling x2 for 
xhdpi but is not.

Rather than simply add a second dimen.xml for xhdpi I want to convert those 
inch dimens to dp dimens to make later maintenance easier.

However i'm trying to avoid simply logging all the dimens after onmeasure 
but I'm not sure what the formula should be to convert them.

Can anyone tell me what the formula would be to convert device inches to dp?

- Brill Pappin

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to