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

Re: [css3-speech] :media-overlay-active

From: Daniel Weck <daniel.weck@gmail.com>
Date: Thu, 9 Jun 2011 10:41:07 +0100
Cc: Marisa DeMeglio <marisa.demeglio@gmail.com>, Gylling Markus <markus.gylling@gmail.com>, Fabien Cazenave <fabien.cazenave@inria.fr>
Message-Id: <CB500AFB-2BE3-4426-8658-2040EDEAE99C@gmail.com>
To: fantasai <fantasai.lists@inkedblade.net>, www-style list <www-style@w3.org>

I should point out that the problem we are trying to solve with "-epub- 
media-overlay-active" (or such like) is not related to speech  
synthesis. It is a more general issue that ties into synchronized  
multimedia. Keyframe-based (video) text/sign-language synchronization  
is another application, for example.

Note that HTML5 "Timed text tracks" specify [1] the ::cue pseudo- 
element as well as :past and :future pseudo-classes, but these are  
specific to the WebVTT captioning format, so they do not translate  
well to document-wide "activation" in the non-linear SMIL / Timesheet  

I have just recently proposed [2] an alternative solution for EPUB3  
Media Overlays, inspired by an experimental SMIL Timesheets  
implementation which effectively solves the problem of style  
discoverability for "active" elements. It is based on regular author- 
defined CSS classes (i.e. the EPUB3 standard wouldn't have to reserve  
any particular class name, nor would it have to rely on a custom  

Now, just a summary to save you reading the EPUB discussions:

At this relatively late stage in the EPUB3 specification process, some  
major implementors / stakeholders in the EPUB working group are  
failing to reach a consensus on the CSS pseudo-class vs reserved-class- 
name issue. This is a sign that this EPUB3 feature (i.e. author- 
provided styling for synchronized text/audio playback activation) is  
at risk of being deferred to an ulterior revision of the standard.

Should this turn out to be the case, reading system implementors would  
likely adopt their own method / extension to EPUB3, and in the case of  
Apple iBooks this would consist in a reserved CSS class name (judging  
by their position in the discussion thread). Note that other  
implementors (and content producers) might actually be perfectly  
contempt with default user-agent styles (which would be overridable by  
users, but not by authors). The ones in favor of a CSS pseudo-class  
would have to either modify the core (browser) rendering engine to  
support it, or would have to adapt the stylesheets at pre-processing  
time (perhaps with a SASS-like structured approach, or with brute- 
force regular expressions text replacements).

Those of us who object against a reserved class name are primarily  
concerned about setting a widespread precedent based on a "magic  
string", which is admittedly a broken approach. A solution similar to  
the existing  CSS ":active" pseudo-class is not only more elegant, it  
is also architecturally more sound (albeit at the cost of  
implementation complexity / feasibility).

Anyway, I am now awaiting feedback regarding the alternative proposal,  
which relies on neither a custom pseudo-class, nor a reserved class  

Regards, Dan



On 9 Jun 2011, at 06:12, fantasai wrote:

> The EPUB3 spec includes the definition for a pseudo-class to select  
> elements
> that are active during speech playback:
>  http://epub-revision.googlecode.com/svn-history/trunk/build/30/spec/epub30-mediaoverlays.html#sec-docs-assoc-style
> There's some ongoing discussion in the EPUBWG about prefixing the  
> pseudo-class
> name or using a reserved class name instead of a pseudo-class, etc.
>  http://groups.google.com/group/epub-working-group/browse_thread/thread/1eba33a3b544b6e2
> Their spec's a little underdefined, imo, but I thought such a pseudo- 
> element would
> be something for the CSSWG to consider, particularly as an addition  
> to CSS3 Speech.
> The state should propagate up to ancestors, so that you can choose,  
> for example,
>  p:media-overlay-active { outline: solid yellow; } /* ugly example  
> for demo purposes */
> I'd suggest coming up with a less awkward name, though. :)  
> (Maybe :playback-active?)
> ~fantasai
Received on Thursday, 9 June 2011 09:41:38 UTC

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