aboutsummaryrefslogtreecommitdiff
path: root/doc/base/classes.xml
diff options
context:
space:
mode:
authorZher Huei Lee2016-10-24 22:13:26 +0100
committerZher Huei Lee2016-10-27 10:27:40 +0100
commitc3b4686082bc92c70886ee848064009c8f628193 (patch)
treef467034c98a7a8c91de7d09e41274555ce60fd4e /doc/base/classes.xml
parent439d43932133d32dcabd482f11842072d52b41e1 (diff)
downloadgodot-c3b4686082bc92c70886ee848064009c8f628193.tar.gz
godot-c3b4686082bc92c70886ee848064009c8f628193.tar.zst
godot-c3b4686082bc92c70886ee848064009c8f628193.zip
Added global sub and bounds checking to RegEx
Diffstat (limited to 'doc/base/classes.xml')
-rw-r--r--doc/base/classes.xml14
1 files changed, 8 insertions, 6 deletions
diff --git a/doc/base/classes.xml b/doc/base/classes.xml
index cafb14491..47fa1deb5 100644
--- a/doc/base/classes.xml
+++ b/doc/base/classes.xml
@@ -32582,7 +32582,7 @@
<argument index="2" name="end" type="int" default="-1">
</argument>
<description>
- Searches the text for the compiled pattern. Returns a [RegExMatch] container of the first matching reult if found, otherwise null. The starting point of the serch could be specified without moving the string start anchor.
+ Searches the text for the compiled pattern. Returns a [RegExMatch] container of the first matching reult if found, otherwise null. The region to search within can be specified without modifying where the start and end anchor would be.
</description>
</method>
<method name="sub" qualifiers="const">
@@ -32590,14 +32590,16 @@
</return>
<argument index="0" name="text" type="String">
</argument>
- <argument index="1" name="template" type="String">
+ <argument index="1" name="replacement" type="String">
</argument>
- <argument index="2" name="start" type="int" default="0">
+ <argument index="2" name="all" type="bool" default="false">
</argument>
- <argument index="3" name="end" type="int" default="-1">
+ <argument index="3" name="start" type="int" default="0">
+ </argument>
+ <argument index="4" name="end" type="int" default="-1">
</argument>
<description>
- Searches the specified text for the compiled pattern and returns the text with the result replaced. Escapes and backreferences such as [code]\1[/code] and [code]\g&lt;name&gt;[/code] are automatically expanded and resolved. If no change was found the unmodified text is returned instead.
+ Searches the text for the compiled pattern and replaces it with the specified string. Escapes and backreferences such as [code]\1[/code] and [code]\g&lt;name&gt;[/code] expanded and resolved. By default only the first instance is replaced but it can be changed for all instances (global replacement). The region to search within can be specified without modifying where the start and end anchor would be.
</description>
</method>
</methods>
@@ -32616,7 +32618,7 @@
<argument index="0" name="template" type="String">
</argument>
<description>
- Using results from the search, returns the specified string with escapes and backreferences such as [code]\1[/code] and [code]\g&lt;name&gt;[/code] expanded and resolved
+ Using results from the search, returns the specified string with escapes and backreferences such as [code]\1[/code] and [code]\g&lt;name&gt;[/code] expanded and resolved.
</description>
</method>
<method name="get_end" qualifiers="const">