Re: [screen-orient] why not provide at CSSOM API to CSS Device Adaptation instead?

In order for CSS Device Adaptation and Fullscreen to work better
together and work with orientation lock in fullscreen mode, I suggest
(idea by Rune) we extend the view-mode media feature with the
following syntax

@media all and (view-mode: fullscreen(#element1)) {
    @viewport {
        orientation: portrait;
    }
}

@media all and (view-mode: fullscreen(#element2)) {
    @viewport {
        orientation: landscape;
    }
}

This way a page can have multiple fullscreen enabled elements which
each their viewport configuration which will be applied when they
enter fullscreen.

Cheers
Kenneth

On Thu, Jun 6, 2013 at 11:04 AM, Kenneth Rohde Christiansen
<kenneth.christiansen@gmail.com> wrote:
> As I understand it, the CSS specs never refer to device pixels, but
> always to CSS pixels which are basically your DIPs, so the confusion
> only arises from the fact that browsers did DPI adjustment (upscaled
> the content to use real CSS values in CSS units - aka DIPs) but forgot
> to do it for everything.
>
> As Apple did the upscaling in their core system/toolkit, everything
> stayed in CSS units from day one, where as other browsers such as
> Android and Qt (Nokia N9) did the upscaling in the browser itself and
> forgot to adjust all web facing values.
>
> Kenneth
>
> On Wed, Jun 5, 2013 at 4:34 PM, John Mellor <johnme@chromium.org> wrote:
>> Sounds reasonable. I think the main things that are missing are explanations
>> of the knock-on effects of Device Adaptation (and the meta viewport tag).
>>
>> For example the CSSOM View module claims that all its dimensions are in CSS
>> pixels. But if you look at what mobile browsers return for something like
>> screen.width, they either return Device Independent Pixels (DIPs) or
>> physical device pixels. It's only for things like window.innerWidth that
>> mobile browsers actually return a value in CSS pixels. Now, returning DIPs
>> does in fact best match the intent of the spec for screen.width (indeed the
>> definition of a CSS pixel is actually the definition of a DIP, and they used
>> to be the same thing until pinch zoom and viewports made them scale
>> independently); but the CSS specs need to accept that there are more kinds
>> of pixels than there used to be, and fix these ambiguities, if we want
>> mobile browsers to converge on a single behaviour.
>>
>>
>> On Wed, Jun 5, 2013 at 2:59 PM, Kenneth Rohde Christiansen
>> <kenneth.christiansen@gmail.com> wrote:
>>>
>>> I think it should be. You think anything is missing?
>>>
>>> Kenneth
>>>
>>>
>>> On Wed, Jun 5, 2013 at 3:51 PM, Simon Pieters <simonp@opera.com> wrote:
>>>>
>>>> On Wed, 24 Apr 2013 13:00:48 +0200, Kenneth Rohde Christiansen
>>>> <kenneth.r.christiansen@intel.com> wrote:
>>>>
>>>>> I support adding some CSSOM API's for CSS Device Adaptation, but I would
>>>>> not do so for the viewport meta tag, which has its share of issues.
>>>>
>>>>
>>>> There's currently
>>>> http://dev.w3.org/csswg/css-device-adapt/#dom-interfaces
>>>>
>>>> Is that sufficient?
>>>>
>>>> --
>>>> Simon Pieters
>>>> Opera Software
>>>>
>>>
>>>
>>>
>>> --
>>> Kenneth Rohde Christiansen
>>> Senior Engineer, WebKit, Qt, EFL
>>> Phone  +45 4294 9458 / E-mail kenneth at webkit.org
>>>
>>> ﹆﹆﹆
>>
>>
>
>
>
> --
> Kenneth Rohde Christiansen
> Senior Engineer, WebKit, Qt, EFL
> Phone  +45 4294 9458 / E-mail kenneth at webkit.org
>
> ﹆﹆﹆



-- 
Kenneth Rohde Christiansen
Senior Engineer, WebKit, Qt, EFL
Phone  +45 4294 9458 / E-mail kenneth at webkit.org

﹆﹆﹆

Received on Thursday, 6 June 2013 10:09:56 UTC