[PATCH weston 1/3] xwm: Initialize window decoration always as !override
Bill Spitzak
spitzak at gmail.com
Mon Jul 23 12:03:41 PDT 2012
This looks like a serious problem that I don't see any workaround for.
I think the idea that clients don't know their x/y position will have to
be changed. This is incompatible with X and Windows (and I suspect with
OS/X as well) and will cause a lot of trouble trying to write portable
applications.
Kristian Høgsberg wrote:
> On Fri, Jul 20, 2012 at 11:09:53PM +0300, Tiago Vignatti wrote:
>
> I grabbed these three patches, and overall it works much better than
> before. There's still a bit too much duct-tape involved and some
> corner cases are still broken though.
>
> Mainly, the problem is that X apps look at their main window position
> relative to screen edges and pop up the menu different places
> depending on whether the popup would be clipped by a screen edge or
> not. It's pretty easy to try out: move a window towards the bottom of
> the screen and then open a menu or a combo box and see how they're
> place above the menu or combo box button. This breaks under xwayland,
> since all windows think they're sitting up in 0,0 and have plenty of
> space to pop up a menu. The only way to really fix this is to
> propagate the wayland window position into X, and set EWMH struts that
> correspond to the desktop panels in weston. And we may want to not
> use the shell.c window types, but just set up a xwm specific
> surface->configure callback instead, so we can place the windows were
> we want them instead of trying to get shell.c to do the right thing by
> guessing transient parents etc.
>
> Anyway, it all works better than before now, so lets go with this for
> now.
>
> Kristian
>
>> Signed-off-by: Tiago Vignatti <tiago.vignatti at intel.com>
>> ---
>> src/xwayland/window-manager.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/src/xwayland/window-manager.c b/src/xwayland/window-manager.c
>> index e2e2ba3..e81a229 100644
>> --- a/src/xwayland/window-manager.c
>> +++ b/src/xwayland/window-manager.c
>> @@ -324,7 +324,7 @@ weston_wm_window_read_properties(struct weston_wm_window *window)
>> props[i].atom,
>> XCB_ATOM_ANY, 0, 2048);
>>
>> - window->decorate = 1;
>> + window->decorate = !window->override_redirect;
>> for (i = 0; i < ARRAY_LENGTH(props); i++) {
>> reply = xcb_get_property_reply(wm->conn, cookie[i], NULL);
>> if (!reply)
>> --
>> 1.7.9.5
>>
>> _______________________________________________
>> wayland-devel mailing list
>> wayland-devel at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
More information about the wayland-devel
mailing list