[PATCH weston] input: don't send to clients key events eaten by bindings

Jasper St. Pierre jstpierre at mecheye.net
Wed Oct 8 15:25:30 PDT 2014


On Wed, Oct 8, 2014 at 3:23 PM, Bill Spitzak <spitzak at gmail.com> wrote:

> On 10/08/2014 11:58 AM, Giulio Camuffo wrote:
>
>  A key being held down on focus-in will not produce a "press" event, so I
>>> don't see what the problem is.
>>>
>>
>> It produces a KeyPress in xwayland.
>>
>
> Okay that may be a problem. So you are saying the client cannot
> distinguish between keys that were held down when it got the keyboard
> focus, and ones that were pressed a very short time afterwards?
>
> I was under the impression that what the client got was an xkb state that
> showed that the keys were held down. Actual events caused by pressing keys
> were different and distinguishable by the client.
>

X clients cannot distinguish between the two.


>  If a client wants to check if X is held down I think the user expects it
>>> to
>>> work even if it was held down as part of the command to switch windows.
>>> Therefore I think the current behavior is correct.
>>>
>>
>> Why would it care about that? The compositor decided that the clients
>> shouldn't know that one key was pressed, so the client's shouldn't
>> know that. If some client gets to know that it's a bug.
>> Or else you should say that key bindings should always let the events
>> pass to clients. Are you saying that?
>>
>
> No. All I want is the client to know the current state of the device,
> including the actual state of the keys. They should not see the keypress
> any more than if the key was pressed in a different client and held down
> until the focus switched to this one.
>
> The most obvious one clients want are shift keys. If I type Alt+tab to go
> to a different client and keep holding down Alt and type 'x', the client
> should act like I typed Alt+x.
>

Too bad. We cannot go back in time 40 years and redesign X11 to be how you
want it. We wouldn't be here in the first place if we could.


> Yes I know this works because the modifier bits are being treated
> differently than the key map. However I don't think that should be special.
> What happens if everybody starts treating hold-down-space as a modifier
> (this actually has some precedence in Photoshop and lots of 3D software)?
>
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>



-- 
  Jasper
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20141008/46ca379f/attachment.html>


More information about the wayland-devel mailing list