Re: [css3-mediaqueries] (min-resolution: 0dpi) is false in several browsers.

On Sun, Oct 21, 2012 at 2:02 PM, Simon Sapin <simon.sapin@kozea.fr> wrote:
> Le 21/10/2012 13:42, Kenneth Rohde Christiansen a écrit :
>
>> +    // According to spec, (resolution) will evaluate to true if
>> (resolution:x)
>> +    // will evaluate to true for a value x other than zero or zero
>> followed by
>> +    // a valid unit identifier (i.e., other than 0, 0dpi, 0dpcm, or
>> 0dppx.).
>> +    //
>> +    // This is actually always the case with the dppx, which we ignore as
>> it is
>> +    // a special-case in the sense it can be out of sync with dpi and
>> dpcm. For
>> +    // instance, both a device with 96dpi and 160dpi can have a dppx of
>> 1.
>
>
> This is not the case. 1dppx is defined as exactly 96dpi, as noted in
> css3-values:
>
> http://dev.w3.org/csswg/css3-values/#resolution
>
> 160dpi is about 1.666dppx

Then that is very different from the device-pixel-ratio it is supposed
to replace, as device-pixel-ratio: 1 on iOS etc corresponds to a DPI
of 160, and 2 to a DPI of the double.

Kenneth

---------------------------------------------------------------------
Intel Denmark Aps
Langelinie Alle 35, DK-2100 Copenhagen
CVR No. 76716919

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.

Received on Sunday, 21 October 2012 12:06:52 UTC