diff -Nur ydotool-1.0.1-orig/manpage/ydotool.1.scd ydotool-1.0.1/manpage/ydotool.1.scd
--- ydotool-1.0.1-orig/manpage/ydotool.1.scd 2022-02-16 19:38:49.000000000 +1000
+++ ydotool-1.0.1/manpage/ydotool.1.scd 2022-03-21 14:46:37.916103638 +1000
@@ -1,12 +1,11 @@
YDOTOOL(1)
-
# NAME
ydotool - command-line _/dev/uinput_ automation tool
# SYNOPSIS
-*ydotool* *cmd* _args_ [ , *cmd* _args_ ... ]
+*ydotool* *cmd* _args_
*ydotool* *cmd* --help
@@ -14,8 +13,6 @@
*ydotool* lets you programmatically (or manually) simulate keyboard input and mouse activity, etc. It does this by writing directly to _/dev/uinput_ so it generally needs to run as root.
-It's possible to chain multiple commands together, separated by a comma between two spaces.
-
Currently implemented command(s):
*type*
@@ -26,67 +23,37 @@
Move mouse pointer to absolute position
*click*
Click on mouse buttons
-*recorder*
- Record/replay input events
-*sleep*
- sleep for a while
# KEYBOARD COMMANDS
-*key* [*--up*] [*--down*] [*--next-delay* _<ms>_] [*--key-delay* _<ms>_] [*--repeat* _<times>_] [*--repeat-delay <ms>*] _<key sequence>_
+*key* [*-d*,*--key-delay* _<ms>_] [_<KEYCODE:PRESSED>_ ...]
- Type a given keystroke. Examples being "alt+r", "ctrl+J",
- "ctrl+alt+n", "backspace".
+ Type a given keycode.
+
+ e.g. 28:1 28:0 means pressing on the Enter button on a standard US keyboard.
- Options:
+ 42:1 38:1 38:0 24:1 24:0 38:1 38:0 42:0 - "LOL"
- *--up*
- Only keyup
-
- *--down*
- Only keydown
+ Non-interpretable values, such as 0, aaa, l0l, will only cause a delay.
- *--delay* _<ms>_
- Delay before starting to output keystrokes. Default 100ms.
+ See `/usr/include/linux/input-event-codes.h' for available key codes (KEY_\*).
- *--key-delay* _<ms>_
+ Options:
+ *-d*,*--key-delay* _<ms>_
Delay time between keystrokes. Default 12ms.
- *--repeat* _<times>_
- Times to repeat the key sequence.
-
- *--repeat-delay* _<ms>_
- Delay time between repetitions. Default 0ms.
-
- Generally, any valid name from _/usr/include/linux/input-event-codes.h_ will work. Multiple keys are separated by '+'.
-
- Each key sequence can be any number of modifiers and keys, separated by plus (+)
-
- For example: alt+r Alt+F4 CTRL+alt+f3 aLT+1+2+3 ctrl+Backspace
-
- Since we are emulating keyboard input, combinations like Shift+# is invalid because typing a `#' involves pressing Shift and 3.
-
- Example: Switch to tty1:
- ydotool key ctrl+alt+f1
-
- Example: Close a window in graphical environment:
- ydotool key Alt+F4
-
-*type* [*--next-delay* _<ms>_] [*--key-delay* _<ms>_] [*--texts* _arg_] [*--file* _<filepath>_] "_texts_"
+*type* [*-D*,*--next-delay* _<ms>_] [*-d*,*--key-delay* _<ms>_] [*-f*,*--file* _<filepath>_] "_text_"
Types text as if you had typed it on the keyboard.
Options:
- *--next-delay* _<ms>_
- Delay before starting typing. Default 100ms.
+ *-d*,*--key-delay* _<ms>_
+ Delay time between key events (up/down each). Default 12ms.
- *--key-delay* _<ms>_
- Delay time between keystrokes. Default 12ms.
-
- *--texts* _arg_
- Texts to type
+ *-D*,*--next-delay* _<ms>_
+ Delay between strings. Default 0ms.
- *--file* _<filepath>_
+ *-f*,*--file* _<filepath>_
Specify a file, the contents of which will be typed as if passed as an argument. The filepath may also be '-' to read from stdin.
Example: to type 'Hello world!' you would do:
@@ -94,8 +61,8 @@
# MOUSE COMMANDS
-*mousemove* _<x> <y>_
- Move the mouse to the specific relative X and Y coordinates on the screen.
+*mousemove* [*-a*,*--absolute*] _<x> <y>_
+ Move the mouse to the relative X and Y coordinates on the screen.
Options:
*--absolute*
@@ -104,47 +71,38 @@
Example: to move the cursor to absolute coordinates (100,100):
ydotool mousemove --absolute 100 100
-*click* [*--next-delay* _<ms>_] _button_
- Send a click. Buttons are: _left_, _right_ or _middle_
-
- Options:
-
- *--next-delay* _<ms>_
- Delay before click. Default 100ms.
-
- *--up*
- Only mouseup
-
- *--down*
- Only mousedown
-
- *--buttons* _<arg>_
- Buttons to press (left, right, middle)
-
- Example: Mouse middle click:
- ydotool click middle
-
-*recorder* [*--record* _<devices>_] [*--replay* _<input files>_] [*--display*] [*--duration* _<ms>_] [*--devices* _<path>_] [*--file* _<path>_]
+*click* [*-d*,*--next-delay* _<ms>_] [*-r*,*--repeat* _N_ ] [_button_ ...]
+ Send a click.
Options:
+ *-d*,*--next-delay* _<ms>_
+ Delay between input events (up/down, a compete click means doubled time). Default 25ms.
- *--record* _<devices>_
- Devices to record from. Default is all, including non-keyboard devices.
-
- *--replay* _<input files>_
- The record file can't be replayed on an architecture with different endianness.
-
- *--display*
- Display
+ *-r*,*--repeat* _N_
+ Repeat entire sequence N times
- *--duration* _<ms>_
- Record duration. Otherwise use SIGINT to stop recording.
+ all mouse buttons are represented using hexadecimal numeric values, with an optional
+ bit mask to specify if mouse up/down needs to be omitted.
- *--devices* _<path>_
- Devices, separated by comma, to record from. Default is all devices (default: "")
+ - 0x00 - LEFT
+ - 0x01 - RIGHT
+ - 0x02 - MIDDLE
+ - 0x03 - SIDE
+ - 0x04 - EXTR
+ - 0x05 - FORWARD
+ - 0x06 - BACK
+ - 0x07 - TASK
+ - 0x40 - Mouse down
+ - 0x80 - Mouse up
+
+ Examples:
+
+ - 0x00: chooses left button, but does nothing (you can use this to implement extra sleeps)
+ - 0xC0: left button click (down then up)
+ - 0x41: right button down
+ - 0x82: middle button up
- *--file* _<path>_
- File to record to / replay from
+ The '0x' prefix can be omitted if you want.
# AUTHOR