Bug 483187 - [X11] After the monitor turns off, the corner/edge effects retrigger without a delay
Summary: [X11] After the monitor turns off, the corner/edge effects retrigger without ...
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: Hotcorners and edges (other bugs)
Version First Reported In: 6.0.1
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords: qt6, X11-only
: 506882 (view as bug list)
Depends on:
Blocks:
 
Reported: 2024-03-11 01:11 UTC by tgnff242
Modified: 2025-09-03 13:41 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: Qt 6.8.4, 6.9.2, and 6.10.0
Sentry Crash Report:


Attachments
glxinfo (122.83 KB, text/plain)
2024-04-07 15:25 UTC, tgnff242
Details
Triggering a hot corner after turning off the monitor. (1.03 MB, video/mp4)
2024-09-26 01:26 UTC, tgnff242
Details
Fix screenedge reactivation (557 bytes, patch)
2025-07-22 19:48 UTC, Guido
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tgnff242 2024-03-11 01:11:33 UTC
SUMMARY

This occurs on X11 only. The monitor could be turned off manually, or let it turn off on its own after the set time in Energy Saving settings.


STEPS TO REPRODUCE
1. Make sure you have a corner or edge configured to trigger an effect.
2 . Turn off the monitor, or let it turn off due to inactivity.
3 . Wake up the monitor, and move the pointer to the corner/edge to trigger the effect.
4 . Keep moving the pointer even after the effect is triggered without stopping.

OBSERVED RESULT

The effect gets re-triggered over and over as long as the pointer moves after hitting the corner/edge. The "reactivation delay" is completely ignored.

EXPECTED RESULT

Before the monitor turns off, you can't keep re-triggering the effect by moving the pointer non-stop to the corner/edge, so I expect this to be true at all times. This behaves well in Wayland.

SOFTWARE/OS VERSIONS
Linux: ArchLinux
KDE Plasma Version: 6.0.1
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.2

ADDITIONAL INFORMATION

Restarting KWin resolves the issue.
Comment 1 tgnff242 2024-04-07 15:25:20 UTC
Also, it seems that triggering the effects is not blocked by fullscreen applications, when this happens. Still present in KWin 6.0.3 / Qt 6.6.3. I've attempted to find the commit that introduced it, but, presumably because I was only building KWin, compilation fails.

I'm assuming this might be hardware-depended, since others would have stumble upon it by now. I'm on a desktop, with an AMD RDNA1 GPU using Mesa. I'm attaching glxinfo.
Comment 2 tgnff242 2024-04-07 15:25:55 UTC
Created attachment 168257 [details]
glxinfo
Comment 3 tgnff242 2024-06-20 16:46:31 UTC
Reproducible on:

KDE Plasma Version: 6.1.0
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1
Comment 4 David Edmundson 2024-09-25 13:55:45 UTC
I cannot reproduce in X11, can you confirm what action you had in your corner and ideally a video of the issue triggering.
Comment 5 tgnff242 2024-09-26 01:26:29 UTC
Created attachment 174084 [details]
Triggering a hot corner after turning off the monitor.

I have the Overview effect on the upper right and the Grid effect on the bottom right corner. I have reproduce the issue using a new user to make sure it's not one of my user's settings.

In the attached video, I'm moving the cursor constantly toward the upper right corner. At the first part of it, you can see how the Overview effect is constantly re-triggered. Then, I restart kwin and show that triggering the corner works as expected.

By the way, this bug makes it difficult to use the effects using the corners, because you need to move the cursor toward the corner again and again until the effect stays "on".
Comment 6 Bug Janitor Service 2024-10-11 03:49:28 UTC
๐Ÿ›๐Ÿงน โš ๏ธ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME.

For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging.

Thank you for helping us make KDE software even better for everyone!
Comment 7 TraceyC 2025-02-24 17:58:35 UTC
Adding the x11-only keyword
Comment 8 Guido 2025-07-13 20:32:27 UTC
*** Bug 506882 has been marked as a duplicate of this bug. ***
Comment 9 Guido 2025-07-13 20:34:51 UTC
I am affected by the same bug. It only occurs in multi-screen configurations. For example, if I start with the external monitor switched on and the integrated monitor switched off.
Restarting kwin_x11 the problem disappears, but if I reactivate the internal monitor, it reappears.
Comment 10 Guido 2025-07-22 19:25:41 UTC
I did a little debugging, this is what I found.

Working fine log

[canActivate] "19:58:10.700" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "null" now: 32046666000
[canActivate] "19:58:10.716" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32046666000" lastTrigger: "null" now: 32046682000
[canActivate] "19:58:10.733" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32046666000" lastTrigger: "null" now: 32046706000
[canActivate] "19:58:10.750" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32046666000" lastTrigger: "null" now: 32046722000
[canActivate] "19:58:10.767" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32046666000" lastTrigger: "null" now: 32046737000
[canActivate] "19:58:10.783" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32046666000" lastTrigger: "null" now: 32046754000
[canActivate] "19:58:11.621" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "32047122000" now: 32047594000
[canActivate] "19:58:11.621" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047594000
[canActivate] "19:58:11.632" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047602000
[canActivate] "19:58:11.650" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047617000
[canActivate] "19:58:11.666" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047634000
[canActivate] "19:58:11.683" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047649000
[canActivate] "19:58:11.700" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047666000
[canActivate] "19:58:11.717" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32047594000" lastTrigger: "32047122000" now: 32047690000
[canActivate] "19:58:12.550" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "32047873000" now: 32048522000
[canActivate] "19:58:12.550" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32048522000" lastTrigger: "32047873000" now: 32048523000
[canActivate] "19:58:12.566" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32048522000" lastTrigger: "32047873000" now: 32048538000
[canActivate] "19:58:12.583" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32048522000" lastTrigger: "32047873000" now: 32048554000
[canActivate] "19:58:12.600" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32048522000" lastTrigger: "32047873000" now: 32048570000
[canActivate] "19:58:12.617" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32048522000" lastTrigger: "32047873000" now: 32048586000
[canActivate] "19:58:12.633" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32048522000" lastTrigger: "32047873000" now: 32048602000
[canActivate] "19:58:13.600" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "32048786000" now: 32049570000
[canActivate] "19:58:13.617" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32049570000" lastTrigger: "32048786000" now: 32049586000
[canActivate] "19:58:13.633" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32049570000" lastTrigger: "32048786000" now: 32049601000
[canActivate] "19:58:13.650" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32049570000" lastTrigger: "32048786000" now: 32049618000
[canActivate] "19:58:13.666" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32049570000" lastTrigger: "32048786000" now: 32049633000
[canActivate] "19:58:13.683" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32049570000" lastTrigger: "32048786000" now: 32049650000


Bugged behavior log

[canActivate] "19:58:28.973" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "null" now: 32064946000
[canActivate] "19:58:28.981" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32064954000
[canActivate] "19:58:28.988" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32064961000
[canActivate] "19:58:28.998" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32064969000
[canActivate] "19:58:29.004" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32064978000
[canActivate] "19:58:29.016" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32064986000
[canActivate] "19:58:29.020" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32064993000
[canActivate] "19:58:29.032" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32065002000
[canActivate] "19:58:29.036" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32065010000
[canActivate] "19:58:29.048" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32065018000
[canActivate] "19:58:29.052" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32064946000" lastTrigger: "null" now: 32065025000
[canActivate] "19:58:29.132" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "null" now: 32065097000
[canActivate] "19:58:29.132" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065097000" lastTrigger: "null" now: 32065105000
[canActivate] "19:58:29.167" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065097000" lastTrigger: "null" now: 32065138000
[canActivate] "19:58:29.182" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065097000" lastTrigger: "null" now: 32065153000
[canActivate] "19:58:29.198" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065097000" lastTrigger: "null" now: 32065170000
[canActivate] "19:58:29.215" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065097000" lastTrigger: "null" now: 32065185000
[canActivate] "19:58:29.684" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "null" now: 32065657000
[canActivate] "19:58:29.698" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065665000
[canActivate] "19:58:29.700" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065674000
[canActivate] "19:58:29.708" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065681000
[canActivate] "19:58:29.717" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065689000
[canActivate] "19:58:29.724" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065697000
[canActivate] "19:58:29.732" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065706000
[canActivate] "19:58:29.740" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065713000
[canActivate] "19:58:29.749" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065722000
[canActivate] "19:58:29.756" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065729000
[canActivate] "19:58:29.765" timeThreshold: 75 reActivationThreshold: 350 lastReset: "32065657000" lastTrigger: "null" now: 32065737000
[canActivate] "19:58:29.796" timeThreshold: 75 reActivationThreshold: 350 lastReset: "null" lastTrigger: "null" now: 32065769000

So "lastTrigger" is always null.
I can propose a patch shortly.
Comment 11 Guido 2025-07-22 19:48:35 UTC
Created attachment 183442 [details]
Fix screenedge reactivation

Please see the attached patch.

it forces m_lastTrigger init on edges we have created in ScreenEdges::recreateEdges()

Tested on kwin-x11 6.4.3

Best!
Comment 12 Bug Janitor Service 2025-07-26 14:56:29 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin-x11/-/merge_requests/55
Comment 13 Bug Janitor Service 2025-07-26 17:28:52 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin-x11/-/merge_requests/57
Comment 14 Guido 2025-07-30 11:24:55 UTC
On my PC, looks like this:

https://codereview.qt-project.org/c/qt/qtbase/+/663811

resolve (also) this bug.
Comment 15 Nate Graham 2025-09-03 13:41:31 UTC
This was apparently fixed in Qt with https://codereview.qt-project.org/c/qt/qtbase/+/663811.