KRunner Wayland issues on Qt 5.9

David Edmundson david at davidedmundson.co.uk
Thu Jul 13 09:05:20 UTC 2017


>IIRC wl_shell is not defined to be double buffered. Not sure how it's
about xdg. There is always the chance of breaking things *cough*Qt*cough*
when changing that - even if it is sane.

Xdg definitely is and for v7 this is important as mapping/unmapping is
different.

* committing a surface with empty buffer on a surface unmaps a window

* commiting again (still with an empty buffer) tells the compositor we're
going to send a configure event because we're about to remap the window

which means we need to be at least be tracking the wl_surface changes even
if we don't properly double buffer.

>From a Kwin POV, it'd be best to deal with this on the kwayland side as we
need to reset the xdg_toplevel state.

Personally I think deleting the xdgshellsurface in Qt is a lot less messy
than the new XDG.  The only thing that doesn't make sense is deleting the
wl_surface.

I wrote a patch that does that. https://paste.kde.org/pgh8jafqw

That works fine for XDG, but wl-shellsurface doesn't like that and remains
until you delete the wl_surface. wl_shell_surface_destroy literally sends
nothing in wayland_debug.

I think that's why they end up deleting both. It's not a simple thing to
abstract when everything behaves so differently.


> What could be an idea is to not do anything in KWin till we get the first
> map event. That is evaluate all the shell options only on map.
>
>
>> In practice that won't acheive anything as QWaylandWindow::initWindow
>> calls commit a few times randomly before the expose event that we're
>> currently hooking into is called. Also kwayland-integration calls
>> commit on the surface every time it attaches something, which I don't
>> think is right.
>>
>
> It is fine given the definition of the interfaces. We setup some state and
> commit it. If we don't commit we don't know when that will happen. We only
> adjusted our own relevant states and everything else is not affected.
>

That would be true if we weren't using these in hooks in the middle of Qt
adjusting things. Maybe avoiding that is the right fix though.

----

FWIW I'm meeting Jonas (the XDGShell and scaling guy) in two weeks at
Guadec.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20170713/d2cce062/attachment.html>


More information about the Plasma-devel mailing list