3

How does (where is) the the cut&paste function for PUTTY under Ubuntu ?

EDIT: source text is not in the PUTTY window.

EDIT: Found the problem: the source text is in a Google Chrome tab which does not support "cutting" (at least for now).

EDIT: mea culpa: I realize now that SSH is preferred under Linux.

jldupont
  • 6,864

6 Answers6

4

You can use the right mouse button to copy it, then click the middle mouse button (wheel) to paste.

2

I solved this issue using 2 methods:

1. Using PuTTY Linux version:

Clicking both touchpad buttons, I simulated the middle button.

I needed to enable it manually, since the Linux Mint distro I'm using had not this middle button simulation activated. The latest version of evdev, version 2.5, changed the default for the middle mouse button emulation code. This change has disabled emulation of the middle mouse button by clicking the left and right mouse buttons.

To enable the middle mouse button emulation, add this to xorg.conf:

Section "InputClass"
Identifier "middle button emulation class"
MatchIsPointer "on"
Option "Emulate3Buttons" "on"
EndSection

2. Using PuTTY Windows version

I prefer that since I do not need to change distro settings like Xorg, only Wine settings in order to connect to console serial ports:

Since Wine handles com ports by having a link to the device (i.e. /dev/ttyUSB0), in the ~/.wine/dosdevices folder, this link would be created as follows, in order to update your wine profile configs:

ln -s /dev/ttyUSB0 ~/.wine/dosdevices/com1

I prefer this second method. Since copying and pasting always works, I do not need the middle button simulation and, the cherry on top of the cake, it NEVER hangs (occasionally PuTTY hangs on some Windows XP installations).

Otherwise, in case you do not need/want to install Wine, the first method is preferable.

slhck
  • 235,242
Joao
  • 21
2

In Ubuntu 12.04, I was able to paste using Ctrl + Shift + Insert after copying text from a Firefox window or text editor.

1

I replaced all occurences of GDK_SELECTION_PRIMARY with GDK_SELECTION_CLIPBOARD in unix/gtkwin.c and unix/gtkdlg.c in the sources, then recompiled. I also had to add '#include "../proxy.h"' to unix/uxproxy.c to get it to recompile, but that's maybe because I'm on FreeBSD.

Anyway, the end result is that it recompiled, and works with the more-or-less expected behaviour.

soandos
  • 24,600
  • 29
  • 105
  • 136
Louis
  • 11
1

One other thing to watch out for (which I just learned about) is that on desktop Linux there are often two different "clipboards" that text can be copied to: X/X11 clipboard and the Gnome/GTK clipboard. This threw me for a bit. I could paste text into some windows, but depending on where I copied it from I couldn't paste in to Putty.

Basically, some applications handle the multiple clipboards and some do not. A few solutions can be found here:
How can I merge the gnome clipboard and the X selection?

One of the most popular programs for syncing both clipboards is autocutsel.

0

Just highlight the text for copy and right click for paste.

user10547
  • 1,115