Files
godot-docs-l10n/classes/es/class_inputeventkey.rst
Rémi Verschelde cf78697eea Add localized class reference as pre-generated RST files
Currently including `zh_CN` and `es` which both have very high completion
ratios. Others will be added once they reach a significant percentage too.

These RST files will be used by godot-docs in place of its `classes` folder
after we sync with https://github.com/godotengine/godot-docs/pull/5458.

The update workflow is manual for now (example for `zh_CN`):

- Build `godotengine/godot` in the branch we currently track (now `3.x`)
- Run `godot --doctool -l zh_CN`
- Run `cd doc && make rst LANGARG=zh_CN`
- Copy `doc/_build/rst/*` to `classes/zh_CN/` here
- Make sure to have `classes/zh_CN/index.rst` copied from `docs/classes`
2021-12-21 16:07:55 +01:00

159 lines
7.2 KiB
ReStructuredText

:github_url: hide
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the InputEventKey.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.
.. _class_InputEventKey:
InputEventKey
=============
**Inherits:** :ref:`InputEventWithModifiers<class_InputEventWithModifiers>` **<** :ref:`InputEvent<class_InputEvent>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
Tipo de evento de entrada para eventos de teclado.
Descripción
----------------------
Almacena las pulsaciones de teclas en el teclado. Soporta pulsaciones de teclas, liberaciones de teclas y eventos de :ref:`echo<class_InputEventKey_property_echo>`.
Tutoriales
--------------------
- :doc:`../tutorials/inputs/inputevent`
Propiedades
----------------------
+-------------------------+--------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`echo<class_InputEventKey_property_echo>` | ``false`` |
+-------------------------+--------------------------------------------------------------------------+-----------+
| :ref:`int<class_int>` | :ref:`physical_scancode<class_InputEventKey_property_physical_scancode>` | ``0`` |
+-------------------------+--------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`pressed<class_InputEventKey_property_pressed>` | ``false`` |
+-------------------------+--------------------------------------------------------------------------+-----------+
| :ref:`int<class_int>` | :ref:`scancode<class_InputEventKey_property_scancode>` | ``0`` |
+-------------------------+--------------------------------------------------------------------------+-----------+
| :ref:`int<class_int>` | :ref:`unicode<class_InputEventKey_property_unicode>` | ``0`` |
+-------------------------+--------------------------------------------------------------------------+-----------+
Métodos
--------------
+-----------------------+----------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_physical_scancode_with_modifiers<class_InputEventKey_method_get_physical_scancode_with_modifiers>` **(** **)** |const| |
+-----------------------+----------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_scancode_with_modifiers<class_InputEventKey_method_get_scancode_with_modifiers>` **(** **)** |const| |
+-----------------------+----------------------------------------------------------------------------------------------------------------------------------+
Descripciones de Propiedades
--------------------------------------------------------
.. _class_InputEventKey_property_echo:
- :ref:`bool<class_bool>` **echo**
+-----------+-----------------+
| *Default* | ``false`` |
+-----------+-----------------+
| *Setter* | set_echo(value) |
+-----------+-----------------+
| *Getter* | is_echo() |
+-----------+-----------------+
Si ``true``, la tecla ya estaba pulsada antes de este evento. Significa que el usuario está manteniendo la tecla pulsada.
----
.. _class_InputEventKey_property_physical_scancode:
- :ref:`int<class_int>` **physical_scancode**
+-----------+------------------------------+
| *Default* | ``0`` |
+-----------+------------------------------+
| *Setter* | set_physical_scancode(value) |
+-----------+------------------------------+
| *Getter* | get_physical_scancode() |
+-----------+------------------------------+
Key physical scancode, which corresponds to one of the :ref:`KeyList<enum_@GlobalScope_KeyList>` constants. Represent the physical location of a key on the 101/102-key US QWERTY keyboard.
To get a human-readable representation of the ``InputEventKey``, use ``OS.get_scancode_string(event.physical_scancode)`` where ``event`` is the ``InputEventKey``.
----
.. _class_InputEventKey_property_pressed:
- :ref:`bool<class_bool>` **pressed**
+-----------+--------------------+
| *Default* | ``false`` |
+-----------+--------------------+
| *Setter* | set_pressed(value) |
+-----------+--------------------+
| *Getter* | is_pressed() |
+-----------+--------------------+
Si ``true``, se pulsa el estado de la tecla. Si ``false``, el estado de la tecla se libera.
----
.. _class_InputEventKey_property_scancode:
- :ref:`int<class_int>` **scancode**
+-----------+---------------------+
| *Default* | ``0`` |
+-----------+---------------------+
| *Setter* | set_scancode(value) |
+-----------+---------------------+
| *Getter* | get_scancode() |
+-----------+---------------------+
The key scancode, which corresponds to one of the :ref:`KeyList<enum_@GlobalScope_KeyList>` constants. Represent key in the current keyboard layout.
To get a human-readable representation of the ``InputEventKey``, use ``OS.get_scancode_string(event.scancode)`` where ``event`` is the ``InputEventKey``.
----
.. _class_InputEventKey_property_unicode:
- :ref:`int<class_int>` **unicode**
+-----------+--------------------+
| *Default* | ``0`` |
+-----------+--------------------+
| *Setter* | set_unicode(value) |
+-----------+--------------------+
| *Getter* | get_unicode() |
+-----------+--------------------+
The key Unicode identifier (when relevant). Unicode identifiers for the composite characters and complex scripts may not be available unless IME input mode is active. See :ref:`OS.set_ime_active<class_OS_method_set_ime_active>` for more information.
Descripciones de Métodos
------------------------------------------------
.. _class_InputEventKey_method_get_physical_scancode_with_modifiers:
- :ref:`int<class_int>` **get_physical_scancode_with_modifiers** **(** **)** |const|
Returns the physical scancode combined with modifier keys such as ``Shift`` or ``Alt``. See also :ref:`InputEventWithModifiers<class_InputEventWithModifiers>`.
To get a human-readable representation of the ``InputEventKey`` with modifiers, use ``OS.get_scancode_string(event.get_physical_scancode_with_modifiers())`` where ``event`` is the ``InputEventKey``.
----
.. _class_InputEventKey_method_get_scancode_with_modifiers:
- :ref:`int<class_int>` **get_scancode_with_modifiers** **(** **)** |const|
Returns the scancode combined with modifier keys such as ``Shift`` or ``Alt``. See also :ref:`InputEventWithModifiers<class_InputEventWithModifiers>`.
To get a human-readable representation of the ``InputEventKey`` with modifiers, use ``OS.get_scancode_string(event.get_scancode_with_modifiers())`` where ``event`` is the ``InputEventKey``.
.. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
.. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`