Jump to content

Simulate input/Keyboard: Difference between revisions

m
m (→‎{{header|Wren}}: Minor tidy)
Line 959:
<br>
As it's not currently possible for Wren-cli to access Xlib directly, we embed a Wren script in a C application to complete this task.
<syntaxhighlight lang="ecmascriptwren">/* simulate_input_keyboardSimulate_input_Keyboard.wren */
 
import "random" for Random
Line 1,438:
WrenVM* vm = wrenNewVM(&config);
const char* module = "main";
const char* fileName = "simulate_input_keyboardSimulate_input_Keyboard.wren";
char *script = readFile(fileName);
WrenInterpretResult result = wrenInterpret(vm, module, script);
9,488

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.