On Monday 12 April 2004 16:01, Elmar Höfner wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > This might be usefull for some of you: > > To translate a highlighted word using a mouse gesture, do the following: > > 1) Create a script with these lines (or just copy&paste): > > ##start here > WORD=`dcop klipper klipper getClipboardContents` > konqueror http://dict.leo.org/?search=$WORD & > exit 0 > ## end here > > name it e.g. 'translator', make it executable and copy it to /usr/local/bin > (if you want systemwide access). DON'T ADD '#!/bin/sh' in the first line! > > 2) Using KHotkeys, select 'new action' and name it 'translate'. > 3) Define a trigger you can easily remember. I used "74159", this is a > hook-shaped gesture. > 4) As Action, define "Command/URL: translator" > 5) Ready. You can use this gesture anywhere, the word added last in the > clipboard (=last highlighted word) will be sent to LEO for German/English > or English/German translation. > 6) If you want other things happen to the highlighted word, change the URL > in the script. I got this from Konqui's web shortcuts: replace "[EMAIL > PROTECTED]" with > "$WORD". > > Bye, > Elmar >
Thanks for the nice tip! However I'm not able to get mouse gestures working in general. :/ Are there any special requirements (e.g. extra packages)? The khotkeys feature appears in kcontrol and I'm able to setup new gestures; the khotkeys daemon should be up and running as well ('disable' box isnt' checked). Maybe my hands are too tremulous for proper gestures. ;-) KDE version: 3.2.1 Regards, Tobias