Newly copied text placed in 2nd position of clipboard

Somewhere within recent plasma 6 updates, my better half started having a strange issue with copy/paste… where basically a new “copy” is not recorded as the “last” copy (first entry in clipboard), but rather the second last copy (second entry in clipboard).

So to copy and paste a new string, she has to do the following:

  1. Highlight and copy string
  2. Super-V to open clipboard, note the new copy is in position #2, select it to be the string to paste (making it now the 1st entry)
  3. Paste the correct string

If she skips step 2, she will paste the previous copy that is still in position #1.

My searches online and in the forum have revealed nothing… perhaps the words I’m using are different from how others have described it.

How can I troubleshoot this?

  • Is there a clipboard conf file I can inspect? I looked through the clipboard plasmoid settings, but nothing I saw there seemed related.
  • Might there be a plasma config/cache file she could try delete?
  • Is it possible that the file that holds the copy history is corrupt and deleting it might fix the issue? If so, what is the files full path/name?

Operating System: Manjaro Linux
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.5.0
Qt Version: 6.7.2
Kernel Version: 6.6.46-1-MANJARO (64-bit)
Graphics Platform: Wayland (Issue duplicated in X11 as well)
Processors: AMD APU
Memory: 32 GiB of RAM

As a potential workaround, the Clipboard widget seems to work as expected.

Well it appears typing out the issue and troubleshooting ideas provided a solution.

I found the clipboard history file @ /home/<uid>/.local/share/klipper/history2.lst; however simply deleting/renaming it didn’t purge what was in memory as clicking the clipboard plasmoid/widget was still populated… so I clicked the “broom” to clear all history and it recreated an empty file.

Now she has gone through a few copy pates, and it is working perfectly fine.

What I suspect happened is that at one point she copied something with a “special character” that confused klipper; making it think that top entry was somehow the “start of the file” and so everything she copied next was shoved into position #2.

Anyway, all that to say that the fix was to:

  1. Click the clipboard plasmoid/widget
  2. Click the broom to clear history
  3. Click the Delete button to confirm the purging
1 Like

You cannot. It’s a bug in Plasma itself, but it manifests only on X11.

On Wayland, the clipboard behavior in Plasma 6.0.5 is even worse. If you highlight something with the mouse, then your cllipboard will be filled with every step of the highlighting.

In other words, say that you highlight the word “Manjaro” with the mouse by marking it — not double-clicking. The clipboard will then contain the following entries…

Manjaro
Manjar
Manja
Manj
Man
Ma
M

Which clipboard are you using? I’ve never encountered that issue on my Plasma 6 Wayland desktop. The only clipboard I have installed on my mini-PC is wl-clipboard.

The default Plasma clipboard. I think it’s called klipper.

03

The default Plasma 6 clipboard is wl-clipboard. Klipper is 3D-printer firmware. You might still have one of the x-org clipboards installed: xclip or xorg-xclipboard.

My system setup is pretty basic though - no 32-bit libraries/apps, and I don’t think anything I use runs under Xwayland, so I don’t need any x-org clipboards.

Just a second - I just opened my clipboard settings from the system tray. I think you might need to uncheck the “Keep the selection and clipboard the same” box, although I just checked that box on my desktop & still couldn’t reproduce the issue.

Edit: Making sure the clipboard is set to only save in history when explicitly copied may also fix the problem.

I have that installed.

I have this installed as well, but it’s not a clipboard. It’s a tool for accessing the (X11) clipboard from the command line.

But I’ll remove it shortly. It’s still a leftover because I’ve only recently switched to Wayland.

I don’t have that installed.

I have always had that checked, but disabling that only means that if you mark something with the mouse, it won’t get copied to the clipboard, as is the behavior of the clipboard in Microsoft Windows.

In UNIX, marking something with the mouse — or with the keyboard — already copies it to the clipboard.

It may, but that should not be necessary — it never behaved the way as I’ve described in my previous post while on X11 — and in my experience, it then also does not automatically copy the selection to the clipboard.

I noticed I have this issue as well.
I hope it will be fixed soon.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.