[whatwg] Fullscreen revision I

Simon Pieters simonp at opera.com
Thu Oct 20 14:10:43 PDT 2011


On Thu, 20 Oct 2011 17:10:03 +0200, Glenn Maynard <glenn at zewt.org> wrote:

> The background: black makes a basic case strange: fullscreening
> <div>hello</div> will result in black text on a black background.  Maybe
> having that on video:fullscreen and maybe img:fullscreen makes sense,  
> but it
> doesn't seem right in general.
>
> Should margin: 0; padding: 0; be set by :fullscreen?
>
> The current spec doesn't seem to allow asking permission to fullscreen in
> advance, since the fullscreen element is set synchronously.  This should  
> be
> supported; there are a lot of potential problems with the ask-after model
> and it shouldn't be the only model supported.
>
> :fullscreen { width: 100%; height: 100%; } will stretch videos and  
> images to
> fit the screen, instead of doing something more sensible (letterboxing,
> pillarboxing or cropping, depending on aspect ratios and the user or  
> site's
> preference).  I'm not sure how that should work in general, but
> fullscreening a video wouldn't be as simple as video.requestFullScreen().
> (I don't recall if <video> can handle cropping and letterboxing directly;
> for example, you don't want to blindly crop a video without the video
> knowing about it, or WebVTT subtitles and native controls would get  
> cropped
> too.)

<video> already shows the video with correct aspect ratio; it has default  
style object-fit:contain. <img> would be stretched, though. We could make  
it object-fit:contain when it's the fullscreen element.

-- 
Simon Pieters
Opera Software



More information about the whatwg mailing list