20 releases
0.2.0-rc2 | Nov 18, 2023 |
---|---|
0.1.2 | Apr 3, 2023 |
0.1.1 | Mar 30, 2023 |
0.0.14 | Mar 7, 2020 |
0.0.7 | Feb 5, 2017 |
#21 in Hardware support
4,354 downloads per month
Used in 38 crates
(31 directly)
195KB
4.5K
SLoC
enigo
Cross platform input simulation in Rust!
- Linux (X11) mouse
- Linux (X11) text
- Linux (Wayland) mouse
- Linux (Wayland) text
- MacOS mouse
- MacOS text
- Win mouse
- Win text
- Serialize/Deserialize
let mut enigo = Enigo::new(&Settings::default()).unwrap();
enigo.move_mouse(500, 200, Abs).unwrap();
enigo.button(Button::Left, Click).unwrap();
enigo.text("Hello World! here is a lot of text ❤️").unwrap();
For more look at the examples.
Runtime dependencies
Linux users may have to install libxdo-dev
if they are using X11
. For example, on Debian-based distros:
apt-get install libxdo-dev
On Arch:
pacman -S xdotool
On Fedora:
dnf install libX11-devel libxdo-devel
On Gentoo:
emerge -a xdotool
Migrating from a previous version
Please have a look at our changelog to find out what you have to do, if you used a previous version.
Permissions
Some platforms have security measures in place to prevent programs from entering keys or controlling the mouse. Have a look at the permissions documentation to see what you need to do to allow it.
Dependencies
~0–48MB
~702K SLoC