Using keys instead of mouse buttons, possible?
-
- Posts: 597
- Joined: Thu 13 Nov 2008, 13:45
Using keys instead of mouse buttons, possible?
I would be interested if there is a way to use keyboard shortcuts, for example alt-Z, X and C to emulate left, center and right mouse buttons.
Maybe MouseKeys — numeric keypad as a mouse replacement is what you need. Alt+Shift+NumLock and Shift+NumLock both can be used to (de)activate this feature on Lupu 525 (I didn't test it on other Puppies). It works but something is wrong with acceleration.
-
- Posts: 597
- Joined: Thu 13 Nov 2008, 13:45
-
- Posts: 597
- Joined: Thu 13 Nov 2008, 13:45
I don't remember that well because it was a while ago, but I do remember that it didn't do the job that well, at most it let you select between a couple of buttons on a menu. If it would have worked well I would have used it.
It comes already installed in some Puppies, and there are packages for others.
May I ask what to you need it for? I originally wanted it because most Puppies have poor support for Macbook touchpads, then I found FatDog64 600, which works very well on Macs, and lost interest in trying to emulate the buttons.
It comes already installed in some Puppies, and there are packages for others.
May I ask what to you need it for? I originally wanted it because most Puppies have poor support for Macbook touchpads, then I found FatDog64 600, which works very well on Macs, and lost interest in trying to emulate the buttons.
My 86 year old father is struggling with doubleclicking so I am looking for an alternative. I've just posted here:mini-jaguar wrote:May I ask what to you need it for? I originally wanted it because most Puppies have poor support for Macbook touchpads, then I found FatDog64 600, which works very well on Macs
http://murga-linux.com/puppy/viewtopic.php?t=82328.
That's interesting about fatdog - I have been looking at some of the external touchpads designed for MAC (they are beautiful..) and I think they would be a great alternative to a mouse. And with the tap-to-click function turned off it would be a good way to separate the "pointer motion" from the "clicking" if I added a second mouse modified to only have the click button function on it. That way I could reduce the chance of my dad dragging icons and folders where they should not be.
-
- Posts: 597
- Joined: Thu 13 Nov 2008, 13:45
Actually I used FatDog64 on a Macbook with a button, to activate the other button you hold two fingers on the touchpad while you click, I think you could even get the third button with three fingers (Ubuntu works the same way).
But FatDog64 is the only Puppy version that works with the Mac touchpad and doesn't have the tap on, all the other versions the touchpad either doesn't work at all or the tap is always on because flsynclient doesn't work properly with macs on them, which can really drive you up the wall.
Although I don't know if you're going to have much luck with this. You can set Puppy to use single clicks only on its own o.s., but you're talking internet stuff (in the other thread). I'm not sure though.
But FatDog64 is the only Puppy version that works with the Mac touchpad and doesn't have the tap on, all the other versions the touchpad either doesn't work at all or the tap is always on because flsynclient doesn't work properly with macs on them, which can really drive you up the wall.
Although I don't know if you're going to have much luck with this. You can set Puppy to use single clicks only on its own o.s., but you're talking internet stuff (in the other thread). I'm not sure though.
mini-jaguar and greengeek,
Perhaps you could make it work by using Xdotool.
Assign a hotkey to a script using xdotool to simulate mouse-clicks. Then place cursor where you want the click and then hit the script hotkey.
I haven't tried it, but it should work.
Cheers,
s
(You can find xdotool here
http://208.109.22.214/puppy/viewtopic.p ... 65aadf5f61 )
Perhaps you could make it work by using Xdotool.
Assign a hotkey to a script using xdotool to simulate mouse-clicks. Then place cursor where you want the click and then hit the script hotkey.
I haven't tried it, but it should work.
Cheers,
s
(You can find xdotool here
http://208.109.22.214/puppy/viewtopic.p ... 65aadf5f61 )
Thanks seaside. Xdotool looks very interesting. My scripting ability is in it's infancy (actually pre-embryonic is a better word...) but I will dig up some xdotool tutorials and see what is possible.seaside wrote:Perhaps you could make it work by using Xdotool.
EDIT: I think what I would need to do is:
1) Assign F9 key (which is the key I want to use as my "doubleclick" function) as a hotkey to run xdotool script.
2) Execute xdotool script that emulates the key sequence which activates Mousekeys function of xorg (ie: "shift numlock"), delays x milliseconds, then emulates depression of "+" key.
- one issue for me to figure out is how I differentiate between "+" on the numeric keypad and "+" on the "=" key. I shall look into this more closely.
EDIT AGAIN: mini-jaguar: these links look like they might be helpful for both your original requirements and mine too:
http://tuxradar.com/content/xdotool-script-your-mouse
http://www.semicomplete.com/projects/xd ... tool.xhtml
Actually, it turns out I don't even need to activate the "ShiftNumlock". It works as required if I do the following:
1) Place cursor over the email I want to open.
2) Type "xdotool click 1 click 1" in a previously opened terminal.
(xdotool has the ability to simulate mouse clicks directly)
All I need to do now is write that into a script and attach it to the F9 key.
Notes:
click 1 = single left click
click 2 = single middle click
click 3 = single right click
click 1 click 1 = two left clicks separated by 12millisecond delay (= doubleclick)
Thanks seaside - this feels like powerful stuff!
1) Place cursor over the email I want to open.
2) Type "xdotool click 1 click 1" in a previously opened terminal.
(xdotool has the ability to simulate mouse clicks directly)
All I need to do now is write that into a script and attach it to the F9 key.
Notes:
click 1 = single left click
click 2 = single middle click
click 3 = single right click
click 1 click 1 = two left clicks separated by 12millisecond delay (= doubleclick)
Thanks seaside - this feels like powerful stuff!
Ive got the doubleclick function working as I want it to now. I have assigned it to the F9 key.
1) First I made a script called doubleclick_xdotool as follows:
I placed this script in /usr/bin and made it executable (by rightclicking and selecting permissions)
2) Then I assigned a hotkey function to the F9 key. This was harder than I expected (haven’t done this before) but I got some tips from here:
http://www.murga-linux.com/puppy/viewtopic.php?t=57085
What I did was to make a backup of /root/.jwm/jwmrc-personal then edit it to add the following line to the list of other Key lines:
(keycode 75 is the code for the F9 key)
Then I restarted the jwm and now I can press F9 any time I want the doubleclick function. Just have to make sure the mouse pointer is sitting where I want it before I press the F9 key.
Thanks all for the suggestions.
1) First I made a script called doubleclick_xdotool as follows:
Code: Select all
#!/bin/sh
xdotool click 1 click 1
2) Then I assigned a hotkey function to the F9 key. This was harder than I expected (haven’t done this before) but I got some tips from here:
http://www.murga-linux.com/puppy/viewtopic.php?t=57085
What I did was to make a backup of /root/.jwm/jwmrc-personal then edit it to add the following line to the list of other Key lines:
Code: Select all
<Key keycode="75">exec:doubleclick_xdotool</Key>
(keycode 75 is the code for the F9 key)
Then I restarted the jwm and now I can press F9 any time I want the doubleclick function. Just have to make sure the mouse pointer is sitting where I want it before I press the F9 key.
Thanks all for the suggestions.