Bug 494169 - window content distortion in klipper-config dialog
Summary: window content distortion in klipper-config dialog
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Clipboard widget & pop-up (show other bugs)
Version: 6.2.0
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
: 480741 497978 (view as bug list)
Depends on:
Blocks:
 
Reported: 2024-10-05 14:14 UTC by slartibart70
Modified: 2025-01-10 22:55 UTC (History)
6 users (show)

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


Attachments
1 (120.62 KB, image/png)
2024-10-05 14:17 UTC, slartibart70
Details
2 (77.83 KB, image/png)
2024-10-05 14:17 UTC, slartibart70
Details
3 (80.17 KB, image/png)
2024-10-05 14:18 UTC, slartibart70
Details
4 (83.67 KB, image/png)
2024-10-05 14:18 UTC, slartibart70
Details
5 (104.37 KB, image/png)
2024-10-05 14:18 UTC, slartibart70
Details
6 (67.27 KB, image/png)
2024-10-05 14:18 UTC, slartibart70
Details
7 (80.32 KB, image/png)
2024-10-05 14:19 UTC, slartibart70
Details
8 (83.65 KB, image/png)
2024-10-05 14:19 UTC, slartibart70
Details
9 (80.33 KB, image/png)
2024-10-05 14:19 UTC, slartibart70
Details
10 (80.12 KB, image/png)
2024-10-05 14:19 UTC, slartibart70
Details
tests with 6.2.2 (3.49 MB, video/webm)
2024-10-24 12:32 UTC, slartibart70
Details
klipper_configure1 - duplicated icons in config window (70.33 KB, image/jpeg)
2025-01-07 22:58 UTC, TraceyC
Details

Note You need to log in before you can comment on or make changes to this bug.
Description slartibart70 2024-10-05 14:14:44 UTC
Problem: the clipboard config dialog behaves weirdly after opening the 'actions properties' and 'add command' and then (without adding anything) just clicking on cancel 2 times until both popyp-dialogs are closed.
Next, click on 'shortcuts' or 'action menu' and see a very strange behavior in the neighboring panel... the contents don't follow the clicks, have non-refreshed content or just 'fade in' slowly. Even the background on the clicked icon (shortcuts, actionMenu, actionsConfiguration,...) is not rendered correctly.

Please see the attached screenshots numbered accordingly to the click-sequence i did.
Th problem with the images are, that only half of the visual glitches are captured by the images. Please click for yourself for the 'full' experience...

This looks and feels like a similar bug in dolphin file-manager when having contentPreview open (F11) which is way harder to reproduce. The effects are similar: the file-view panel gets distorted and has incomplete contents
(i already filed this bug ages ago, but it got never resolved. Plasma updates only made it harder to reproduce, so there is progress, i guess? :-) 




Operating System: Fedora Linux 40
KDE Plasma Version: 6.2.0
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.2
Kernel Version: 6.10.12-200.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 PRO 7840U w/ Radeon 780M Graphics
Memory: 58,5 GiB of RAM
Graphics Processor: AMD Radeon 780M
Manufacturer: LENOVO
Product Name: 21K5000JGE
System Version: ThinkPad P14s Gen 4
Comment 1 slartibart70 2024-10-05 14:17:40 UTC
Created attachment 174449 [details]
1
Comment 2 slartibart70 2024-10-05 14:17:59 UTC
Created attachment 174450 [details]
2
Comment 3 slartibart70 2024-10-05 14:18:23 UTC
Created attachment 174451 [details]
3
Comment 4 slartibart70 2024-10-05 14:18:33 UTC
Created attachment 174452 [details]
4
Comment 5 slartibart70 2024-10-05 14:18:42 UTC
Created attachment 174453 [details]
5
Comment 6 slartibart70 2024-10-05 14:18:54 UTC
Created attachment 174454 [details]
6
Comment 7 slartibart70 2024-10-05 14:19:05 UTC
Created attachment 174455 [details]
7
Comment 8 slartibart70 2024-10-05 14:19:15 UTC
Created attachment 174456 [details]
8
Comment 9 slartibart70 2024-10-05 14:19:25 UTC
Created attachment 174457 [details]
9
Comment 10 slartibart70 2024-10-05 14:19:36 UTC
Created attachment 174458 [details]
10
Comment 11 slartibart70 2024-10-05 14:26:28 UTC
i found the old bugreport for dolphin
https://bugs.kde.org/show_bug.cgi?id=466211

Even if this was in plasma5, those glitches are still there in plasma6 (i encountered them in plasma 6.1.x and 6.2.0)
But, they are very hard to reproduce now
Comment 12 Akseli Lahtinen 2024-10-07 10:29:31 UTC
Oh wow, I can repro the weird flickering every time, i think the steps are same as reporters:

1. Configure clipboard
2. Select actions configuration
3. Click "Add action"
4. Click "Add command"
5. Close both dialogs with cancel
6. Switch to different menus. Especially shortcuts menu gets weird.

Operating System: Fedora Linux 40
KDE Plasma Version: 6.2.80
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.2
Kernel Version: 6.10.12-200.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 3600 6-Core Processor
Memory: 15,5 GiB of RAM
Graphics Processor: AMD Radeon RX 6600
Comment 13 Bug Janitor Service 2024-10-16 16:43:38 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4844
Comment 14 David Edmundson 2024-10-16 21:25:15 UTC
Git commit 44358a8e724aeba3a4520be9ae63d6c4fec4c529 by David Edmundson.
Committed on 16/10/2024 at 21:07.
Pushed by davidedmundson into branch 'master'.

klipper: Avoid creating lots of native windows in settings dialog

Klipper's action dialog tries to resize itself, for that it needs a
QWindow. It was using an extreme call that also makes it a native window
ahead of QDialog doing it.

The dialog has a widget parent which isn't separated yet due to it not
being shown.

The current code hits a path where QWidget tries making all child
widgets of the parent widget also native windows and we get in a mess.

M  +1    -1    klipper/editactiondialog.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/44358a8e724aeba3a4520be9ae63d6c4fec4c529
Comment 15 David Edmundson 2024-10-16 21:59:55 UTC
Git commit dcb1b27d38a84f14c794504655161e23e3d43192 by David Edmundson, on behalf of David Edmundson.
Committed on 16/10/2024 at 21:42.
Pushed by davidedmundson into branch 'Plasma/6.2'.

klipper: Avoid creating lots of native windows in settings dialog

Klipper's action dialog tries to resize itself, for that it needs a
QWindow. It was using an extreme call that also makes it a native window
ahead of QDialog doing it.

The dialog has a widget parent which isn't separated yet due to it not
being shown.

The current code hits a path where QWidget tries making all child
widgets of the parent widget also native windows and we get in a mess.


(cherry picked from commit 44358a8e724aeba3a4520be9ae63d6c4fec4c529)

Co-authored-by: David Edmundson <kde@davidedmundson.co.uk>

M  +1    -1    klipper/editactiondialog.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/dcb1b27d38a84f14c794504655161e23e3d43192
Comment 16 slartibart70 2024-10-24 09:11:39 UTC
i tested in 6.2.2, but this is not yet fixed?
Still the same problematic behavior when switching to different menu-entries

--- 

Operating System: Fedora Linux 40
KDE Plasma Version: 6.2.2
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.2
Kernel Version: 6.11.5-200.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 PRO 7840U w/ Radeon 780M Graphics
Memory: 58,5 GiB of RAM
Graphics Processor: AMD Radeon 780M
Manufacturer: LENOVO
Product Name: 21K5000JGE
System Version: ThinkPad P14s Gen 4
Comment 17 David Edmundson 2024-10-24 11:17:14 UTC
It should be in 6.2.2. Please ensure plasmashell has restarted since upgrading.

The steps given above no longer produce an issue for me. If you have an issue remaining please provide new steps/screenshots.
Comment 18 slartibart70 2024-10-24 12:31:13 UTC
Yes, definitely restarted (and also rebooted) the machine.

This time as proof a video of the things i do and the distortions visible.

Any other files (logs, configs, ...) that i can provide?
Comment 19 slartibart70 2024-10-24 12:32:17 UTC
Created attachment 175186 [details]
tests with 6.2.2
Comment 20 slartibart70 2024-10-24 13:03:13 UTC
just to be sure - i picked up an older laptop, lenovo t420, intel-machine, only intel-graphics.
With plasma 6.2.0 i can recreate the problem on the machine.
Same steps, same results (here, i only created a dummy action, named 'test' with the command 'ls'... just for having one). 

Updating to 6.2.2 with a current kernel - and the problem remains.

--- 
Operating System: Fedora Linux 40
KDE Plasma Version: 6.2.2
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.2
Kernel Version: 6.11.5-200.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 4 × Intel® Core™ i7-2620M CPU @ 2.70GHz
Memory: 15,5 GiB of RAM
Graphics Processor: Mesa Intel® HD Graphics 3000
Manufacturer: LENOVO
Product Name: 4236NGG
System Version: ThinkPad T420
Comment 21 Nate Graham 2025-01-04 00:30:01 UTC
*** Bug 497978 has been marked as a duplicate of this bug. ***
Comment 22 slartibart70 2025-01-05 15:11:18 UTC
just a refresher:

i tried this problem with klipper with the kde-develop version.
The visual distortion is still there, i would say it's worse than in the official release of 6.2.5

---
Operating System: Fedora Linux 41
KDE Plasma Version: 6.2.80
KDE Frameworks Version: 6.11.0
Qt Version: 6.8.1
Kernel Version: 6.12.8-200.fc41.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 8 × Intel® Core™ i7-7820HQ CPU @ 2.90GHz
Memory: 31.1 GiB of RAM
Graphics Processor 1: Mesa Intel® HD Graphics 630
Graphics Processor 2: llvmpipe
Comment 23 TraceyC 2025-01-07 22:56:49 UTC
Confirm that following Akseli's reproduction steps, I also see corruption in the Configure window
Both on git-master and Plasma 6.2.4 I see the menu icons get doubled in the window on the left
It makes me think that this was happening for slartibart70, the difference being that the duplicated icons were stacked on the originals, where on my machines they are to the right

When I follow the reproduction steps:
4. Click "Add command"
At this point the left hand icons are shown twice in the main Actions Configuration window in the back.

5. Close both dialogs with cancel
The inner icons don't do anything on click - except if the main (real) shortcuts icon is selected to the left. See klipper_configure1 to see the double icons at this point.

6. Switch to different menus. Especially shortcuts menu gets weird.

Also, I tried to resize the config window and it crashed.
I also got it to crash by clicking around in the window, particularly in the Shortcuts panel
Comment 24 TraceyC 2025-01-07 22:58:39 UTC
Created attachment 177184 [details]
klipper_configure1 - duplicated icons in config window
Comment 25 Bug Janitor Service 2025-01-08 14:59:02 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/5040
Comment 26 Fushan Wen 2025-01-09 12:31:24 UTC
Git commit 8a6c6e8f995c179bcc5dd1d3e2efbecf0a232f2f by Fushan Wen, on behalf of David Edmundson.
Committed on 09/01/2025 at 12:31.
Pushed by fusionfuture into branch 'master'.

klipper: Avoid use of winId

winId is a messy function and causes problems when used badly.

M  +1    -1    klipper/editcommanddialog.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/8a6c6e8f995c179bcc5dd1d3e2efbecf0a232f2f
Comment 27 Fushan Wen 2025-01-09 13:01:28 UTC
Git commit d5496141e11a75764d134724fc5a715b77522e97 by Fushan Wen.
Committed on 09/01/2025 at 13:01.
Pushed by fusionfuture into branch 'Plasma/6.3'.

klipper: Avoid use of winId

winId is a messy function and causes problems when used badly.


(cherry picked from commit 8a6c6e8f995c179bcc5dd1d3e2efbecf0a232f2f)

Co-authored-by: David Edmundson <kde@davidedmundson.co.uk>

M  +1    -1    klipper/editcommanddialog.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/d5496141e11a75764d134724fc5a715b77522e97
Comment 28 TraceyC 2025-01-09 21:54:12 UTC
*** Bug 480741 has been marked as a duplicate of this bug. ***
Comment 29 slartibart70 2025-01-10 22:55:38 UTC
can confirm: works in 6.3.80
Many thanks!!

---

Operating System: Fedora Linux 41
KDE Plasma Version: 6.3.80
KDE Frameworks Version: 6.11.0
Qt Version: 6.8.1
Kernel Version: 6.12.9-200.fc41.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 PRO 7840U w/ Radeon 780M Graphics
Memory: 58,5 GiB of RAM
Graphics Processor: AMD Radeon 780M