Bug 429418 - Cannot paste text copied from GTK apps into Kate
Summary: Cannot paste text copied from GTK apps into Kate
Status: RESOLVED UPSTREAM
Alias: None
Product: kate
Classification: Applications
Component: general (show other bugs)
Version: 20.08.3
Platform: Debian testing Linux
: NOR normal
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
: 381997 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-11-20 21:53 UTC by David
Modified: 2022-11-03 17:31 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David 2020-11-20 21:53:59 UTC
SUMMARY
For some reason, I cannot copy large amounts of text from GTK appa into Kate/KWrite. Pastying works correctly if the text is copied from a QT text editor though.

STEPS TO REPRODUCE
1. Create a large text file with >10k lines (e.g. this: https://github.com/david-cortes/cmfrec/blob/master/src/collective.c).
2. Open said file in e.g. gedit or sublime.
3. Launch a kate/kwrite window.
4. Paste the text into kate/write. 

OBSERVED RESULT
Nothing happens

EXPECTED RESULT
Should paste the copied text

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 5.19.5
KDE Frameworks Version: 5.74.0
Qt Version: 5.15.1

ADDITIONAL INFORMATION
Comment 1 David 2020-11-20 21:55:38 UTC
Sory missing step:

STEPS TO REPRODUCE
1. Create a large text file with >10k lines (e.g. this: https://github.com/david-cortes/cmfrec/blob/master/src/collective.c).
2. Open said file in e.g. gedit or sublime (GTK text editors).
3. Select all text from that file in the text editor and copy it to the clipboard.
4. Launch a kate/kwrite window.
5. Paste the text into kate/write.
Comment 2 Justin Zobel 2020-11-21 11:35:36 UTC
Thanks for the report David, I've just tested this with Kate 20.08.3 and gedit 3.36.2 on openSUSE and I am unable to replicate this issue, the text is pasted immediately.

Are you able to test with a fresh user and if that also fails with a live ISO of another distro like openSUSE Tumbleweed?
Comment 3 David 2020-11-21 18:03:06 UTC
(In reply to Justin Zobel from comment #2)
> Thanks for the report David, I've just tested this with Kate 20.08.3 and
> gedit 3.36.2 on openSUSE and I am unable to replicate this issue, the text
> is pasted immediately.
> 
> Are you able to test with a fresh user and if that also fails with a live
> ISO of another distro like openSUSE Tumbleweed?

Bug is still present in openSUSE-Tumbleweed-KDE-Live-x86_64-Snapshot20201117-Media
Comment 4 Justin Zobel 2020-11-22 02:12:06 UTC
Information provided.
Comment 5 Christoph Cullmann 2021-03-31 20:49:10 UTC
True, doesn't work.

 QApplication::clipboard()->text(QClipboard::Clipboard)

just doesn't return the text :/
Comment 6 Christoph Cullmann 2021-03-31 21:05:11 UTC
Yeah, Qt issue, Qt Creator can't paste that either...
Comment 7 Christoph Cullmann 2021-04-04 18:47:09 UTC
*** Bug 381997 has been marked as a duplicate of this bug. ***
Comment 8 Szczepan Hołyszewski 2021-06-18 13:43:05 UTC
Is there a Qt issue on their tracker that I can follow?
Comment 9 Eric Armbruster 2022-11-02 11:58:07 UTC
I cannot reproduce with Kate 22.08 and Plasma 5.26. Is this still an issue?
Comment 10 Justin Zobel 2022-11-02 22:17:02 UTC
Same I can no longer reproduce this issue with the file, copying from gedit to write 22.08.1, Qt 5.15.6 on Fedora 37.

Can anyone else who was experiencing the issue still reproduce it?
Comment 11 Greg Lepore 2022-11-03 11:30:04 UTC
Issue appears fixed to me, I was able to copy several megabytes of data from Firefox to Kate with no problems. Previously this would fail.
Comment 12 David 2022-11-03 17:31:16 UTC
Not reproducible anymore.