RE: [css-device-adapt] Units

I think it would make sense to disallow these within the @viewport rule.


From: []
Sent: Sunday, October 28, 2012 6:34 AM
To: CSS WG; Christiansen, Kenneth R; Øyvind Stenhaug
Subject: RE: [css-device-adapt] Units

While we are at it, I’ve discovered an issue with CSS-Device-Adapt : there’s nothing preventing you to specify the @viewport { width } declaration in viewport units (vh,vw,vmin,vmax).

However, those units are ill-defined in the @viewport rule since the width isn’t properly computed at this time.

@viewport { width: 2vw; }

In the only browser supporting both @viewport and Viewport Units (IE10), the declaration is causing weird rounding issues for viewport units later in the document so this clearly has border-effects proving it’s not completely ignored (even if the browser didn’t enter in a loop incrementing the viewport width at each relayout operation).

To make things simpler, I propose to invalidate the use of Viewport Units in the Viewport AtRule.

De : Øyvind Stenhaug
Envoyé : ‎26‎ ‎octobre‎ ‎2012 ‎17‎:‎11
À : www-style list; Kenneth Rohde Christiansen
Objet : Re: [css-device-adapt] Units

On Wed, 24 Oct 2012 14:55:22 +0200, Kenneth Rohde Christiansen
<<>> wrote:

> On Wed, Oct 24, 2012 at 2:41 PM, Kenneth Rohde Christiansen
> <<>> wrote:
>> The iPhone >= 4, has a device dpi of 320, but a CSS DPI of 192, so
>> shouldn't that be made a bit more clear here. Also at zoom 1.0 the
>> iPhone has a width of 160px (CSS unit) due to resolution being 2dppx,
>> so at scale 0.25, it can fit a document of width 640px and not 1280px.
> I need more coffee, I see. It is exactly 320px wide (640 device
> pixels). Still it makes sense clarifying that it is a 320px wide
> screen in CSS units. Because when you talk about a device you usually
> talk about device units.

I've tweaked the text a bit now.

Øyvind Stenhaug
Core Norway, Opera Software ASA
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, 28 October 2012 23:54:23 UTC