[Wayland-bugs] [Bug 771561] Epiphany application mode on Wayland broken with WebKit 2.13.92

gtk+ (GNOME Bugzilla) bugzilla at gnome.org
Mon Sep 19 13:03:56 UTC 2016


https://bugzilla.gnome.org/show_bug.cgi?id=771561

--- Comment #11 from Olivier Fourdan <ofourdan at redhat.com> ---
Created attachment 335854
  --> https://bugzilla.gnome.org/attachment.cgi?id=335854&action=edit
Simple reproducer

Ok, trying to root cause this issue, I think I know what's going on...

Long story short, the toplevel epiphany window is switching to maximized state
while realizing the window meaning that the shadows are 0, but the backend is
not yet aware. That is definitely not a bug in epiphany, nor in gdk Wayland
backend, but rather in gtk itself (ie higher in the stack)

Basically, what debugging in gdb shows is, initially, the min size set is 99
(in my case, the actual value doesn't matter, this may vary depending on the
theme/and or DPI and/or font size, etc.)

Then, a few iterations later, it is set to 47, which leads to the min size
being negative once you remove the shadow margins in the backend.

The initial value of 99 = 47 + 23 + 29, i.e. in
gtk_window_get_preferred_height() minimum_size = title_min + window_border.top
+ window_border.bottom;

The last value of 47 is, well, 47 + 0 + 0 because
gtk_container_get_border_width() returned (0,0,0,0), because the window has
transitioned to the maximized state in between, but the Wayland backend still
applies the "old" shadow margins...

Ths attached simple reproducer (similar program as before, just added a
"gtk_window_maximize (GTK_WINDOW(window))" prior to showing the window shows
the behavior.

So actually, I think we should not even clamp (although it would be safe), we
should tahter fix the upper layers to keep the shadows margins in sync, if
doable...

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/wayland-bugs/attachments/20160919/cd499342/attachment.html>


More information about the wayland-bugs mailing list