Bug 93092
Summary: | add support for ::cue | ||
---|---|---|---|
Product: | WebKit | Reporter: | geoff_freed |
Component: | Media | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED WORKSFORME | ||
Severity: | Normal | CC: | eric.carlson, silviapf |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | All | ||
OS: | All | ||
URL: | http://ncamftp.wgbh.org/test/track/ |
geoff_freed
In your WebVTT implementation, please add support for the ::cue pseudo element as specified at http://dev.w3.org/html5/webvtt/#the-'::cue'-pseudo-element . This will allow authors to use CSS to style captions and subtitles that are displayed through the <track> element.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Silvia Pfeiffer
This works just fine, e.g.
<style>
video::cue {color: lime;}
video::cue(#\31\ first\ cue) {background-color: blue;}
video::cue(v[voice="Tay Zonday"]) {color: red !important;}
video::cue(:past) {color: lime;}
video::cue(:future) {color: gray;}
video::cue(c.brown) {color:brown; background-color: white;}
</style>
On a file such as:
WEBVTT
1 first cue
00:00:10.000 --> 00:00:21.710
<v Tay Zonday>Chocolate Rain</v>
2
00:00:12.210 --> 00:00:21.710
<b>Some </b><i>stay </i><u>dry </u><c>and </c>others feel the pain
3
00:00:15.920 --> 00:00:21.170
<c.brown>Chocolate </c><u>Rain</u>
4
00:00:18.000 --> 00:00:21.170
<00:00:18.250><c>A </c><00:00:18.500><c>baby </c><00:00:19.000><c>born </c><00:00:19.250><c>will </c><00:00:19.500><c>die </c><00:00:19.750><c>before </c><00:00:20.500><c>the </c><00:00:20.750><c>sin</c>
6
00:00:21.180 --> 00:00:23.000
<00:00:21.200><c>Chocolate </c><00:00:21.500><c>Rain</c>
See: http://html5videoguide.net/NEW/CH4/code_c4_14.html
Eric Carlson
I lost track of this bug. the ::cue pseudo element was added in r137955 for bug 10419