Need keystroke to send doubleClick plus control+C

Booting, installing, newbie
Post Reply
Message
Author
kerl
Posts: 154
Joined: Tue 16 Apr 2013, 21:15

Need keystroke to send doubleClick plus control+C

#1 Post by kerl »

How could I send a double click plus a "Control+C" by pressing "Control+leftShift" ?

The idea is that ctrl+shift can be performed quickly with your left hand whilst ctrl+c requires your two hands.

FYI I want this keystroke while using GoldenDict where the popoup based on ocr detection does not work any more on midern web browsers.
I think this ctrl+shift keystroke would do as a workaround.

Thanks in advance
Last edited by kerl on Tue 07 Nov 2017, 14:31, edited 1 time in total.

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#2 Post by Burn_IT »

here are plenty of tools to remap your keyboard. The only problem is that they tend to be at OS/driver level not at the hardware level.
"Just think of it as leaving early to avoid the rush" - T Pratchett

kerl
Posts: 154
Joined: Tue 16 Apr 2013, 21:15

#3 Post by kerl »

I've just coded this for Mswindows if you want to give it a try:
http://lilfile.com/m2WIZW
it's practical for Goldendict under winXP (just mouse over a word and press control+shift)
unfortunately it does not work under wine

jamesbond
Posts: 3433
Joined: Mon 26 Feb 2007, 05:02
Location: The Blue Marble

#4 Post by jamesbond »

Since you can code, perhaps you want to look at doing it at uinput level. Here's an example: https://stackoverflow.com/questions/266 ... e#27166484.

There is another mapping daemon called evmapd, but last time I tried it didn't work properly; and I sort of lost patience. There is another one which is newer but I can't recall the name at the moment.

Probably not the answer you want to hear, but anyway.
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]

kerl
Posts: 154
Joined: Tue 16 Apr 2013, 21:15

#5 Post by kerl »

Hi Jamesbond.

I can only code a bit on Basic dialect languages which deal with Windows :)

Do you know some automation tool for Linux? I've just run into Actiona
https://wiki.actiona.tools/doku.php?id=en:start
an open source tool with binaries for Ubuntu and Debian.
Last edited by kerl on Wed 08 Nov 2017, 10:24, edited 1 time in total.

User avatar
smokey01
Posts: 2813
Joined: Sat 30 Dec 2006, 23:15
Location: South Australia :-(
Contact:

#6 Post by smokey01 »

Xdotool.

kerl
Posts: 154
Joined: Tue 16 Apr 2013, 21:15

#7 Post by kerl »

smokey01 wrote:Xdotool.
thanks! though my intention would be launching a Xdotool script and leave it in background, so that everytime my keystroke is intercepted, the same commands,clicks,etc would be performed..
Last edited by kerl on Wed 08 Nov 2017, 10:24, edited 1 time in total.

kerl
Posts: 154
Joined: Tue 16 Apr 2013, 21:15

#8 Post by kerl »

this might work

Code: Select all

#!/bin/sh 
xdotool click 1 click 1 key ctrl+c key ctrl+c
but how can I assign a keyboard shortcut to launch the bash script ?
Last edited by kerl on Wed 08 Nov 2017, 10:21, edited 2 times in total.

kerl
Posts: 154
Joined: Tue 16 Apr 2013, 21:15

#9 Post by kerl »

kerl wrote:this will do

Code: Select all

#!/bin/sh 
xdotool click 1 click 1 key ctrl+c key ctrl+c
but how can I assign a keyboard shortcut to launch the .sh ?
How to Open any file via Keyboard Shortcut.
An example for Puppies based on Xfce :

Code: Select all

Open your Keyboard Settings: Menu > Settings > Keyboard > Application Shortcuts
Add a new shortcut with the following command and shortcut:
exo-open --launch TerminalEmulator /home/david/openfile.sh
CTRL + SHIFT + ALT + O
However the above xdotool script leads to hang the system.

Post Reply