| Summary: | KWIN includes window decorations in the size of new windows for SSD (xdg_toplevel) | ||
|---|---|---|---|
| Product: | [Plasma] kwin | Reporter: | Campbell Barton <ideasman42> |
| Component: | wayland-generic | Assignee: | KWin default assignee <kwin-bugs-null> |
| Status: | RESOLVED NOT A BUG | ||
| Severity: | normal | CC: | kde, nate, vlad.zahorodnii, xaver.hugl |
| Priority: | NOR | Keywords: | wayland-only |
| Version First Reported In: | 5.27.9 | ||
| Target Milestone: | --- | ||
| Platform: | Arch Linux | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
Campbell Barton
2023-11-29 22:24:58 UTC
> This means creating a surface 500x500 then using XDG top-level to assign server side decorations will create a 500x500 window Does blender request a server side decoration **after** attaching a 500x500 buffer to the surface? > existing surface size should be used unless there is a reason to constrain them (window size exceeds monitor size for e.g.). What window geometry size the compositor puts in configure events is subject to compositor policies. Apps cannot make assumptions about it. If blender initializes xdg-toplevels as follows -> wl_compositor.create_surface -> xdg_wm_base.get_xdg_surface -> xdg_surface.get_toplevel -> xdg_decoration_manager_v1.get_toplevel_decoration -> xdg_toplevel_decoration_v1.set_mode -> wl_surface.commit wait for the configure event -> wl_surface.attach(500x500) -> wl_surface.commit then the toplevel won't shrink. If the server side decoration is requested **after** the surface has been mapped, what happens next is up to the compositor. In case of kwin, it tries to maintain same frame geometry, so the space for window borders will be subtracted from the surface size. If blender indeed initializes like that, we recommend to request a server side decoration **before** the first wl_surface commit. It's going to fix this issue and it's going to ensure that there's no any flickering caused by server side decoration being missing for one frame. This works, thanks for the hint... while I'm not sure if this is following the XDG spec, postponing attaching the sized buffer helps to avoid flickering. Committed fix: https://projects.blender.org/blender/blender/commit/e6c200e94ccc16839bcccee39be84dde9dce3993 Closing as not a bug. |