-
Notifications
You must be signed in to change notification settings - Fork 111
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
Send virtual key events to a specifc process/PID ? #118
Comments
I do not know how that would be possible. At least for Linux Wayland I don't think it would work because none of the protocols seem to allow choosing the window. If anyone knows how this could be achieved, please let me know. |
It might be possible under Windows (not sure, my memory of the windows api fades over the years :P) and i am also quite sure its not possible under Linux. This also opens the question how do we proceed with things that are not possible on all supported platforms. |
Under Linux X11 it seems to be possible. At least the xdotools man page says:
And it includes a few examples:
|
I am not familiar with Windows, but I found this: |
It also looks like it is possible with macOS. There is post_to_pid, so we should be able to send the events to a specific process/window. |
Describe your Question
Want to send key events to a specific process/PID/Window.
Describe your Goal
Use reddit on one monitor while my bot sends virtual key-presses to another window of my choosing.
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: