Bug 162625

Summary: Ability to cancel paste operation
Product: [Applications] konsole Reporter: Stefan Neufeind <kde>
Component: copy-pasteAssignee: Konsole Developer <konsole-devel>
Status: RESOLVED FIXED    
Severity: wishlist CC: adaptee
Priority: LO    
Version: unspecified   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
Latest Commit: Version Fixed In: 4.11
Sentry Crash Report:

Description Stefan Neufeind 2008-05-26 00:24:51 UTC
Version:            (using KDE 4.0.4)
Installed from:    Fedora RPMs

occured to me lately that I wanted to select "copy" from the context-menu but accidentally chose "paste". However since I had a whole bunch in the clipboard at that time, only chance was to close that konsole by force.

It would be great to somehow be able to cancel a running "paste". Maybe just by chosing "paste" again (maybe through the menu on the top) or something?
Comment 1 Robert Knight 2008-06-02 08:24:43 UTC
The real bug here is that 'Paste' is so slow.  It should be instant.
Comment 2 Stefan Neufeind 2008-06-02 10:21:02 UTC
Hmm well, in case you use the console to paste 5mbyte over a slow ssh-link a possibility to cancel (instead of killing the console) would be nice.

About it being "slow", maybe you should file a separate bug for that?
Comment 3 Robert Knight 2008-06-02 12:22:38 UTC
> Hmm well, in case you use the console to paste 5mbyte
>  over a slow ssh-link a possibility to cancel
> (instead of killing the console) would be nice. 

True.  I was thinking of pasting into a local application.  In that case yes, the ability to cancel paste would be useful.

Comment 4 Jekyll Wu 2012-05-13 12:28:29 UTC
Canceling an pasting operation is hard in current implementation, because all those text are sent within one simulated keyevent.

Well, I think the real problem reflected in this report is pasting many lines into an terminal emulator is usually an misoperation instead of an intended operation. It is better for konsole to do some check based upon common sense(the pasted text is over 1000 lines?) before doing the paste, and ask users for confirmation that they really want to paste so many lines.
Comment 5 Kurt Hindenburg 2012-12-22 02:54:53 UTC
Git commit e45674ae3fd1c6ef50332e3fc7dfc66f5562c8e2 by Kurt Hindenburg.
Committed on 22/12/2012 at 03:53.
Pushed by hindenburg into branch 'master'.

Add Dialog warning when huge amounts of text is about to be pasted

Currently there is no way to stop an accidently paste into the terminal.
This patch adds a dialog when 8000+ characters are pasted asking if
the user really wants to do this.  At most the user will see this once
as there is a "Don't show again" box.
REVIEW: 107570
FIXED-IN: 4.11
GUI:

M  +12   -0    src/TerminalDisplay.cpp

http://commits.kde.org/konsole/e45674ae3fd1c6ef50332e3fc7dfc66f5562c8e2
Comment 6 Kurt Hindenburg 2012-12-22 03:26:38 UTC
Git commit 92019daad53e389c0736a29843e0c1e0242f3126 by Kurt Hindenburg.
Committed on 22/12/2012 at 04:13.
Pushed by hindenburg into branch 'master'.

Add Dialog warning when huge amounts of text is about to be pasted

Currently there is no way to stop an accidently paste into the terminal.
This patch adds a dialog when 8000+ characters are pasted asking if
the user really wants to do this.  At most the user will see this once
as there is a "Don't show again" box.

Previously commit trigger a sysadmin issue.
REVIEW: 107570
FIXED-IN: 4.11
GUI:

M  +12   -0    src/TerminalDisplay.cpp

http://commits.kde.org/konsole/92019daad53e389c0736a29843e0c1e0242f3126