Re: CSS Timed Text Module

On Sun, Jul 24, 2011 at 2:28 PM, Anne van Kesteren <annevk@opera.com> wrote:
> HTML has a section where it defines various features for styling captioning.
> It proposes a ::cue pseudo-element, ::cue(selector) pseudo-lement, :past
> pseudo-class, and a :future pseudo-class.
>
> http://www.w3.org/TR/2011/WD-html5-20110525/rendering.html#timed-text-tracks-0
> http://www.whatwg.org/html#timed-text-tracks-0
>
> At some point the CSS WG should probably "own" these features and issue a
> draft for them.

:past and :future are pretty easy and well-named.  It can be used for
things other than WebVTT that have a time-dependence.

::cue() is more interesting.  The captions on a video are basically an
embedded document, similar to <iframe>, that are not normally
accessible to the outer page's selectors.  ::cue() pokes a hole in
that, allowing the outer document to select and style the elements in
the embedded document.  This is potentially applicable more widely;
I'm not sure we'd *want* it to, though. ^_^

::cue is just a shortcut for ::cue(), which is defined as selecting
the root elements.  (WebVTT documents usually have many root elements
- each cue is one.)

~TJ

Received on Sunday, 24 July 2011 22:02:36 UTC