W3C home > Mailing lists > Public > www-style@w3.org > March 2004

@viewport at-rule and 'title' (was Re: [css3] :viewport pseudo-class)

From: Tantek Çelik <tantek@cs.stanford.edu>
Date: Mon, 08 Mar 2004 14:21:49 -0800
To: "Anne van Kesteren (fora)" <fora@annevankesteren.nl>, <www-style@w3.org>
Message-ID: <BC7231CE.37C1F%tantek@cs.stanford.edu>

On 3/8/04 10:06 AM, "Anne van Kesteren (fora)" <fora@annevankesteren.nl>

> L. David Baron wrote:
>> What Mozilla has is a pseudo-element, ::-moz-viewport. I'm not sure how
>> a pseudo-class would work.
>> -David
> My bad, this should have been a proposal for a ::viewport pseudo-element
> in that case (the description still applies of course). I read some old
> bugzilla messages, where ':-moz-viewport' was discussed. There was not
> mentioning of pseudo-class or pseudo-element so following the CSS3
> syntax I thought it was a pseudo-class.
> I could have known, since Mozilla supports only recently the new syntax
> for pseudo-elements. And I didn't follow my own thought it should be a
> pseudo-element, since I thought there were some good reasons, you and
> Ian Hickson wanted to make it a pseudo-class :-).

Actually, this doesn't make sense as a pseudo-element either, because you
will never apply it to a particular element, unlike, say, :first-letter or
:before, both of which make sense when applied to an element like a


Where as this makes no sense:


This concept of "::viewport" is much more akin to the "@page" rule, and thus
an "@viewport" rule makes more sense.

And just as @page has the special 'size' property, we could add a special
'title' property to @viewport so that arbitrary XML documents could be
styled to present what they consider their title in the title of the window,

@viewport {
  title: "Welcome to this XML document";


@viewport {
  title: contents(root>label); /* note use of Selectors on the RHS */

for markup like:

 <label>Here is the label for this document</label>
  Here are some contents.

Just some recent thoughts...

Received on Monday, 8 March 2004 17:21:52 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:27 GMT