summaryrefslogtreecommitdiff
path: root/doc/classes
diff options
context:
space:
mode:
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/@GlobalScope.xml6
-rw-r--r--doc/classes/Color.xml33
-rw-r--r--doc/classes/JavaScript.xml22
-rw-r--r--doc/classes/Mesh.xml2
-rw-r--r--doc/classes/Panel.xml10
-rw-r--r--doc/classes/PopupMenu.xml7
-rw-r--r--doc/classes/RID.xml6
-rw-r--r--doc/classes/RenderingServer.xml2
-rw-r--r--doc/classes/String.xml16
-rw-r--r--doc/classes/StringName.xml24
-rw-r--r--doc/classes/TranslationServer.xml7
-rw-r--r--doc/classes/Tree.xml1
-rw-r--r--doc/classes/Vector3i.xml1
-rw-r--r--doc/classes/VisualShaderNodeParticleRandomness.xml10
-rw-r--r--doc/classes/int.xml7
15 files changed, 140 insertions, 14 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml
index d8c9ca08e8..4c0f89f14d 100644
--- a/doc/classes/@GlobalScope.xml
+++ b/doc/classes/@GlobalScope.xml
@@ -1267,6 +1267,12 @@
<constant name="INLINE_ALIGNMENT_BOTTOM" value="14" enum="InlineAlignment">
Aligns bottom of the inline object (e.g. image, table) to the bottom of the text. Equivalent to [code]INLINE_ALIGNMENT_BOTTOM_TO | INLINE_ALIGNMENT_TO_BOTTOM[/code].
</constant>
+ <constant name="INLINE_ALIGNMENT_IMAGE_MASK" value="3" enum="InlineAlignment">
+ A bit mask for [code]INLINE_ALIGNMENT_*_TO[/code] alignment constants.
+ </constant>
+ <constant name="INLINE_ALIGNMENT_TEXT_MASK" value="12" enum="InlineAlignment">
+ A bit mask for [code]INLINE_ALIGNMENT_TO_*[/code] alignment constants.
+ </constant>
<constant name="KEY_SPECIAL" value="16777216" enum="Key">
Keycodes with this bit applied are non-printable.
</constant>
diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml
index f3fcd90f51..4e73d4d9d8 100644
--- a/doc/classes/Color.xml
+++ b/doc/classes/Color.xml
@@ -218,12 +218,45 @@
<return type="Color" />
<argument index="0" name="rgba" type="String" />
<description>
+ Returns a new color from [code]rgba[/code], an HTML hexadecimal color string. [code]rgba[/code] is not case sensitive, and may be prefixed with a '#' character.
+ [code]rgba[/code] must be a valid three-digit or six-digit hexadecimal color string, and may contain an alpha channel value. If [code]rgba[/code] does not contain an alpha channel value, an alpha channel value of 1.0 is applied.
+ If [code]rgba[/code] is invalid a Color(0.0, 0.0, 0.0, 1.0) is returned.
+ [codeblocks]
+ [gdscript]
+ var green = Color.html("#00FF00FF") # set green to Color(0.0, 1.0, 0.0, 1.0)
+ var blue = Color.html("#0000FF") # set blue to Color(0.0, 0.0, 1.0, 1.0)
+ [/gdscript]
+ [csharp]
+ var green = Color.Html("#00FF00FF"); // set green to Color(0.0, 1.0, 0.0, 1.0)
+ var blue = Color.Html("#0000FF"); // set blue to Color(0.0, 0.0, 1.0, 1.0)
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="html_is_valid" qualifiers="static">
<return type="bool" />
<argument index="0" name="color" type="String" />
<description>
+ Returns [code]true[/code] if [code]color[/code] is a valid HTML hexadecimal color string. [code]color[/code] is not case sensitive, and may be prefixed with a '#' character.
+ For a string to be valid it must be three-digit or six-digit hexadecimal, and may contain an alpha channel value.
+ [codeblocks]
+ [gdscript]
+ var result = Color.html_is_valid("#55aaFF") # result is true
+ result = Color.html_is_valid("#55AAFF20") # result is true
+ result = Color.html_is_valid("55AAFF") # result is true
+ result = Color.html_is_valid("#F2C") # result is true
+ result = Color.html_is_valid("#AABBC) # result is false
+ result = Color.html_is_valid("#55aaFF5") # result is false
+ [/gdscript]
+ [csharp]
+ var result = Color.HtmlIsValid("#55AAFF"); // result is true
+ result = Color.HtmlIsValid("#55AAFF20"); // result is true
+ result = Color.HtmlIsValid("55AAFF); // result is true
+ result = Color.HtmlIsValid("#F2C"); // result is true
+ result = Color.HtmlIsValid("#AABBC"); // result is false
+ result = Color.HtmlIsValid("#55aaFF5"); // result is false
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="inverted" qualifiers="const">
diff --git a/doc/classes/JavaScript.xml b/doc/classes/JavaScript.xml
index aeaf8ac1f5..4ea60ad867 100644
--- a/doc/classes/JavaScript.xml
+++ b/doc/classes/JavaScript.xml
@@ -53,5 +53,27 @@
Returns an interface to a JavaScript object that can be used by scripts. The [code]interface[/code] must be a valid property of the JavaScript [code]window[/code]. The callback must accept a single [Array] argument, which will contain the JavaScript [code]arguments[/code]. See [JavaScriptObject] for usage.
</description>
</method>
+ <method name="pwa_needs_update" qualifiers="const">
+ <return type="bool" />
+ <description>
+ Returns [code]true[/code] if a new version of the progressive web app is waiting to be activated.
+ [b]Note:[/b] Only relevant when exported as a Progressive Web App.
+ </description>
+ </method>
+ <method name="pwa_update">
+ <return type="int" enum="Error" />
+ <description>
+ Performs the live update of the progressive web app. Forcing the new version to be installed and the page to be reloaded.
+ [b]Note:[/b] Your application will be [b]reloaded in all browser tabs[/b].
+ [b]Note:[/b] Only relevant when exported as a Progressive Web App and [method pwa_needs_update] returns [code]true[/code].
+ </description>
+ </method>
</methods>
+ <signals>
+ <signal name="pwa_update_available">
+ <description>
+ Emitted when an update for this progressive web app has been detected but is waiting to be activated because a previous version is active. See [method pwa_update] to force the update to take place immediately.
+ </description>
+ </signal>
+ </signals>
</class>
diff --git a/doc/classes/Mesh.xml b/doc/classes/Mesh.xml
index c774528a39..8fbafcdb51 100644
--- a/doc/classes/Mesh.xml
+++ b/doc/classes/Mesh.xml
@@ -206,7 +206,7 @@
<constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat">
Mesh array uses indices.
</constant>
- <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="2147475463" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="7" enum="ArrayFormat">
</constant>
<constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat">
</constant>
diff --git a/doc/classes/Panel.xml b/doc/classes/Panel.xml
index 21ac7dfac1..3246fa7eba 100644
--- a/doc/classes/Panel.xml
+++ b/doc/classes/Panel.xml
@@ -11,16 +11,6 @@
<link title="2D Finite State Machine Demo">https://godotengine.org/asset-library/asset/516</link>
<link title="3D Inverse Kinematics Demo">https://godotengine.org/asset-library/asset/523</link>
</tutorials>
- <members>
- <member name="mode" type="int" setter="set_mode" getter="get_mode" enum="Panel.Mode" default="0">
- </member>
- </members>
- <constants>
- <constant name="MODE_BACKGROUND" value="0" enum="Mode">
- </constant>
- <constant name="MODE_FOREGROUND" value="1" enum="Mode">
- </constant>
- </constants>
<theme_items>
<theme_item name="panel" data_type="style" type="StyleBox">
The style of this [Panel].
diff --git a/doc/classes/PopupMenu.xml b/doc/classes/PopupMenu.xml
index eb1b0aada7..b316f822f0 100644
--- a/doc/classes/PopupMenu.xml
+++ b/doc/classes/PopupMenu.xml
@@ -331,6 +331,13 @@
[b]Note:[/b] The indices of items after the removed item will be shifted by one.
</description>
</method>
+ <method name="scroll_to_item">
+ <return type="void" />
+ <argument index="0" name="index" type="int" />
+ <description>
+ Moves the scroll view to make the item at the given [code]index[/code] visible.
+ </description>
+ </method>
<method name="set_current_index">
<return type="void" />
<argument index="0" name="index" type="int" />
diff --git a/doc/classes/RID.xml b/doc/classes/RID.xml
index 695b0933fa..990e82593e 100644
--- a/doc/classes/RID.xml
+++ b/doc/classes/RID.xml
@@ -30,6 +30,12 @@
Returns the ID of the referenced resource.
</description>
</method>
+ <method name="is_valid" qualifiers="const">
+ <return type="bool" />
+ <description>
+ Returns [code]true[/code] if [RID] is valid.
+ </description>
+ </method>
</methods>
<operators>
<operator name="operator !=">
diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml
index 446db40dd8..82728c0570 100644
--- a/doc/classes/RenderingServer.xml
+++ b/doc/classes/RenderingServer.xml
@@ -3626,7 +3626,7 @@
<constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat">
Flag used to mark an index array.
</constant>
- <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="2147475463" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="7" enum="ArrayFormat">
</constant>
<constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat">
</constant>
diff --git a/doc/classes/String.xml b/doc/classes/String.xml
index eeb17c24c0..a6182f5dab 100644
--- a/doc/classes/String.xml
+++ b/doc/classes/String.xml
@@ -222,6 +222,22 @@
[/codeblock]
</description>
</method>
+ <method name="get_slice_count" qualifiers="const">
+ <return type="int" />
+ <argument index="0" name="delimiter" type="String" />
+ <description>
+ Splits a string using a [code]delimiter[/code] and returns a number of slices.
+ </description>
+ </method>
+ <method name="get_slicec" qualifiers="const">
+ <return type="String" />
+ <argument index="0" name="delimiter" type="int" />
+ <argument index="1" name="slice" type="int" />
+ <description>
+ Splits a string using a Unicode character with code [code]delimiter[/code] and returns a substring at index [code]slice[/code]. Returns an empty string if the index doesn't exist.
+ This is a more performant alternative to [method split] for cases when you need only one element from the array at a fixed index.
+ </description>
+ </method>
<method name="hash" qualifiers="const">
<return type="int" />
<description>
diff --git a/doc/classes/StringName.xml b/doc/classes/StringName.xml
index b32665a09f..85c4d7593e 100644
--- a/doc/classes/StringName.xml
+++ b/doc/classes/StringName.xml
@@ -48,6 +48,18 @@
<description>
</description>
</operator>
+ <operator name="operator &lt;">
+ <return type="bool" />
+ <argument index="0" name="right" type="StringName" />
+ <description>
+ </description>
+ </operator>
+ <operator name="operator &lt;=">
+ <return type="bool" />
+ <argument index="0" name="right" type="StringName" />
+ <description>
+ </description>
+ </operator>
<operator name="operator ==">
<return type="bool" />
<description>
@@ -65,5 +77,17 @@
<description>
</description>
</operator>
+ <operator name="operator &gt;">
+ <return type="bool" />
+ <argument index="0" name="right" type="StringName" />
+ <description>
+ </description>
+ </operator>
+ <operator name="operator &gt;=">
+ <return type="bool" />
+ <argument index="0" name="right" type="StringName" />
+ <description>
+ </description>
+ </operator>
</operators>
</class>
diff --git a/doc/classes/TranslationServer.xml b/doc/classes/TranslationServer.xml
index c90cb2987c..6ece42da6b 100644
--- a/doc/classes/TranslationServer.xml
+++ b/doc/classes/TranslationServer.xml
@@ -91,6 +91,13 @@
Returns readable script name for the [code]script[/code] code.
</description>
</method>
+ <method name="get_tool_locale">
+ <return type="String" />
+ <description>
+ Returns the current locale of the editor.
+ [b]Note:[/b] When called from an exported project returns the same value as [method get_locale].
+ </description>
+ </method>
<method name="get_translation_object">
<return type="Translation" />
<argument index="0" name="locale" type="String" />
diff --git a/doc/classes/Tree.xml b/doc/classes/Tree.xml
index 766c740a2c..4b051c4938 100644
--- a/doc/classes/Tree.xml
+++ b/doc/classes/Tree.xml
@@ -240,6 +240,7 @@
<method name="scroll_to_item">
<return type="void" />
<argument index="0" name="item" type="TreeItem" />
+ <argument index="1" name="center_on_item" type="bool" default="false" />
<description>
Causes the [Tree] to jump to the specified [TreeItem].
</description>
diff --git a/doc/classes/Vector3i.xml b/doc/classes/Vector3i.xml
index 8a901fdf37..e0b8a53a3c 100644
--- a/doc/classes/Vector3i.xml
+++ b/doc/classes/Vector3i.xml
@@ -48,6 +48,7 @@
<method name="abs" qualifiers="const">
<return type="Vector3i" />
<description>
+ Returns a new vector with all components in absolute values (i.e. positive).
</description>
</method>
<method name="clamp" qualifiers="const">
diff --git a/doc/classes/VisualShaderNodeParticleRandomness.xml b/doc/classes/VisualShaderNodeParticleRandomness.xml
index 2dec41105c..880208b136 100644
--- a/doc/classes/VisualShaderNodeParticleRandomness.xml
+++ b/doc/classes/VisualShaderNodeParticleRandomness.xml
@@ -8,14 +8,20 @@
</tutorials>
<members>
<member name="op_type" type="int" setter="set_op_type" getter="get_op_type" enum="VisualShaderNodeParticleRandomness.OpType" default="0">
+ A type of operands and returned value.
</member>
</members>
<constants>
<constant name="OP_TYPE_SCALAR" value="0" enum="OpType">
+ A floating-point scalar.
</constant>
- <constant name="OP_TYPE_VECTOR" value="1" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_2D" value="1" enum="OpType">
+ A 2D vector type.
</constant>
- <constant name="OP_TYPE_MAX" value="2" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_3D" value="2" enum="OpType">
+ A 3D vector type.
+ </constant>
+ <constant name="OP_TYPE_MAX" value="3" enum="OpType">
Represents the size of the [enum OpType] enum.
</constant>
</constants>
diff --git a/doc/classes/int.xml b/doc/classes/int.xml
index d212fe42bf..006dc7eb29 100644
--- a/doc/classes/int.xml
+++ b/doc/classes/int.xml
@@ -177,6 +177,13 @@
</description>
</operator>
<operator name="operator +">
+ <return type="String" />
+ <argument index="0" name="right" type="String" />
+ <description>
+ Adds Unicode character with code [int] to the [String].
+ </description>
+ </operator>
+ <operator name="operator +">
<return type="float" />
<argument index="0" name="right" type="float" />
<description>