On showing windows where the users want them, on wayland
David Edmundson
david at davidedmundson.co.uk
Tue Apr 14 12:55:46 BST 2020
On Tue, Apr 14, 2020 at 12:37 PM Aleix Pol <aleixpol at kde.org> wrote:
>
> On Tue, Apr 14, 2020 at 11:54 AM David Edmundson
> <david at davidedmundson.co.uk> wrote:
> >
> > It depends on whether someone needs to recreate xeyes!
> >
> > >- make Qt report the screen where the current cursor is the primary
> > one,
> >
> > QScreen constantly changing would make plasma panels move, we don't want to expose cursor pos that way.
> >
> > >- include in the KWayland::Client::PlasmaShell a way to report the
> > screen (e.g. the edid or another identifier) with the current cursor.
> >
> > We would probably use a wl_output ID as an arg.
> >
> > Being in PlasmaShell is also potentially problematic.
> >
> > You need this information before we show.
> > We don't have a wl_surface after the first hide() before the second show(), which means we can't have a plasmashell.
> >
> > It might be doable still, but that order needs thinking about before making protocol mods.
>
> Was talking about org_kde_plasma_shell rather than org_kde_plasma_shell_surface.
That works.
> > -----
> >
> > From a "pure wayland" POV, this approach is backwards - the client should be specifying the position semantically then kwin would do its thing.
> > We have the client doing things in absolute positions to have a nice client migration path from X. I hope to be changing that for KF6.
>
> Would you suggest having a property clients can enable so they get
> assigned to the cursor's screen upon show()? Works for me too.
>
I was referring to
zwlr_layer_shell_v1.get_layer_surface with NULL as the wl_output
it's defined as
"You may pass NULL for output to allow the compositor to decide which
output to use. Generally this will be the one that the user most
recently interacted with."
Layer shell means we don't say "position x=800, y=0", but
layer.set_anchor(Top) and it'll be magic
> I don't see how KF6 will change anything there.
Use of layer_shell means API changes for the positioning, changes to
how plasmashell stores it's configs for panels as well as (possibly)
Qt changes, so we can do the first buffer commit only when our shell
surface is configured.
> Aleix
More information about the kwin
mailing list