keyboard_key_press(key)

From ENIGMA

(Difference between revisions)
Jump to: navigation, search
Line 1: Line 1:
{{FuncTitle|keyboard_key_press|key}}
{{FuncTitle|keyboard_key_press|key}}
== Description ==
== Description ==
-
General description of the function.
+
Simulates a key press of the given key.
 +
{{Function:Unimplemented}}
== Parameters ==
== Parameters ==
Line 7: Line 8:
! Parameter !! Description
! Parameter !! Description
|-
|-
-
| key || keyboard constant of the key to check
+
| key || keyboard constant of the key to simulate.
|}
|}
== Return Values ==
== Return Values ==
-
'''returntype''': Returns...
+
'''void''': This function does not return anything.
== Example Call ==
== Example Call ==
<syntaxhighlight lang="edl">
<syntaxhighlight lang="edl">
-
// demonstrates
+
keyboard_key_press(vk_shift);
 +
keyboard_key_press(ord('C'));
 +
keyboard_key_release(vk_shift);
 +
keyboard_key_press(ord('O'));
 +
keyboard_key_press(ord('D'));
 +
keyboard_key_press(ord('E'));
</syntaxhighlight>
</syntaxhighlight>
__NOTOC__
__NOTOC__
{{Function:GM}}
{{Function:GM}}

Revision as of 04:00, 2 September 2013

Description

Simulates a key press of the given key. Note: This function may be unimplemented on some platforms.


Parameters

Parameter Description
key keyboard constant of the key to simulate.

Return Values

void: This function does not return anything.

Example Call

keyboard_key_press(vk_shift);
keyboard_key_press(ord('C'));
keyboard_key_release(vk_shift);
keyboard_key_press(ord('O'));
keyboard_key_press(ord('D'));
keyboard_key_press(ord('E'));
Personal tools
Namespaces
Variants
Actions
Navigation
ENIGMA
Other
Toolbox