Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 03-18-2005, 05:36 AM   #1
Registered: Jul 2003
Location: Sri Lanka
Distribution: Mandrake
Posts: 99

Rep: Reputation: 15
Read KDE clipboard content


Is there anyway that I could get the content of the clipboard (I use KDE) inside a shellscript? I want to copy the content of the clipboard to a file programatically.


Old 03-18-2005, 06:25 AM   #2
LQ Newbie
Registered: Mar 2005
Location: Ourense, Spain, EU
Distribution: Gentoo, Debian, Kubuntu
Posts: 29

Rep: Reputation: 15
Try this

$dcop klipper klipper getClipboardContents

Last edited by rgawenda; 03-19-2005 at 06:43 AM.
Old 03-20-2005, 09:54 PM   #3
Registered: Jul 2003
Location: Sri Lanka
Distribution: Mandrake
Posts: 99

Original Poster
Rep: Reputation: 15
Hey, this is great. I just managed to configure Festival (speach synthesizer) to read the contents of the clipboard. If any body is interested, the shell script is

dcop klipper klipper getClipboardContents > $HOME/festivaltext
festival --tts $HOME/festivaltext

I have Mandrake 10.0 and have festival, and festvox rpms installed.

I created an icon in the taskbar to call this shellscript. So now when I want to read text, all I need to do is select the text in any application, right click and copy to clipboard and then click the shortcut to the above shellscript and Festival will read it aloud. There maybe better and more efficient ways to do it but this is the best I could find.


Old 05-10-2005, 12:12 PM   #4
Registered: Feb 2003
Location: Orangeville
Distribution: Fedora
Posts: 469

Rep: Reputation: 31
Read and Write Gnome Clipboard

Do you know how to read and write to the gnome clipboard through a shell script?


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 On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
how to add content to KDE help center of SuSE Linux zhaosj SUSE / openSUSE 1 11-14-2005 02:43 AM
How to manually modify the content of the K menu in KDE? pujolasdf Linux - Software 2 03-27-2005 11:26 AM
Read clipboard from console drj000 Linux - Software 2 02-23-2005 11:00 PM
KDE clipboard problem 286 Linux - Newbie 0 01-17-2004 01:33 PM
libqt3-mt partitial content kde 3.1.4 eduac Linux - General 0 12-31-2003 08:08 AM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:45 PM.

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