Skip to content

Commit

Permalink
Document which escape sequences are supported by String.c_unescape()
Browse files Browse the repository at this point in the history
  • Loading branch information
Calinou committed Jul 15, 2020
1 parent dad21ac commit 04b2510
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions doc/classes/String.xml
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,8 @@
<return type="String">
</return>
<description>
Returns a copy of the string with escaped characters replaced by their meanings according to the C language standard.
Returns a copy of the string with escaped characters replaced by their meanings. Supported escape sequences are [code]\'[/code], [code]\"[/code], [code]\?[/code], [code]\\[/code], [code]\a[/code], [code]\b[/code], [code]\f[/code], [code]\n[/code], [code]\r[/code], [code]\t[/code], [code]\v[/code].
[b]Note:[/b] Unlike the GDScript parser, this method doesn't support the [code]\uXXXX[/code] escape sequence.
</description>
</method>
<method name="capitalize">
Expand Down Expand Up @@ -413,7 +414,6 @@
</argument>
<description>
Returns the index of the [b]first[/b] case-sensitive occurrence of the specified string in this instance, or [code]-1[/code]. Optionally, the starting search index can be specified, continuing to the end of the string.

[b]Note:[/b] If you just want to know whether a string contains a substring, use the [code]in[/code] operator as follows:
[codeblock]
# Will evaluate to `false`.
Expand Down

0 comments on commit 04b2510

Please sign in to comment.