Bug 453745 - Window Border Not Render on the Right on Wayland when Display Scaling > 100%
Summary: Window Border Not Render on the Right on Wayland when Display Scaling > 100%
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: decorations (show other bugs)
Version: 5.24.5
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-13 15:10 UTC by Kevan
Modified: 2022-07-08 12:34 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Image of display settings, where the border around the image does not render on the right side (160.04 KB, image/png)
2022-05-13 15:10 UTC, Kevan
Details
This image shows what the window border normally looks like at 100% scaling (177.19 KB, image/png)
2022-05-13 15:18 UTC, Kevan
Details
Transparent right window border when scaled to any size not 100% (577.42 KB, image/jpeg)
2022-07-07 12:30 UTC, Joern
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kevan 2022-05-13 15:10:20 UTC
Created attachment 148798 [details]
Image of display settings, where the border around the image does not render on the right side

SUMMARY
When the display scaling is 100%, the window borders render as expected, beautifully. However, I crank the scaling up to 110% because I am a bit hard of sight, and the right border on the window leaves the building. Please see the attached image for more information. I took a screenshot of my window with the scaling settings, in the screenshot you can see the border stops at the right side of the window


STEPS TO REPRODUCE
1. Change scaling to >100%
2. Enable Window Borders

OBSERVED RESULT
No rendered window border on the right side of the window frame

EXPECTED RESULT
Complete border around the frame.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: Gentoo (?) Kernel 5.17.4
(available in About System)
KDE Plasma Version: 5.24.5
KDE Frameworks Version: 5.92.0
Qt Version: 5.15.3

ADDITIONAL INFORMATION
I use two monitors. When I move the window from the 110% scaled monitor to a 100% scaled monitor, the right border begins to render again on the window immediately.
Comment 1 Kevan 2022-05-13 15:18:59 UTC
Created attachment 148799 [details]
This image shows what the window border normally looks like at 100% scaling
Comment 2 Joern 2022-07-07 12:29:32 UTC
> ADDITIONAL INFORMATION
> I use two monitors. When I move the window from the 110% scaled monitor to a
> 100% scaled monitor, the right border begins to render again on the window
> immediately.

I've the same problem. In addition the right border (and only the right  one) is transparent on any screen scale !=100%, !=200% and so on. Sometimes the transparent border also flickers until I move the window.
It came up somewhere in between 5.23-5.24.

To visualize I set window border to "Large" and also enabled "Shadow". This monitor is scaled to 115%. When I scale to 100%/200% the right border is fine. See attachmnent
Comment 3 Joern 2022-07-07 12:30:55 UTC
Created attachment 150463 [details]
Transparent right window border when scaled to any size not 100%
Comment 4 David Redondo 2022-07-07 12:57:29 UTC
I can reproduce,
- set borders to normals
- set scaling to 125% 

the right border is not rendered,
at 150% it's rendered
Comment 5 Vlad Zahorodnii 2022-07-08 12:34:28 UTC
Git commit c49620658f24dde055c053cfa1aac6b22997b0d0 by Vlad Zahorodnii, on behalf of David Edmundson.
Committed on 08/07/2022 at 12:34.
Pushed by vladz into branch 'master'.

Create large enough atlas texture for decorations

When we render individual component of a decoration into an atlas we
ceil the positions for the individual component parts so they don't risk
overlapping. See SceneOpenGLDecorationRenderer::render

This isn't done when we set the overall texture height. This can cause
the bottommost part of the atlas (the right edge) to go out of view.

M  +9    -5    src/scenes/opengl/scene_opengl.cpp
M  +1    -0    src/scenes/opengl/scene_opengl.h

https://invent.kde.org/plasma/kwin/commit/c49620658f24dde055c053cfa1aac6b22997b0d0