Bug 453311

Summary: Color can be drag&dropped onto a panel, creates ghost applet
Product: [Unmaintained] kdeplasma-addons Reporter: ratijas <me>
Component: Color PickerAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: kde, nate, niccolo.venerandi
Priority: NOR    
Version First Reported In: master   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In: 6.0
Sentry Crash Report:
Attachments: Color dragged onto a panel

Description ratijas 2022-05-02 18:06:53 UTC
Created attachment 148517 [details]
Color dragged onto a panel

SUMMARY

Dropping a color mime data (e.g. from a color picker dialog)
inserts into the panel containment a fake "applet" item
which is invisible but has some weird side-effects.

This does not happen with colors dragged from a color picker applet itself.

STEPS TO REPRODUCE
1. Open color picker dialog. You can find one by adding a color picker applet, then right click -> Open Color Dialog.
2. Drag a color item from a dialog, and drop it onto a panel.

OBSERVED RESULT
Panel allocates some space as you drag a color over it, suggesting that you may drop it there.
As soon as you drop it, an invisible item stays there (is it the same placeholder or a new one? idk). This fake "applet" can be moved around in Edit mode, but it does not provide any tooltip data (I guess) because the tooltip either shows whatever it had from a previous hovered item/applet, or becomes empty. Since "Remove" button is located in a tooltip, you effectively can't remove this ghost item.

EXPECTED RESULT
For consistency's sake, a dragged color from a color picker dialog should behave the same as from the color picker applet -- expose text/plain mime type so that Plasma will create a Note with the the color string.

But on the other side, I think that creating notes on a panel every time user happens to drag something over it is inadequate (unlike a desktop containment). It's not only about colors, so that's a more general discussion for another time.

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20220428
KDE Plasma Version: 5.24.80
KDE Frameworks Version: 5.94.0
Qt Version: 5.15.2
Kernel Version: 5.17.4-1-default (64-bit)
Graphics Platform: X11
Processors: 8 × Intel® Core™ i7-8565U CPU @ 1.80GHz
Memory: 15.3 ГиБ of RAM
Graphics Processor: Mesa Intel® UHD Graphics 620
Comment 1 Nate Graham 2023-09-18 21:09:05 UTC
Tried this again on Plasma 6 wayland and now it creates a Sticky Note widget with the hex color code. Which is maybe also not super amazing, but it's much better than the bug originally reported here, which I was able to reproduce in the past. So let's call it fixed now!