W3C home > Mailing lists > Public > www-dom@w3.org > January to March 2002

pseudoElt argument to getComputedStyle()

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Mon, 25 Feb 2002 21:05:40 -0500
Message-Id: <200202260205.VAA26387@pedagogue.mit.edu>
To: www-dom@w3.org, www-style@w3.org
Cc: caillon@returnzero.com
The second argument to getComputedStyle() is defined as:

pseudoElt of type DOMString 
   The pseudo-element or null if none.

This seems to me to be very much under-specified.

For example, is "first-letter" an acceptable value of "pseudoElt"?  What
about ":first-letter"?  What about "::first-letter"?

Presumably ":selection" would be invalid, but what about "selection" or

It seems to me that in this context the string is unambiguously a
pseudo-element, so "first-letter", ":first-letter", "::first-letter",
"selection", "::selection" should all be allowed and do the right thing,
while ":selection" should not have any effect (be treated as "" or null).


We are all agreed that your theory is crazy.  The
question which divides us is whether it is crazy enough
to have a chance of being correct.  My own feeling is
that it is not crazy enough.
                                     -- Niels Bohr
Received on Monday, 25 February 2002 21:05:56 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:50:32 UTC