From 6776fa63de4d96f043c1e970ee366a865d46da27 Mon Sep 17 00:00:00 2001 From: George Marques Date: Thu, 23 Jun 2016 18:08:41 -0300 Subject: Add docs for String and CanvasItem --- doc/base/classes.xml | 78 ++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 58 insertions(+), 20 deletions(-) (limited to 'doc') diff --git a/doc/base/classes.xml b/doc/base/classes.xml index 808bf20c25..5ccc540422 100644 --- a/doc/base/classes.xml +++ b/doc/base/classes.xml @@ -7059,8 +7059,11 @@ Draw a textured rectangle region at a given position, optionally modulated by a color. Transpose swaps the x and y coordinates when reading the texture. - + + + + Used for editing, returns an opaque value representing the transform state. @@ -7080,7 +7083,7 @@ - Used for editing, returns an opaque value representing the transform state. + Set the transform state of this CanvasItem. For [Node2D], this is an [Array] with (in order) a [Vector2] for position, a float for rotation and another [Vector2] for scale. For [Control] this is a [Rect2] with the position and size. @@ -7094,6 +7097,7 @@ + Return the [RID] of the [World2D] canvas where this item is in. @@ -7107,55 +7111,63 @@ + Get the transform matrix of this item's canvas. + Get the global position of the mouse. + Get the global transform matrix of this item. + Get the global transform matrix of this item in relation to the canvas. + Get a [Rect2] with the boundaries of this item and its children. - Return a rect containing the editable contents of the item. + Return a rect containing the editable boundaries of the item. + Get this item's light mask number. + Get the mouse position relative to this item's position. + Get the material of this item. @@ -7176,30 +7188,35 @@ + Get the transform matrix of this item. + Get whether this item uses its parent's material. + Get the viewport's boundaries as a [Rect2]. + Get this item's transform in relation to the viewport. + Get the [World2D] where this item is in. @@ -7241,13 +7258,14 @@ + Takes a global input event and convert to this item's coordinate system. - Set as toplevel. This means that it will not inherit transform from parent canvas items. + Set as top level. This means that it will not inherit transform from parent canvas items. @@ -7261,25 +7279,28 @@ - Sets whether the canvas item is drawn behind its parent. + Set whether the canvas item is drawn behind its parent. + Set whether this item should be hidden or not. Note that no matter what is set here this item won't be shown if its parent or grandparents nodes are also hidden. A hidden CanvasItem make all children hidden too. + Set the ligtht mask number of this item. + Set the material of this item. @@ -7300,6 +7321,7 @@ + Set whether or not this item should use its parent's material. @@ -7309,7 +7331,7 @@ - Queue the CanvasItem for update. NOTIFICATION_DRAW will be called on idle time to request redraw. + Queue the CanvasItem for update. [code]NOTIFICATION_DRAW[/code] will be called on idle time to request redraw. @@ -37540,12 +37562,14 @@ A similar effect may be achieved moving this node's descendants. + Return a copy of the string with special characters escaped using the C language standard. + Return a copy of the string with escaped characters replaced by their meanings according to the C language standard. @@ -37577,6 +37601,7 @@ A similar effect may be achieved moving this node's descendants. + Return true if the strings ends with the given string. @@ -37585,6 +37610,7 @@ A similar effect may be achieved moving this node's descendants. + Erase [code]chars[/code] characters from the string starting from [code]pos[/code]. @@ -37684,7 +37710,7 @@ A similar effect may be achieved moving this node's descendants. - Checked whether this string is a subsequence of the given string. + Check whether this string is a subsequence of the given string. @@ -37693,7 +37719,7 @@ A similar effect may be achieved moving this node's descendants. - Checked whether this string is a subsequence of the given string, without considering case. + Check whether this string is a subsequence of the given string, without considering case. @@ -37714,6 +37740,7 @@ A similar effect may be achieved moving this node's descendants. + Check whether the string is a valid identifier. As is common in programming languages, a valid identifier may contain only letters, digits and underscores (_) and the first character may not be a digit. @@ -37734,6 +37761,7 @@ A similar effect may be achieved moving this node's descendants. + Return a copy of the string with special characters escaped using the JSON standard. @@ -37774,12 +37802,14 @@ A similar effect may be achieved moving this node's descendants. + Return the MD5 hash of the string as an array of bytes. + Return the MD5 hash of the string as a string. @@ -37797,7 +37827,7 @@ A similar effect may be achieved moving this node's descendants. - Return the character code at position "at". + Return the character code at position [code]at[/code]. @@ -37806,6 +37836,7 @@ A similar effect may be achieved moving this node's descendants. + Format a number to have an exact number of [code]digits[/code] after the decimal point. @@ -37814,18 +37845,21 @@ A similar effect may be achieved moving this node's descendants. + Format a number to have an exact number of [code]digits[/code] before the decimal point. + Decode a percent-encoded string. See [method percent_encode]. + Percent-encode a string. This is meant to encode parameters in a URL when sending a HTTP GET request and bodies of form-urlencoded POST request. @@ -37834,6 +37868,7 @@ A similar effect may be achieved moving this node's descendants. + If the string is a path, this concatenates [code]file[/code] at the end of the string as a subpath. E.g. [code]"this/is".plus_file("path") == "this/is/path"[/code]. @@ -37889,10 +37924,17 @@ A similar effect may be achieved moving this node's descendants. Return the right side of the string from a given position. + + + + + + + Return the SHA-256 hash of the string as a string. @@ -37912,7 +37954,7 @@ A similar effect may be achieved moving this node's descendants. - Split the string by a divisor string, return an array of the substrings. Example "One,Two,Three" will return \["One","Two","Three"\] if split by ",". + Split the string by a divisor string, return an array of the substrings. Example "One,Two,Three" will return ["One","Two","Three"] if split by ",". @@ -37923,7 +37965,7 @@ A similar effect may be achieved moving this node's descendants. - Split the string in floats by using a divisor string, return an array of the substrings. Example "1,2.5,3" will return \[1,2.5,3\] if split by ",". + Split the string in floats by using a divisor string, return an array of the substrings. Example "1,2.5,3" will return [1,2.5,3] if split by ",". @@ -37945,7 +37987,7 @@ A similar effect may be achieved moving this node's descendants. - Return part of the string from "from", with length "len". + Return part of the string from the position [code]from[/code], with length [code]len[/code]. @@ -37959,14 +38001,14 @@ A similar effect may be achieved moving this node's descendants. - Convert a string, containing a decimal number, into a float. + Convert a string, containing a decimal number, into a [code]float[/code]. - Convert a string, containing an integer number, into an int. + Convert a string, containing an integer number, into an [code]int[/code]. @@ -37994,14 +38036,14 @@ A similar effect may be achieved moving this node's descendants. - Perform XML escaping on the string. + Return a copy of the string with special characters escaped using the XML standard. - Perform XML un-escaping of the string. + Return a copy of the string with escaped characters replaced by their meanings according to the XML standard. @@ -39262,8 +39304,6 @@ A similar effect may be achieved moving this node's descendants. - - @@ -39272,8 +39312,6 @@ A similar effect may be achieved moving this node's descendants. - - -- cgit v1.2.3