-
Notifications
You must be signed in to change notification settings - Fork 112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not respect GNOME touchpad disable-while-typing settings #144
Comments
We're literally generating input on a keyboard device... I think you may want to file this upstream as a bug with Gnome and see what they say... |
Yes, this issue still exits since i last use xkeysnail, i leave it because this issue too, because i use on my laptop, if no after disable it, |
Please file this upstream as a bug against Gnome and then link us to that and I'd be happy to have a discussion with the Gnome people and see what the options might be (if any)... I have a feeling it's something only Gnome can fix (or tell us how)... either they count input from uinput as keyboard input, or perhaps there is a flag we need to set on the device to make them see it as a "keyboard worthy of note"... but only they would know. |
I create a issue here. https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/5530 though, don't sure if correct place. |
Sounds like now you're off to file a report against libinput and see what they say. :) |
Create a new issue here. https://gitlab.freedesktop.org/libinput/libinput/-/issues/778 |
Related: https://gitlab.freedesktop.org/libinput/libinput/-/issues/727 The answer over on libinput seems highly relevant. This is something we could probably fix in the future. We need to either:
This is made more complex by the fact that some users may be mapping MULTIPLE real keyboards onto a single virtual output keyboard - not all of them internal... so the trackpad should be disabled only for SOME inputs but not others. Until then I'd suggest reading the linked issue and trying what it suggests with |
Or if you're comfortable hacking the source you could try changing the constructor on
You'd want to try passing the same vendor/product/version/bus as your existing internal hardware keyboard. Sorry I'm not 100% sure where you get all those numbers. |
Sorry, could not find same code in this file in git version or 0.4.0 package install version. |
I guess following tree device is about keyboard, touchpad and Mouse.
If there is info needed? @joshgoebel Thank you. |
It's in the keysnail directory... https://github.com/mooz/xkeysnail/blob/master/xkeysnail/output.py |
Sorry, where is the python constructor? please see following screenshot. |
UInput constructor on line 30... |
Sorry, still don't know what you means, i am not clear to change what for which file ... |
If I knew exactly what to do I'd show you, but I'd have to figure it out myself... the constructor is on line 30...
if you Google the evdev Python docs you should see what arguments the constructor wants, how to pass configuration information to it such that is pretends to be a different type of keyboard, etc... At that point you'd have to play with it... if that's all greek to you then you're probably not going to make progress here and will have to wait for someone else to come along to asist. |
Sorry, i guess i have ability to do this, but, i don't know what you means exactly where to do those changes.
This should be which file, which line? What ever please check following screenshot. |
https://github.com/mooz/xkeysnail/blob/master/xkeysnail/output.py#L30 It's right there, line 30. |
Following is my interal keyboard " AT Translated Set 2 keyboard (BUS_I8042)" info, which use
It seem like not recognize my internal keyboard as usb device. because |
@zw963 Try this (and post info here):
Then try copying all those details into the new UInput device... see an example here: What they are doing automatically you are just wanting to do by hand... and see if it helps... Or if you're familiar enough with Python you could try just hacking it to manually copy from your keyboard device (as I show you at the top of this message). It might be all you need is phys and bustype, I'm not really sure... one thing I read said that it just needs to think the keyboard is internal, which should happen if you switch the bustype to PS/2 (maybe?). |
If you manage to get it working we can see about adding this "cloning" functionality, but we'd need a way to specify WHICH keyboard to clone since technically a user can have LOTS of keyboards... and for people with more than 1 there might not be a correct answer - but I'm not sure we could solve that. |
Following is my output result: import evdev
# this is my interal keyboard device
device = evdev.InputDevice("/dev/input/event3")
print(device.phys)
print(device.info.vendor)
print(device.info.product)
print(device.info.version)
print(device.info.bustype)
print(device.input_props())
Then i change code in xkeysnail/output.py#L30 to: please see following screenshot. Could you please check to ensure i do correct changes? Thank you very much. |
BTW: i run above same python script on my two different laptop, one hp zbook, one lg gram, even, one use Xorg, another use Wayland, and different event device, but all get exact same value, why? And, both laptop install latest arch linux + GNOME, but, one xorg, another wayland. |
Looks right, did it help any? Is xkeysnail being started BEFORE the desktop environment or after? |
i use a user systemd file, correct?
|
Hmmm... so it's needed by the graphics target, but does it load first? I don't know - also not sure if that matters... |
Okay, thank you very much, i will testt this config in recent days, will report here |
I have to change to following to make xkeysnail start to work
Now, service is started.
|
@joshgoebel , could you please give me some clue about how to make xkeysnail start when system is boot? current the issue is, i use a user systemd, after reboot, it start failed because
Yes, i consider this is a file permission issue, so, i have to wrap xkeysnail use another bash wrapper script, and run following command before really run xkeysnail. sudo chmod 0666 /dev/input/event* /dev/uinput But, this bash wrapper script could not start correct because possible sudo , it not work, get above error. But, i can correct up manually use Following is my systemd file
|
I would not recommend that. I think optimally the best way to do this is to let I'll probably have more to say here next week. I believe I've just gotten my fork to the point where it's usable so pretty soon I'll be figuring out solid ideas on how people SHOULD run it...
Did making those changes indeed help with your Gnome ignore input issue or is the jury still out? |
In fact, my $USER is a member of input, and /dev/uinput group is input too, but still not start correct, but, whatever, i start it my my ~/.profile, only once, it works anyway, thank you very much.
i just try to use it in my another laptop very few time yesterday, it seem like fixed, but i still need more time to ensure this. |
I don't recommend that either - that allows any software on your computer to potentially log all your keystrokes, passwords, emails, etc... there is a reason users don't usually have access to the raw input devices. |
If |
@joshgoebel , Hi, though, recent days, because busy, not used to much my another laptop for test this issue, but, i think this hack works! because, if not do this hack, my another laptop (big touchpad LGRAM 17) will skip almost make people crazy. but it not since a enable this hack. Thank you very much for you help, so, when we will fix this in xkeysnail? |
Possibly never. For all intents and purposes xkeysnail seems effectively unmaintained. I am however the maintainer of the fork/reboot keyszer... so if you wanted to open an issue against that project (and link back here).... I think there is definitely room for something like this long-term... a "masquerade as" option... I wouldn't say it's a super high priority though. However, I think my fork actually has the hook you would need to fix this from just your config file... look at my_uinput = UInput(events={ecodes.EV_KEY: _keyboard_codes,
ecodes.EV_REL: set([0,1,6,8,9]),
},
name="mykeyboarddevice",
phys="isa0060/serio0/input0",
vendor=1,
product=1,
version=43841,
bustype=17,
input_props=[])
from keyszer.output import setup_uinput
setup_uinput(my_uinput) Just put that at the top of your config and I think it might work. It's still a bit early but I've been using my fork 24/7 for several days... there are still some unresolved issues ( you may want to look thru them)... if you'd like to give it a shot, feel free. You can install it from You'd obviously have to import |
When enable xkeysnail, following GNOME settings will become invalid.
this feature very useful for user who use laptop which exists a big touchpad, and user use laptop keyboard typing directly.
The text was updated successfully, but these errors were encountered: