|Summary:||Turning the monitor off/on, causes some windows to get resized|
|Product:||kwin||Reporter:||Ahmad Samir <a.samirh78>|
|Component:||wayland-generic||Assignee:||KWin default assignee <kwin-bugs-null>|
|Latest Commit:||https://invent.kde.org/plasma/kwin/commit/5a6f1e42c161fd7f2945df7dff2e5d5f40be03b0||Version Fixed In:||5.24|
Description Ahmad Samir 2021-12-23 10:53:01 UTC
Running Plasma Wayland session, if I turn the monitor off then back on some windows get resized; e.g. a maximised Kate window is resized to small square on the right; a Konversation window that wasn't maximised is resized to a shorter height, the same goes for Firefox. This is on OpenSuse Tumbleweed, recent-ish git master snapshots of plasma and kwin ...etc. This is with an nvidia GTX 770, using the modesetting driver (is that correct?), i.e. not the proprietary driver.
Comment 1 Ahmad Samir 2021-12-23 10:55:58 UTC
This seems to happen with kscreen enabled and disabled (`/usr/bin/systemctl --user mask plasma-kscreen.service`).
Comment 2 Ahmad Samir 2021-12-23 10:59:56 UTC
It seems I remember stuff after I hit save changes... I have a 4k monitor with this setup: QT_SCREEN_SCALE_FACTORS=DP-1=1 PLASMA_USE_QT_SCALING=1 QT_AUTO_SCREEN_SCALE_FACTOR=0 QT_ENABLE_HIGHDPI_SCALING=1
Comment 3 Bug Janitor Service 2022-01-02 23:05:27 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/1835
Comment 4 Zamundaaa 2022-01-03 10:30:12 UTC
Git commit 5a6f1e42c161fd7f2945df7dff2e5d5f40be03b0 by Xaver Hugl. Committed on 03/01/2022 at 10:17. Pushed by zamundaaa into branch 'master'. backends/drm: make the placeholder screen as big as the last screen The fixed size of 1080p makes windows change their size and place. To prevent that from happening, make the placeholder screen the same size as the last disconnected screen. This is not a bullet proof solution, only a fast one. Ideally KWin should remember the window layout on a given monitor setup and restore it when reconnected. FIXED-IN: 5.24 M +1 -1 src/backends/drm/drm_backend.cpp https://invent.kde.org/plasma/kwin/commit/5a6f1e42c161fd7f2945df7dff2e5d5f40be03b0
Comment 5 Ahmad Samir 2022-01-04 08:42:43 UTC
I tested locally, and it's indeed fixed. Thanks.