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

Re: [css-device-adapt] Accepting semi-colons as a separator for meta-viewport

From: Peter Beverloo <beverloo@google.com>
Date: Fri, 21 Oct 2011 11:40:30 +0100
Message-ID: <CALt3x6mtMiU+LTPNY2MLxemXT46UqmDNjMv0xQpyJUOE_F2Apg@mail.gmail.com>
To: Rune Lillesveen <rune@opera.com>
Cc: "Tab Atkins Jr." <jackalmage@gmail.com>, www-style@w3.org
On Fri, Oct 21, 2011 at 10:29 AM, Rune Lillesveen <rune@opera.com> wrote:
> On Thu, 20 Oct 2011 23:36:34 +0200, Tab Atkins Jr. <jackalmage@gmail.com>
> wrote:
>> On Thu, Oct 20, 2011 at 10:12 AM, Peter Beverloo <beverloo@google.com>
>> wrote:
>>> The CSS Device Adapt specification defines a parsing algorithm[1] for
>>> the meta-element viewport content, which has been based on WebKit's
>>> implementation that shipped with iOS4. This algorithm only accepts
>>> commas as separators between properties.
>>> In reality, web authors are using both commas as semi-colons. A wide
>>> range of websites, including CNN[2], Flickr[3] and Reddit[4] depend on
>>> this behavior, which has led at least Mozilla and Microsoft to
>>> implement it and, in case of the latter, write about it[5].
>>> I think the specification should adapt to reflect what authors are
>>> doing. While it's unfortunate that the divergence between commas and
>>> semi-colons happened, it's important for compatibility among mobile
>>> browsers.
>>> Thanks,
>>> Peter
>>> [1] http://dev.w3.org/csswg/css-device-adapt/#parsing-algorithm
>>> [2] http://m.cnn.com
>>> [3] http://m.flickr.com
>>> [4] http://www.reddit.com/.compact (or http://m.reddit.com/)
>>> [5]
>>> http://blogs.msdn.com/b/iemobile/archive/2010/11/22/the-ie-mobile-viewport-on-windows-phone-7.aspx
>> Agreed that we should match current behavior, whatever it is.
> There is no current behavior that matches all implementations. The current
> description matches Safari and Opera. If you add ';' as a valid separator,
> you'll probably describe Android WebKit and Fennec. I haven't analyzed those
> implementations in detail, so I don't know if there are other differences.
> The constraining procedure using the parsed values also differ, so it's not
> always easy to tell without looking at the source code.

I was specifically talking about author behavior, which at least
Mozilla and Microsoft's implementations have adapted to.

>> Hopefully by getting a single correct description of the necessary
>> parsing algorithm we can get proper interop between everyone that
>> prevents it from drifting further.
> Depends on what you mean by a single correct description since the current
> implementations are not interoperable. You have to choose between one
> describing one of the existing implementations or choose an algorithm which
> matches neither.

As usage of the semi-colon for viewport meta tags is unlikely to go
away, changing the parsing algorithm to reflect this would be a good
first step, as this would allow implementations to align themselves.

In all this, the transition towards CSS @viewport is something I
highly support, but that doesn't address the current situation.


> --
> Rune Lillesveen
> Layout Group Manager
> Core Technology Department
> Opera Software ASA

Peter Beverloo | Software Engineer | beverloo@google.com | +31-6-41000722
Received on Friday, 21 October 2011 10:41:05 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:38:51 UTC