LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices

Reply
 
Search this Thread
Old 08-18-2009, 12:43 AM   #1
robsku
LQ Newbie
 
Registered: Jul 2009
Location: Helsinki
Distribution: Debian GNU/Linux & Fedora 7
Posts: 3

Rep: Reputation: 0
Question Is there terminal program that supports copy&paste with keyboard (read for specifics)


Hi everyone. I have a request for help on getting this one issue I have with terminal, mouse vs. keyboard and copy&paste, any solution will be highly appreciated and I will write about it on my linux related blog, so helping me is also spreading good information

My goal has been for some time now to eliminate all unnecessary mouse use wherever a way to do it more efficiently via keyboard can be found. So far I have moved to tiling window manager with full control via keyboard, learned the quite ok method implemented in Opera for mouseless browsing and found out even better method for FireFox via plugin named LoL (formerly HaH) & keyconfig.

After some thoughts I decided that currently the most annoying thing of those tasks that could be done better with keyboard if I knew how is copy&paste from and to terminal window with keyboard.

WHAT I NEED:
I think that most propably the solution can be found in some terminal emulator program that can be configured to allow copying an area of text to clipboard with keyboard - like you can do inside screen with exceptions that instead of having to run screen the functionality is in terminal and copying is not limited just to copy&paste within the terminal but it would copy the selection otherwise like when selecting area with mouse except that instead of mouse selection buffer it would copy to clipboard or if possible to selection buffer *and* clipboard (copy available via keyboard would not be any useful if I had to move my hand to mouse for pasting the text from selection buffer anyway).

My preferences and dislikes among terminal programs (these are just preferences, anything that works will do):
I dislike Gnome Terminal, Konsole or any other with default look that has anything unnecessary visible by default, I also dislike predefined keybindings in terminal - except if there is an easy way to rebind and/or disable any of them - terminals that I would prefer if any of them can achieve what I want are xterm, rxvt/urxvt, aterm, eterm and any similiar to them and I could also stand using Terminator if it can do what I want and none of others can and if absolutely necessary I could use any terminal at all if I can hide away any possible menus & anything else than the text area itself and disable/rebind any and all possible keybindings except ones for copy&paste naturally.
 
Old 08-18-2009, 02:11 AM   #2
mark_alfred
Senior Member
 
Registered: Jul 2003
Location: Toronto, Ontario, Canada
Distribution: Ubuntu Linux
Posts: 1,033

Rep: Reputation: 95
I think it'll be difficult to do much with xterm. With konsole, and with openoffice.org, I did have some luck. For instance, I opened both openoffice.org, and konsole, and typed some stuff in openoffice. I then pressed F8, allowing for keyboard selection, and then pressed the arrow keys to select some of the text that I typed. I then copied this selection with Ctrl-C. Then, pressing Alt-Tab (or Alt-Shift-Tab), I selected konsole. I used konsole's paste keybinding (Shift-Insert) to paste the selected text from openoffice.org into konsole. So, using only a keyboard, I was able to select some specifically chosen text from a program (OOo), and paste it into a terminal (konsole).

The problem, though, is many programs don't have such key bindings associated with them. I don't think xterm has any capacity for pasting besides using the middle mouse button. And programs that can select text via a keyboard (other than select all, which is usally Ctrl-A) for copying are quite rare.

(later..) I found something else. Using xclip (you'd need to install this program), you can copy and paste to different xterms. For instance:

Code:
mark@debian:~$ echo Hello World | xclip -i
mark@debian:~$ xclip -o
Hello World
This works whether it is with the same xterm, or if it is between two different xterms.

It can be done from xterm to other programs, too, with the following:

Code:
echo Hello World | xclip -i -selection clipboard
This will copy the typed phrase ("Hello World") onto the clipboard. Then, you can paste this phase into any text program, such as gedit, or openoffice.org, via Ctrl-V. This doesn't work between different xterms, though (it ends up copying the entire line, for some reason).

Note: the keybindings I described above were while using fluxbox. They're reasonably common keybindings (IE, Ctrl-V for paste), but these may be different for whatever tiling window manager you're using.

Last edited by mark_alfred; 08-19-2009 at 11:50 PM.
 
  


Reply

Tags
binding, keyboard, terminal


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Looking for light terminal that supports copy and paste to other applications bbmak Linux - Newbie 10 09-27-2009 03:37 PM
copy and paste in a terminal? BmxFace Linux - General 5 06-29-2003 05:08 AM
copy and paste in terminal bash Linux - Software 3 07-08-2002 08:11 PM
Copy & Paste to Terminal monowar Linux - Newbie 1 07-02-2002 11:22 AM
copy&paste with keyboard? doublefailure Linux - General 5 03-31-2002 03:18 PM


All times are GMT -5. The time now is 09:43 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration