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

Re: CSS Viewport proposal

From: Rune Lillesveen <rune@opera.com>
Date: Tue, 24 Aug 2010 21:50:05 +0200
To: "Kenneth Rohde Christiansen" <kenneth.christiansen@gmail.com>
Cc: "Kenneth Christiansen" <kenneth.christiansen@openbossa.org>, "www-style list" <www-style@w3.org>, "Eduardo Fleury" <eduardo.fleury@openbossa.org>
Message-ID: <op.vhyj1rrl8isf1p@id-c1005.oslo.osa>
On Tue, 17 Aug 2010 13:54:27 +0200, Kenneth Rohde Christiansen  
<kenneth.christiansen@gmail.com> wrote:

> Hi Rune,
>
> This seems wrong:
>
> 11. If the computed value of initial-scale is ‘auto’ and height is not
> ‘auto’, set initial-scale = MAX(initial-scale, (available-height /
> height))
>
> How can you do max of something that is auto.

As pointed out by Øyvind, it's defined in 6.1.

> I use the following in my code:
> appliedScale = qMax(qreal(visibleWidth) / qreal(appliedWidth),
> qreal(visibleHeight) / qreal(appliedHeight));

As long as both appliedWidth and appliedHeight are calculated at that  
point. In the spec, they might be 'auto' at the point where the  
initial-scale is resolved.

-- 
Rune Lillesveen
Senior Core Developer / Architect
Opera Software ASA
Received on Tuesday, 24 August 2010 19:50:23 GMT

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