--- Comment #11 from Olivier Fourdan <> ---
Created attachment 335854
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.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

You are receiving this mail because:
You are on the CC list for the bug.
wayland-bugs mailing list

Reply via email to