Bug 467509 - Pager applet does not clamp when "current screen only" is selected
Summary: Pager applet does not clamp when "current screen only" is selected
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Pager widget (other bugs)
Version First Reported In: 5.26.5
Platform: Manjaro Linux
: NOR minor
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-17 22:56 UTC by Nicolai Weitkemper
Modified: 2023-03-24 15:26 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 5.27.4
Sentry Crash Report:


Attachments
observed result: the representation overflows (4.92 KB, image/png)
2023-03-17 22:56 UTC, Nicolai Weitkemper
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolai Weitkemper 2023-03-17 22:56:51 UTC
Created attachment 157378 [details]
observed result: the representation overflows

SUMMARY
(see title/attachment)

STEPS TO REPRODUCE
1. Have two (or more) screens arranged side-by-side.
2. Have a virtual desktop pager applet in a panel on the left screen.
3. In the pager's config, enable the  “current screen only” option.
4. Open a window on the left screen and slowly move it towards the right screen.

OBSERVED RESULT
Until the “center” of the window passes the screen border, its representation in the pager overflows, interfering with the applets to its right.

EXPECTED RESULT
The representation should be clamped as it is when not using the “current screen only” option.

SOFTWARE/OS VERSIONS
Manjaro 22.0.4
KDE Plasma Version: 5.26.5
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8

ADDITIONAL INFORMATION
There is clamping logic present, but it doesn't seem to consider the possibility that “current screen only” is set.
https://invent.kde.org/plasma/plasma-desktop/-/blob/master/applets/pager/plugin/windowmodel.cpp#L101
Comment 1 Nicolai Weitkemper 2023-03-17 23:04:02 UTC
Forgot one STEP TO REPRODUCE:
3b. Open the rightmost virtual desktop.
Comment 2 Bug Janitor Service 2023-03-23 13:04:49 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/1442
Comment 3 David Redondo 2023-03-24 15:26:49 UTC
Git commit cd8b899d458c3136fa1c83c6923b3c9dcd45903b by David Redondo.
Committed on 24/03/2023 at 07:57.
Pushed by davidre into branch 'master'.

applets/pager: Clamp to screen size if only showing one screen

Otherwise windows will spill into the gap/next VD.
FIXED-IN:5.27.4

M  +7    -6    applets/pager/plugin/windowmodel.cpp

https://invent.kde.org/plasma/plasma-desktop/commit/cd8b899d458c3136fa1c83c6923b3c9dcd45903b