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

Re: CSS Viewport proposal

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Mon, 09 Aug 2010 18:10:58 +0200
To: "Rune Lillesveen" <rune@opera.com>
Cc: "www-style list" <www-style@w3.org>
Message-ID: <0o20661m4d7mtclcm4rrui508odpd8rnfp@hive.bjoern.hoehrmann.de>
* Rune Lillesveen wrote:
>If there's any interest - here's my attempt at specifying the  
>functionality of the viewport META tag in CSS syntax using an @viewport  
>block:
>
>   http://people.opera.com/rune/TR/ED-css-viewport-20100806/

CSS intentionally avoids boolean property value as you have them here
for "user-scalable". An alternative would be spelling out the relevant
effect, so one value could be "scalable".

>The proposal includes a mapping from the viewport META syntax into the  
>proposed CSS syntax.

That is some orders of magnitude more complex than it needs to be, I
for instance just spent five minutes trying to understand the split
between line 7 and line 11 until I figured out that the idea is to
parse "foo bar=baz" as if it was "foo=baz" which strikes me as a bad
idea.

I see no reason why this needs to be more complicated than splitting
at "," and then splitting the items at "=" into name and value (or no
value if there is no "="), while ignoring white space at the start,
end, and around "=" and ",". That's easier to implement and describe
and does not lead to surprising results as the one mentioned above.

(The code for this in WebKit is actually a copy of the code used to
parse window.open(...) features including a comment noting that it's
supposed to mimic Internet Explorer; so I'd rather doubt this needs
to be this complicated for reasons of compatibility.)
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de
25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Monday, 9 August 2010 16:11:35 GMT

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