Created attachment 155655 [details] Affected 1.25 + 1.5 screen layout SUMMARY With kwin_wayland 5.26.90 (bug wasn't present on kwin_wayland 5.26.5) maximized windows take also one pixel on other screen. I use fractional scaling, top-bottom screen arrangements (left-right wasn't tested). Bug reproduced with top×1.25 + bottom×1.5 and top×1 + bottom×1.5 screen layouts. One extra pixel is not kscreen problem, screens do not overlap (it is hidden by right panel on bottom screen and active maximized window on bottom screen). STEPS TO REPRODUCE 1. Setup layout with two screens, bottom one has scaling 1.5, top could be any (reproduced at least with 1 and 1.25). 2. Maximize window on top screen (for easier noticing, contrast window and wallpaper may be used). 3. (Optional) Maximize some window on bottom screen. OBSERVED RESULT One pixel line overhang on on bottom screen from top max window. With step 3 you could switch between windows and see how that extra line appears and hides. EXPECTED RESULT Maximized windows should not extend beyond their screen. SOFTWARE/OS VERSIONS Linux/KDE Plasma: openSUSE Tumbleweed 20230124 with KDE Plasma 5.27 beta KDE Plasma Version: 5.26.90 KDE Frameworks Version: 5.102.0 Qt Version: 5.15.8+kde160 ADDITIONAL INFORMATION This bug looks like some sort of opposite to https://bugs.kde.org/show_bug.cgi?id=459373 Unlike that bug it doesn't depend on XWayland (native Wayland clients are used) and it wasn't present before 5.27 beta. example of affected layout (full in attachment) `kscreen-doctor -j | jq '[.outputs[] | { name: .name, pos: .pos, size: .size, scale: .scale }]'` ``` [ { "name": "eDP-1", "pos": { "x": 385, "y": 1152 }, "size": { "height": 1080, "width": 1920 }, "scale": 1.5 }, { "name": "DP-1", "pos": { "x": 0, "y": 0 }, "size": { "height": 1440, "width": 2560 }, "scale": 1.25 } ] ```
Created attachment 155656 [details] screenshot with noticeable step between panel and extent of window
Can reproduce on latest neon unstable (wayland)
A possibly relevant merge request was started @ https://invent.kde.org/plasma/libkscreen/-/merge_requests/172
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kscreen/-/merge_requests/264
Git commit 6f797a908360de5c9654cd6cbd1dcc170b35207c by Yifan Zhu. Committed on 10/12/2023 at 04:33. Pushed by zamundaaa into branch 'master'. Round up output geometry Under fractional scaling, output screens can have non-integral sizes. Previous code uses QSizeF::toSize(), which rounds to the nearest integer. This sometimes results in different screens sharing one pixel at the edge, which causes BUG 464842 and BUG 477791. Implement Output::explicitLogicalSizeInt() and Config::logicalSizeForOutputInt to explicitly round up non-integral sizes, and use them in calculating output geometry. Related: bug 477791 M +1 -1 autotests/testscreenconfig.cpp M +7 -1 src/config.cpp M +7 -0 src/config.h M +7 -1 src/output.cpp M +11 -0 src/output.h https://invent.kde.org/plasma/libkscreen/-/commit/6f797a908360de5c9654cd6cbd1dcc170b35207c
Git commit cff5739c872393bfbfe9bca43a5763f4d9ec3e6e by Xaver Hugl, on behalf of Yifan Zhu. Committed on 11/12/2023 at 15:23. Pushed by zamundaaa into branch 'master'. Round up output geometry Under fractional scaling, output screens can have non-integral sizes. Previous code uses QSizeF::toSize(), which rounds to the nearest integer. This sometimes results in different screens sharing one pixel at the edge, which causes BUG 464842 and BUG 477791. Use the new Output::explicitLogicalSizeInt() and Config::logicalSizeForOutputInt functions to explicitly round up non-integral sizes. Related: bug 477791 M +6 -6 kcm/output_model.cpp https://invent.kde.org/plasma/kscreen/-/commit/cff5739c872393bfbfe9bca43a5763f4d9ec3e6e