immersive-home/docs/reference/EventKey.md

42 lines
2.3 KiB
Markdown
Raw Permalink Normal View History

2024-03-16 19:45:43 +02:00
# EventKey
**Inherits:** [EventWithModifiers](/reference/EventWithModifiers.html)
2024-03-16 19:45:43 +02:00
2024-03-17 01:14:31 +02:00
## Description
2024-03-16 19:45:43 +02:00
2024-03-17 01:14:31 +02:00
Events emitted by the Virtual Keyboard
2024-03-16 19:45:43 +02:00
## Properties
2024-03-17 01:14:31 +02:00
| Name | Type | Default |
| ------------------ | ------------------------------------------------------------------- | ------- |
| [echo](#prop-echo) | [bool](https://docs.godotengine.org/de/4.x/classes/class_bool.html) | |
| [key](#prop-key) | [int](https://docs.godotengine.org/de/4.x/classes/class_int.html) | |
2024-03-16 19:45:43 +02:00
## Methods
| Returns | Name |
| ----------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| [String](https://docs.godotengine.org/de/4.x/classes/class_string.html) | [key_to_string](#key-to-string) ( key: [int](https://docs.godotengine.org/de/4.x/classes/class_int.html), caps: [bool](https://docs.godotengine.org/de/4.x/classes/class_bool.html), apply_to: [String](https://docs.godotengine.org/de/4.x/classes/class_string.html) ) |
2024-03-17 01:14:31 +02:00
2024-03-16 19:45:43 +02:00
## Property Descriptions
2024-03-17 01:14:31 +02:00
### echo: [bool](https://docs.godotengine.org/de/4.x/classes/class_bool.html) {#prop-echo}
2024-03-16 19:45:43 +02:00
2024-03-17 01:14:31 +02:00
true if the event is repeated due to a key being held down for a while
2024-03-16 19:45:43 +02:00
2024-03-17 01:14:31 +02:00
### key: [int](https://docs.godotengine.org/de/4.x/classes/class_int.html) {#prop-key}
2024-03-16 19:45:43 +02:00
2024-03-17 01:14:31 +02:00
The key that was pressed or released
2024-03-16 19:45:43 +02:00
## Method Descriptions
2024-03-17 01:14:31 +02:00
### static key_to_string (key: [int](https://docs.godotengine.org/de/4.x/classes/class_int.html) , caps: [bool](https://docs.godotengine.org/de/4.x/classes/class_bool.html) , apply_to: [String](https://docs.godotengine.org/de/4.x/classes/class_string.html) ) -> [String](https://docs.godotengine.org/de/4.x/classes/class_string.html) {#key-to-string}
2024-03-16 19:45:43 +02:00
2024-03-17 01:14:31 +02:00
Modifies a string based on the key pressed