[Bug 22075] possibility to shrink the rendering area for timed text (webvtt) using CSS

https://www.w3.org/Bugs/Public/show_bug.cgi?id=22075

--- Comment #3 from Alexander Farkas <alexander.farkas@aperto.de> ---
Nice to see, that this problem is already worked on. 

Defining multiple "reserved" areas seems better and is more powerful than my
proposal.

Two short comings about the Viewport interface:

1. The coordinates are in percentages of the video's rendering area.
In most cases control-bars, logos and control-buttons are defined using pixels.
Reserving an area in percentages doesn't work for them.

2. They are defined using JS
The main thing here, is that a video script solution can have many different
theme packages (CSS). It doesn't feel right, that the author has to provide
additional JS to make his style theme work. 


About my proposal:

This was just a hasty reaction to the problem, but I think it's not only easy,
but is the right solution for the discussed usecases.

For 99% of all usecases, we only need to reserve the edges of the video
rendering area. Top/Left logo, bottom control-bar and sometimes right edge for
some additional control-buttons.

Even if we reserve to much space for a logo (whole top or whole left area), it
doesn't really hurt.

We could define the ::cuedisplay takes the following CSS-Styles and author can
change those:

::cuedisplay {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
}

This way, we can define reserved edges in all units (px, em, % etc.) and have
full control in our stylesheet.


In case you want to keep a Viewport.reserve function here, it would be
interesting, that you can also pass a DOM-Object and the browsers keeps track
of the dimension of this DOM object. In this case a player script can reserve
the space in general and doesn't need to be changed, in case the player gets a
new theme or is changing to fullscreen (for other control styles, in that
case).

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Wednesday, 22 May 2013 09:35:49 UTC