HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

wtype — Simulate keyboard input on Wayland, similar to `xdotool type` for X11. See also: `ydotool`. More inf

Submitted by: @import:tldr-pages··
0
Viewed 0 times
commandkeyboardwaylandsimilarwtypeclisimulateinput
linux

Problem

How to use the wtype command: Simulate keyboard input on Wayland, similar to xdotool type for X11. See also: ydotool. More information: <https://manned.org/wtype>.

Solution

wtype — Simulate keyboard input on Wayland, similar to xdotool type for X11. See also: ydotool. More information: <https://manned.org/wtype>.

Simulate typing text:
wtype "{{Hello World}}"


Type a specific key:
wtype -k {{Left}}


Press a modifier:
wtype -M {{shift|ctrl|...}}


Release a modifier:
wtype -m {{ctrl}}


Wait between keystrokes (in milliseconds):
wtype -d {{500}} -- "{{text}}"


Read text from stdin:
echo "{{text}}" | wtype -

Code Snippets

Simulate typing text

wtype "{{Hello World}}"

Type a specific key

wtype -k {{Left}}

Press a modifier

wtype -M {{shift|ctrl|...}}

Release a modifier

wtype -m {{ctrl}}

Wait between keystrokes (in milliseconds)

wtype -d {{500}} -- "{{text}}"

Context

tldr-pages: linux/wtype

Revisions (0)

No revisions yet.