W3C home > Mailing lists > Public > www-style@w3.org > October 2010

Re: [css-device-adaptation] New draft

From: Kenneth Rohde Christiansen <kenneth.christiansen@gmail.com>
Date: Tue, 19 Oct 2010 10:28:36 -0300
Message-ID: <AANLkTim7n2q44yAQg2Jp23rTzfVakrsbov8YY_5Dy3oF@mail.gmail.com>
To: Rune Lillesveen <rune@opera.com>
Cc: www-style@w3.org
I think the most important is that you might want to import another css
style when the device has a higher dpi, and keep zoom at 1.0.

It is more a legacy thing, as most mobile web app widgets are developed with
the iPhone in mind, and they thus become too small on a device with a higher
DPI. People have worked around with that by adjusting the zoom factor
(multiplying with a dpi factor) and the targetDensityDpi was introduced so
that sites could actually make use of the better dpi and ignore the dpi
adjustment factor.

Kenneth

On Tue, Oct 19, 2010 at 8:10 AM, Rune Lillesveen <rune@opera.com> wrote:

> On Mon, 18 Oct 2010 22:02:55 +0200, Kenneth Rohde Christiansen <
> kenneth.christiansen@gmail.com> wrote:
>
>
>>>
>>> Apple's proposals, bring some information for zoom and magnification into
>>> the scripting environment.
>>> window.devicePixelRatio and device-pixel-ratio selectors are quite handy,
>>>  target-densityDpi is a useful addition,
>>> but not supported by Apple (afaik).
>>>
>>
>>
>> The targetDensityDpi is half supported in WebKit trunk now, so when Apple
>> ports the iOS port to use WebKit2, this should be supported automatically.
>> We will also support this for Qt WebKit.
>>
>
> Could dpi values for zoom be an acceptable replacement for
> target-densityDpi?
>
> Examples:
>
>  /* Set the zoom factor so that there is a 1-1 relationship between
> physical and CSS pixels */
>  @viewport {
>    zoom: device-dpi
>  }
>
>
>  /* Set the zoom factor so that there are 160 CSS pixels per inch. */
>  @viewport {
>    zoom: 160dpi
>  }
>
>
> You would lose the possibility to do something like this:
>
>  /* Set zoom factor so that a CSS pixel is rendered as 2x2 physical pixels
> with a viewport width of 500px. */
>  @viewport {
>    target-densityDpi: device-dpi;
>    zoom: 2;
>    width: 500px;
>  }
>
>
> Are there important use cases for combinations of target-densityDpi and
> zoom?
>
>
> --
> Rune Lillesveen
> Senior Core Developer / Architect
> Opera Software ASA
>
>


-- 
Kenneth Rohde Christiansen
Senior Engineer
Nokia Danmark A/S
Phone  +55 81 8895 6002 / E-mail kenneth.christiansen at gmail.com

http://codeposts.blogspot.com ﹆﹆﹆
Received on Tuesday, 19 October 2010 13:29:33 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:33 GMT