Hi Pancake, If you read the CSS spec carefully, you would find that on a screen, these real-world units doesn't have to be sized in the same way on a physical ruler (though on paper it should).
http://www.w3.org/TR/CSS21/syndata.html#length-units If you are looking to size an HTML element with physical size, the non-standard mozmm is the unit you are looking for -- but I am pretty sure we didn't set the Gecko pref() right on all devices for all FxOS devices. We should file bugs on that. MDN is more understandable than the spec on this topic: https://developer.mozilla.org/en-US/docs/Web/CSS/length On Thu, May 16, 2013 at 9:06 AM, pancake <[email protected]> wrote: > I've been playing a while with the simulator, keon and peak and I conclude > that there is clear way to work with that. > > If you own a Peak you will notice that almost everything looks tiny, > > What I found surprising is that the css style size : 2cm is not reliable. > Centimeters or inches looks different depending on screen. > > When running the js code to get the dpi all of them say 96. Which is not true. > > In gaia they solved the issue with a responsive.css which scales the root > font size and the rest should use rem units. > > Shouldnt b2g provide a way to get screen definition? That will make apps like > this much reliable across devices: > > http://ruler.ffos.lolcathost.org/install.html > _______________________________________________ > dev-b2g mailing list > [email protected] > https://lists.mozilla.org/listinfo/dev-b2g -- Tim Guan-tin Chien, Engineering Manager and Front-end Lead, Firefox OS, Mozilla Corp. (Taiwan) _______________________________________________ dev-b2g mailing list [email protected] https://lists.mozilla.org/listinfo/dev-b2g
