Improve parsing of [method ...] tags
Also improve some code display.
This commit is contained in:
parent
1af65aff44
commit
0f11b322b3
2 changed files with 19 additions and 27 deletions
|
@ -1780,7 +1780,7 @@
|
|||
<argument index="0" name="with" type="AABB">
|
||||
</argument>
|
||||
<description>
|
||||
Return the intersection between two [AABB]s. An empty AABB (size 0,0,0) is returned on failure.
|
||||
Return the intersection between two [AABB]. An empty AABB (size 0,0,0) is returned on failure.
|
||||
</description>
|
||||
</method>
|
||||
<method name="intersects">
|
||||
|
@ -5925,7 +5925,7 @@
|
|||
<return type="bool">
|
||||
</return>
|
||||
<description>
|
||||
Return true of this is the current camera (see [method Camera2D.make_current]).
|
||||
Return true of this is the current camera (see [method make_current]).
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_limit">
|
||||
|
@ -7339,7 +7339,7 @@
|
|||
</argument>
|
||||
<description>
|
||||
Set the array of points forming the polygon.
|
||||
When editing the point list via the editor, depending on [method get_build_mode], it has to be a list of points (for [code]build_mode[/code]=0), or a list of lines (for [code]build_mode[/code]=1). In the second case, the even elements of the array define the start point of the line, and the odd elements the end point.
|
||||
When editing the point list via the editor, depending on [method get_build_mode], it has to be a list of points (for [code]build_mode==0[/code]), or a list of lines (for [code]build_mode==1[/code]). In the second case, the even elements of the array define the start point of the line, and the odd elements the end point.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_polygon" qualifiers="const">
|
||||
|
@ -7353,14 +7353,14 @@
|
|||
<argument index="0" name="build_mode" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Set whether the polygon is to be a [ConvexPolygon2D] ([code]build_mode[/code]=0), or a [ConcavePolygon2D] ([code]build_mode[/code]=1).
|
||||
Set whether the polygon is to be a [ConvexPolygon2D] ([code]build_mode==0[/code]), or a [ConcavePolygon2D] ([code]build_mode==1[/code]).
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_build_mode" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<description>
|
||||
Return whether the polygon is a [ConvexPolygon2D] ([code]build_mode[/code]=0), or a [ConcavePolygon2D] ([code]build_mode[/code]=1).
|
||||
Return whether the polygon is a [ConvexPolygon2D] ([code]build_mode==0[/code]), or a [ConcavePolygon2D] ([code]build_mode==1[/code]).
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_trigger">
|
||||
|
@ -12909,18 +12909,12 @@ verify_host will check the SSL identity of the host if set to true.
|
|||
<argument index="3" name="body" type="String" default="""">
|
||||
</argument>
|
||||
<description>
|
||||
Sends a request to the connected host. The url is the what is normally behind the hostname, i.e:
|
||||
http://somehost.com/index.php
|
||||
url would be "index.php"
|
||||
|
||||
Headers are HTTP request headers
|
||||
|
||||
To create a POST request with query strings to push to the server, do:
|
||||
var fields = {"username" : "user",
|
||||
"password" : "pass"}
|
||||
Sends a request to the connected host. The url is what is normally behind the hostname, i.e. in [code]http://somehost.com/index.php[/code], url would be "index.php".
|
||||
Headers are HTTP request headers.
|
||||
To create a POST request with query strings to push to the server, do::
|
||||
var fields = {"username" : "user", "password" : "pass"}
|
||||
var queryString = httpClient.query_string_from_dict(fields)
|
||||
var headers = ["Content-Type: application/x-www-form-urlencoded",
|
||||
"Content-Length: " + str(queryString.length())]
|
||||
var headers = ["Content-Type: application/x-www-form-urlencoded", "Content-Length: " + str(queryString.length())]
|
||||
var result = httpClient.request(httpClient.METHOD_POST, "index.php", headers, queryString)
|
||||
</description>
|
||||
</method>
|
||||
|
@ -13028,11 +13022,9 @@ var result = httpClient.request(httpClient.METHOD_POST, "index.php", headers, qu
|
|||
<argument index="0" name="fields" type="Dictionary">
|
||||
</argument>
|
||||
<description>
|
||||
Generates a GET/POST application/x-www-form-urlencoded style query string from a provided dictionary.
|
||||
|
||||
Generates a GET/POST application/x-www-form-urlencoded style query string from a provided dictionary, e.g.::
|
||||
var fields = {"username": "user", "password": "pass"}
|
||||
String queryString = httpClient.query_string_from_dict(fields)
|
||||
|
||||
returns:= "username=user&password=pass"
|
||||
</description>
|
||||
</method>
|
||||
|
|
|
@ -166,9 +166,9 @@ def rstize_text(text,cclass):
|
|||
|
||||
if param.find('.') != -1:
|
||||
(class_param, method_param) = param.split('.')
|
||||
tag_text = ':ref:`'+class_param+'.'+method_param+'<' + class_param.lower() + '_' + method_param + '>`'
|
||||
tag_text = ':ref:`'+class_param+'.'+method_param+'<class_' + class_param + '_' + method_param + '>`'
|
||||
else:
|
||||
tag_text = ':ref:`' + param + '<' + cclass +"_"+ param + '>`'
|
||||
tag_text = ':ref:`' + param + '<class_' + cclass +"_"+ param + '>`'
|
||||
elif cmd.find('image=') == 0:
|
||||
tag_text = "" #'![](' + cmd[6:] + ')'
|
||||
elif cmd.find('url=') == 0:
|
||||
|
|
Loading…
Reference in a new issue