W3C home > Mailing lists > Public > www-style@w3.org > October 2012

Re: position: pointer

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 8 Oct 2012 14:30:35 -0700
Message-ID: <CAAWBYDDtH+78XVrQBbHq3ci07LXkYjcKvzK+F0LcCQGoLzmsDA@mail.gmail.com>
To: Simon Fraser <smfr@me.com>
Cc: Jussi Kalliokoski <jussi.kalliokoski@gmail.com>, www-style@w3.org
On Mon, Oct 8, 2012 at 2:16 PM, Simon Fraser <smfr@me.com> wrote:
> On Oct 8, 2012, at 1:50 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
>> On Mon, Oct 8, 2012 at 1:40 PM, Simon Fraser <smfr@me.com> wrote:
>>> video {
>>>  position: pointer;
>>> }
>>>
>>> What should happen? Or
>>>
>>> html {
>>>  position: pointer;
>>> }
>>
>> I don't understand the point of your questions.  Both are extremely
>> simple.  It's identical to setting "position:absolute" and setting
>> top/left to the position of the pointer, assuming that their
>> positioning roots are the ICB.
>
> There's a difference between this and CSS cursors; CSS cursors can project outside of the window (though I suppose the UA usually resets the cursor when the mouse leaves the window, though I'm not sure if it's required to).
>
> On the other hand, elements with position:pointer could not be rendered outside the viewport. It's really a different beast to a cursor.

Ah, I didn't think about that.  You're right, the cursor would project
outside the window, while the element slaved to it would just be
clipped by the window edge.

Ideally, this would be paired with something like "position-contain:
window;", so you could just specify that the position is tweaked to
remain visible in the window when it gets near the edge.

> Also:
>
> div {
>   position: pointer;
> }
>
> div:hover {
>   position: static;
> }
>
> (though we have this issue with other properties too).

Yeah, we're already biting the bullet with the interaction of :hover
and anything that manipulates layout.  Assuming implementations have a
consistent answer to this, they should just continue their current
behavior.  (However, separately from this proposal, we should really
work out what the required behavior is and specify it.)

~TJ
Received on Monday, 8 October 2012 21:31:22 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:21:01 GMT