doc: Use self-closing tags for return and argument

For the time being we don't support writing a description for those, preferring
having all details in the method's description.

Using self-closing tags saves half the lines, and prevents contributors from
thinking that they should write the argument or return documentation there.

(cherry picked from commit 7adf4cc9b5)
This commit is contained in:
Rémi Verschelde
2021-07-30 15:28:05 +02:00
parent c5589c76ce
commit 16fd1c421e
350 changed files with 10551 additions and 21102 deletions

View File

@@ -11,127 +11,97 @@
</tutorials>
<methods>
<method name="action_add_event">
<return type="void">
</return>
<argument index="0" name="action" type="String">
</argument>
<argument index="1" name="event" type="InputEvent">
</argument>
<return type="void" />
<argument index="0" name="action" type="String" />
<argument index="1" name="event" type="InputEvent" />
<description>
Adds an [InputEvent] to an action. This [InputEvent] will trigger the action.
</description>
</method>
<method name="action_erase_event">
<return type="void">
</return>
<argument index="0" name="action" type="String">
</argument>
<argument index="1" name="event" type="InputEvent">
</argument>
<return type="void" />
<argument index="0" name="action" type="String" />
<argument index="1" name="event" type="InputEvent" />
<description>
Removes an [InputEvent] from an action.
</description>
</method>
<method name="action_erase_events">
<return type="void">
</return>
<argument index="0" name="action" type="String">
</argument>
<return type="void" />
<argument index="0" name="action" type="String" />
<description>
Removes all events from an action.
</description>
</method>
<method name="action_get_deadzone">
<return type="float">
</return>
<argument index="0" name="action" type="String">
</argument>
<return type="float" />
<argument index="0" name="action" type="String" />
<description>
Returns a deadzone value for the action.
</description>
</method>
<method name="action_has_event">
<return type="bool">
</return>
<argument index="0" name="action" type="String">
</argument>
<argument index="1" name="event" type="InputEvent">
</argument>
<return type="bool" />
<argument index="0" name="action" type="String" />
<argument index="1" name="event" type="InputEvent" />
<description>
Returns [code]true[/code] if the action has the given [InputEvent] associated with it.
</description>
</method>
<method name="action_set_deadzone">
<return type="void">
</return>
<argument index="0" name="action" type="String">
</argument>
<argument index="1" name="deadzone" type="float">
</argument>
<return type="void" />
<argument index="0" name="action" type="String" />
<argument index="1" name="deadzone" type="float" />
<description>
Sets a deadzone value for the action.
</description>
</method>
<method name="add_action">
<return type="void">
</return>
<argument index="0" name="action" type="String">
</argument>
<argument index="1" name="deadzone" type="float" default="0.5">
</argument>
<return type="void" />
<argument index="0" name="action" type="String" />
<argument index="1" name="deadzone" type="float" default="0.5" />
<description>
Adds an empty action to the [InputMap] with a configurable [code]deadzone[/code].
An [InputEvent] can then be added to this action with [method action_add_event].
</description>
</method>
<method name="erase_action">
<return type="void">
</return>
<argument index="0" name="action" type="String">
</argument>
<return type="void" />
<argument index="0" name="action" type="String" />
<description>
Removes an action from the [InputMap].
</description>
</method>
<method name="event_is_action" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="event" type="InputEvent">
</argument>
<argument index="1" name="action" type="String">
</argument>
<return type="bool" />
<argument index="0" name="event" type="InputEvent" />
<argument index="1" name="action" type="String" />
<description>
Returns [code]true[/code] if the given event is part of an existing action. This method ignores keyboard modifiers if the given [InputEvent] is not pressed (for proper release detection). See [method action_has_event] if you don't want this behavior.
</description>
</method>
<method name="get_action_list">
<return type="Array">
</return>
<argument index="0" name="action" type="String">
</argument>
<return type="Array" />
<argument index="0" name="action" type="String" />
<description>
Returns an array of [InputEvent]s associated with a given action.
</description>
</method>
<method name="get_actions">
<return type="Array">
</return>
<return type="Array" />
<description>
Returns an array of all actions in the [InputMap].
</description>
</method>
<method name="has_action" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="action" type="String">
</argument>
<return type="bool" />
<argument index="0" name="action" type="String" />
<description>
Returns [code]true[/code] if the [InputMap] has a registered action with the given name.
</description>
</method>
<method name="load_from_globals">
<return type="void">
</return>
<return type="void" />
<description>
Clears all [InputEventAction] in the [InputMap] and load it anew from [ProjectSettings].
</description>