Re: TextTracueCue Constructor

On Sat, Aug 10, 2013 at 7:32 AM, Glenn Adams <glenn@skynav.com> wrote:
>
>
>
> On Fri, Aug 9, 2013 at 9:48 AM, Glenn Adams <glenn@skynav.com> wrote:
>>
>>
>> On Fri, Aug 9, 2013 at 8:59 AM, Victor Carbune <victor.carbune@gmail.com>
>> wrote:
>>>
>>> On Fri, Aug 9, 2013 at 12:09 PM, Silvia Pfeiffer
>>> <silviapfeiffer1@gmail.com> wrote:
>>> > On Fri, Aug 9, 2013 at 1:05 PM, Glenn Adams <glenn@skynav.com> wrote:
>>> >>
>>> >> On Thu, Aug 8, 2013 at 8:29 PM, Silvia Pfeiffer
>>> >> <silviapfeiffer1@gmail.com>
>>> >> wrote:
>>> >>> I decided to just have the regionId on VTTCue for now. This can be
>>> >>> changed if we decide in the HTML spec to also introduce regions. For
>>> >>> now it's a WebVTT-only feature.
>>> >>
>>> >>
>>> >> ok
>>> >
>>> > Admittedly, I've still got it the regions as TextTrackRegion in the VTT
>>> > spec.
>>> > http://dev.w3.org/html5/webvtt/#texttrackregion-interface
>>> > I could rename it to VTTRegion.
>>> >
>>> > What do ppl think?
>>>
>>> Renaming it to VTTRegion sounds appropriate to me, especially since it
>>> seems to remain specific to VTT.
>>
>>
>> Although it is likely that a TTMLRegion will be needed, in which case a
>> common TextTrackRegion would be desirable, we aren't quite at a point at
>> which we can concretely define the specifics of TTMLRegion.
>>
>> I would recommend defining a very light weight TextTrackRegion interface
>> now rather than later, and have VTTRegion inherit from it. The only certain
>> common property is an id, so you might consider defining regionId on
>> TextTrackRegion, and the remaining members on VTTRegion as presently
>> specified.
>
>
> I meant to say "id" rather than "regionId". Also, the back-pointer to the
> track would be useful as a common property. So I would suggest you define as
> follows:
>
>
> interface TextTrackRegion : EventTarget {
>   readonly attribute TextTrack? track;
>            attribute DOMString id;
> };
>
>
>
> [Constructor]
> interface VTTRegion : TextTrackRegion {
>            attribute double width;
>            attribute long lines;
>            attribute double regionAnchorX;
>            attribute double regionAnchorY;
>            attribute double viewportAnchorX;
>            attribute double viewportAnchorY;
>            attribute DOMString scroll;
> };


We can introduce a light-weight TextTrackRegion when it's appropriate
- as proposed here, it's pretty useless for anything but VTTRegion, so
I'll just rename TextTrackRegion to VTTRegion.

Thanks,
Silvia.

Received on Friday, 9 August 2013 23:49:24 UTC