Bug 502274 - Clipboard history stores copy-pasted files (or list of files) even when Non-text selection is set to Never save in history
Summary: Clipboard history stores copy-pasted files (or list of files) even when Non-t...
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Clipboard widget & pop-up (other bugs)
Version First Reported In: 6.3.3
Platform: Other Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-04-01 12:20 UTC by Roman
Modified: 2026-09-09 02:40 UTC (History)
6 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Roman 2025-04-01 12:20:10 UTC
SUMMARY
Clipboard history stores copy-pasted files (or list of files) even when Non-text selection is set to "Never save in history".

STEPS TO REPRODUCE
1. Open Dolphin (or another file manager), copy-paste some files around
2. Look at clipboard history

OBSERVED RESULT
There is item in clipboard history for every file or set of files copy-pasted. 

EXPECTED RESULT
Files (or sets of files) are clearly non-text items, and should not be in history when set to "Never save in history". 

Or maybe there should be separate settings for text items, images, and files, so everyone can set it as needed?

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.3.3
KDE Frameworks Version: 6.12.0
Qt Version: 6.8.3
Kernel Version: 6.13.8-arch1-1 (64-bit)
Graphics Platform: Wayland
Processors: 8 × Intel® Core™ i7-9700K CPU @ 3.60GHz
Memory: 31.3 GiB of RAM
Graphics Processor: NVIDIA GeForce RTX 4070
Comment 1 TraceyC 2025-04-01 18:19:04 UTC
I can reproduce this on git-master
Comment 2 Fushan Wen 2025-04-03 17:20:30 UTC

*** This bug has been marked as a duplicate of bug 496453 ***
Comment 3 Roman 2025-10-01 11:17:43 UTC
This issue is still present in 6.4.5, and is NOT duplicate of https://bugs.kde.org/show_bug.cgi?id=496453 (items are not duplicate, and it has nothing to do with Connect)
Comment 4 TraceyC 2025-10-01 16:00:29 UTC
Setting back to confirmed
Comment 5 erfan 2025-11-18 09:48:11 UTC
The problem is still present on plasma 6.5.2 - KDE Neon and Opensuse Tumbleweed, and copying not only from Dolphin, but also copying images or videos from imageviewers like Gwenview or Qimgv is the same.

From my point of view I would set the importance of the bug to MAJOR one, to be solved urgently, because there are several huge problems with Klipper in handling images, so until all those problems gets solved, it would be possible to use klipper at least for texts.
Comment 6 TraceyC 2025-11-18 18:06:04 UTC
(In reply to erfan from comment #5)
> The problem is still present on plasma 6.5.2 - KDE Neon and Opensuse
> Tumbleweed, and copying not only from Dolphin, but also copying images or
> videos from imageviewers like Gwenview or Qimgv is the same.

Thanks for the additional detail, that helps.

> From my point of view I would set the importance of the bug to MAJOR one, to
> be solved urgently, because there are several huge problems with Klipper in
> handling images, so until all those problems gets solved, it would be
> possible to use klipper at least for texts.


About the Importance field, you can see our criteria for the different values here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging#Set_the_Severity_field

The reason this is set to "Normal" is because there's a workaround that isn't too painful - you can manually clear clipboard history periodically. We only have one bug per report, if there are other reports for the clipboard you believe should be higher severity because there isn't a workaround or it's very cumbersome, please feel free to comment in those reports. Thanks for your understanding.
Comment 7 erfan 2025-11-19 08:09:59 UTC
I will add to the list of apps from which klipper copies images, even if it shouldn't, nomacs image viewer too.

Thank You pointing me to the Importance field values. According to it, and putting together
Bug 1. this bug
Bug 2. https://bugs.kde.org/show_bug.cgi?id=511672, a duplicate of https://bugs.kde.org/show_bug.cgi?id=490952
Bug 3. https://bugs.kde.org/show_bug.cgi?id=512280

all which affects me, and because this bug affects directly an option from the settings, which is not working, I would even consider it Grave.

Deleting the images from clipboard history is not a workaround to this bug trio, because images are shown only after the hang up (Bug 2.). So, if this option would have been working correctly, the other two bugs (Bug 2. and 3.)  could have been secondary problems, because setting Never copy Non-text selections would eliminate the possibility to create images in the clipboard, therefore no hang-up too. So I had to completely disable klipper and didn't find a replacement for it on wayland. So, no workaround => Importance = Grave.

As about commenting on other reports, I have made it, and it was proposed to me to open a new bug report about it. So I have found this report, and added the apps from which klipper also copies files even if it shouldn't. One problem is in relationship with or is the consequence of the other, they are linked, cannot be completely separated.

Thank you for your patience!
Comment 8 Tomáš Hnyk 2026-09-03 13:12:48 UTC
This is partial duplicate of https://bugs.kde.org/show_bug.cgi?id=348932 in terms of it saying the config says something which is not true. But that one is about images and this is about files, so not marking it as duplicate, also it will be fixed now: https://bugs.kde.org/show_bug.cgi?id=348932
Comment 9 Nate Graham 2026-09-09 02:40:23 UTC
Git commit 51890caa5a37cd47b8cdac349abfddaf3458c6c1 by Nate Graham, on behalf of Tomáš Hnyk.
Committed on 09/09/2026 at 02:39.
Pushed by ngraham into branch 'master'.

Klipper: Replace radio buttons with checklist in configuration window

Previously, there were two radio button groups in the config.

The first encodes two posibilities, so a checkbox is more appropriate.

The second was confusing and added little value. It is unclear if any
apps are sending images to primary selection. It seems not. So this
radiobuttons are replaced with a checkbox too.

The two checkboxes allow choosing whether to save text selection and
images into history. If there are images sent to primary selection, they
are included when both checkboxes are checked, so it is not possible to
include them in history but not include text selection in history. It is
doubtful such a combination of settings will be missed.

The explanations texts are changed too. We now talk about images,
because that is what non-text data in practice is. We note that
Spectacle ignores this and explain the difference between Klipper
displaying preview of images when an image filepath is copied or when an
image is copied directly.

The explanations texts were slightly reworded and made accurately
describe what the code does.

The settings are now stored positively. It requires less code and is
easier to comprehend.

Old shortcuts are migrated from user configs with kconf_update.
Related: bug 348932

FIXED-IN: 6.8.0

M  +3    -3    appiumtests/applets/clipboardtest.py
M  +1    -1    klipper/autotests/klippertest.cpp
M  +27   -124  klipper/configdialog.cpp
M  +2    -20   klipper/configdialog.h
M  +5    -11   klipper/historymodel.cpp
M  +2    -3    klipper/historymodel.h
M  +7    -0    klipper/kconf_update/CMakeLists.txt
A  +33   -0    klipper/kconf_update/plasma6.8-replace-ignore-settings.cpp     [License: GPL(v2.0+)]
A  +7    -0    klipper/kconf_update/plasma6.8-replace-ignore-settings.upd
M  +9    -14   klipper/klipper.kcfg

https://invent.kde.org/plasma/plasma-workspace/-/commit/51890caa5a37cd47b8cdac349abfddaf3458c6c1