Bug 494829

Summary: [Regression with bisect] Kwin 6.2.1 doesn't update mouse cursor when hovering through links
Product: [Plasma] kwin Reporter: Dan <dan76>
Component: platform-drmAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: contact, nate, postix, xaver.hugl
Priority: NOR Keywords: regression
Version: 6.2.1   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: 6.2.1.1
Sentry Crash Report:

Description Dan 2024-10-15 20:59:52 UTC
I upgraded Plasma to 6.2.1 and I noticed the mouse cursor isn't updated when hovering through a link (the mouse pointer just stays the same and "jumps" over buttons and links, instead of changing from pointer to the hand finger cursor). So I did a bisect between 6.2.0 and 6.2.1 and the result is:

446423407104461c9936c107616ccec7b2432867 is the first bad commit
commit 446423407104461c9936c107616ccec7b2432867 (HEAD)
Author: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
Date:   Tue Oct 15 11:24:32 2024 +0000

    backends/drm: restrict damage area to the screen's size
    
    Scissor rectangles going outside of the framebuffer cause OpenGL warnings
    
    BUG: 492152
    
    
    (cherry picked from commit de12db7398068725c0ef1681455069f3ccd09526)
    
    Co-authored-by: Xaver Hugl <xaver.hugl@gmail.com>

 src/backends/drm/drm_egl_layer_surface.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

***

Here's my setup:

Operating System: Linux 
KDE Plasma Version: 6.2.1
KDE Frameworks Version: 6.6.0
Qt Version: 6.8.0
Kernel Version: 6.11.2 (64-bit)
Graphics Platform: Wayland
Processors: 16 × Intel® Core™ i9-9980HK CPU @ 2.40GHz
Memory: 31.2 GiB of RAM
Graphics Processor: NVIDIA GeForce RTX 2070 with Max-Q Design/PCIe/SSE2

Thanks!
Comment 1 Dan 2024-10-15 21:01:39 UTC
And this is happening just on Firefox and Chrome. I didn't notice it on KDE apps.
Comment 2 Bug Janitor Service 2024-10-16 14:53:04 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/6641
Comment 3 Zamundaaa 2024-10-16 15:19:34 UTC
Git commit 12e44324d55c5c0dc8f082248d07bc818f08993a by Xaver Hugl.
Committed on 16/10/2024 at 14:52.
Pushed by zamundaaa into branch 'master'.

backends/drm: don't scale infiniteRegion()

It can lead to weird issues, like the resulting region being entirely in negative coordinates

M  +12   -4    src/backends/drm/drm_egl_layer_surface.cpp

https://invent.kde.org/plasma/kwin/-/commit/12e44324d55c5c0dc8f082248d07bc818f08993a
Comment 4 Bug Janitor Service 2024-10-16 15:20:31 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/6642
Comment 5 Zamundaaa 2024-10-16 15:21:19 UTC
Please test and let me know if this actually fixes your problem
Comment 6 Dan 2024-10-16 16:05:30 UTC
Perfect! Your commit solved the issue. Thanks!
Comment 7 Zamundaaa 2024-10-16 16:35:31 UTC
Git commit d352a368e21b9c95eb738a0cbde749425906f7fe by Xaver Hugl.
Committed on 16/10/2024 at 15:20.
Pushed by zamundaaa into branch 'Plasma/6.2'.

backends/drm: don't scale infiniteRegion()

It can lead to weird issues, like the resulting region being entirely in negative coordinates


(cherry picked from commit 12e44324d55c5c0dc8f082248d07bc818f08993a)

Co-authored-by: Xaver Hugl <xaver.hugl@gmail.com>

M  +12   -4    src/backends/drm/drm_egl_layer_surface.cpp

https://invent.kde.org/plasma/kwin/-/commit/d352a368e21b9c95eb738a0cbde749425906f7fe
Comment 8 Zamundaaa 2024-10-16 17:05:39 UTC
Great!
Comment 9 Liviu Mirea 2024-10-17 16:08:07 UTC
*** Bug 494876 has been marked as a duplicate of this bug. ***
Comment 10 Zamundaaa 2024-10-18 11:09:36 UTC
*** Bug 494959 has been marked as a duplicate of this bug. ***
Comment 11 postix 2024-10-18 13:05:15 UTC
As the bug title is only about the cursor, does 12e44324d55c5c0dc8f082248d07bc818f08993a also fix the weird flickering, which I have observed in the duplicate bug report?
Comment 12 postix 2024-10-18 13:07:40 UTC
Also, this report doesn't mention the night light, which was a requirement for me that the bug got triggered.
Comment 13 postix 2024-10-20 12:47:20 UTC
Thanks Xaver, 6.2.1.1 has fully fixed both the cursor and the glitches with night light for me. :)