Merge pull request #64230 from YuriSizov/makerst-more-robust-tag-parser

Improve the `make_rst.py` parser for BBCode tags
This commit is contained in:
Max Hilbrunner 2022-08-17 14:43:58 +02:00 committed by GitHub
commit 5347732e5f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 704 additions and 529 deletions

View File

@ -692,7 +692,7 @@
<return type="int" /> <return type="int" />
<param index="0" name="screen" type="int" default="-1" /> <param index="0" name="screen" type="int" default="-1" />
<description> <description>
Returns the dots per inch density of the specified screen. If [param screen] is [/code]SCREEN_OF_MAIN_WINDOW[/code] (the default value), a screen with the main window will be used. Returns the dots per inch density of the specified screen. If [param screen] is [constant SCREEN_OF_MAIN_WINDOW] (the default value), a screen with the main window will be used.
[b]Note:[/b] On macOS, returned value is inaccurate if fractional display scaling mode is used. [b]Note:[/b] On macOS, returned value is inaccurate if fractional display scaling mode is used.
[b]Note:[/b] On Android devices, the actual screen densities are grouped into six generalized densities: [b]Note:[/b] On Android devices, the actual screen densities are grouped into six generalized densities:
[codeblock] [codeblock]

View File

@ -942,7 +942,7 @@
<param index="0" name="string" type="String" /> <param index="0" name="string" type="String" />
<param index="1" name="dict" type="PackedStringArray" /> <param index="1" name="dict" type="PackedStringArray" />
<description> <description>
Returns index of the first string in [code]dict[/dict] which is visually confusable with the [code]string[/string], or [code]-1[/code] if none is found. Returns index of the first string in [param dict] which is visually confusable with the [param string], or [code]-1[/code] if none is found.
[b]Note:[/b] This method doesn't detect invisible characters, for spoof detection use it in combination with [method spoof_check]. [b]Note:[/b] This method doesn't detect invisible characters, for spoof detection use it in combination with [method spoof_check].
[b]Note:[/b] Always returns [code]-1[/code] if the server does not support the [constant FEATURE_UNICODE_SECURITY] feature. [b]Note:[/b] Always returns [code]-1[/code] if the server does not support the [constant FEATURE_UNICODE_SECURITY] feature.
</description> </description>
@ -1707,10 +1707,10 @@
Glyph horizontal position is rounded to one quarter of the pixel size, each glyph is rasterized up to four times. Glyph horizontal position is rounded to one quarter of the pixel size, each glyph is rasterized up to four times.
</constant> </constant>
<constant name="SUBPIXEL_POSITIONING_ONE_HALF_MAX_SIZE" value="20" enum="SubpixelPositioning"> <constant name="SUBPIXEL_POSITIONING_ONE_HALF_MAX_SIZE" value="20" enum="SubpixelPositioning">
Maximum font size which will use one half of the pixel subpixel positioning in [constants SUBPIXEL_POSITIONING_AUTO] mode. Maximum font size which will use one half of the pixel subpixel positioning in [constant SUBPIXEL_POSITIONING_AUTO] mode.
</constant> </constant>
<constant name="SUBPIXEL_POSITIONING_ONE_QUARTER_MAX_SIZE" value="16" enum="SubpixelPositioning"> <constant name="SUBPIXEL_POSITIONING_ONE_QUARTER_MAX_SIZE" value="16" enum="SubpixelPositioning">
Maximum font size which will use one quarter of the pixel subpixel positioning in [constants SUBPIXEL_POSITIONING_AUTO] mode. Maximum font size which will use one quarter of the pixel subpixel positioning in [constant SUBPIXEL_POSITIONING_AUTO] mode.
</constant> </constant>
<constant name="FEATURE_SIMPLE_LAYOUT" value="1" enum="Feature"> <constant name="FEATURE_SIMPLE_LAYOUT" value="1" enum="Feature">
TextServer supports simple text layouts. TextServer supports simple text layouts.

View File

@ -939,7 +939,7 @@
<param index="0" name="string" type="String" /> <param index="0" name="string" type="String" />
<param index="1" name="dict" type="PackedStringArray" /> <param index="1" name="dict" type="PackedStringArray" />
<description> <description>
Returns index of the first string in [code]dict[/dict] which is visually confusable with the [code]string[/string], or [code]-1[/code] if none is found. Returns index of the first string in [param dict] which is visually confusable with the [param string], or [code]-1[/code] if none is found.
</description> </description>
</method> </method>
<method name="is_locale_right_to_left" qualifiers="virtual const"> <method name="is_locale_right_to_left" qualifiers="virtual const">

View File

@ -17,7 +17,7 @@
Translates [code]uv[/code] by using [code]scale[/code] and [code]offset[/code] values using the following formula: [code]uv = uv + offset * scale[/code]. [code]uv[/code] port is connected to [code]UV[/code] built-in by default. Translates [code]uv[/code] by using [code]scale[/code] and [code]offset[/code] values using the following formula: [code]uv = uv + offset * scale[/code]. [code]uv[/code] port is connected to [code]UV[/code] built-in by default.
</constant> </constant>
<constant name="FUNC_SCALING" value="1" enum="Function"> <constant name="FUNC_SCALING" value="1" enum="Function">
Scales [code]uv[/uv] by using [code]scale[/code] and [code]pivot[/code] values using the following formula: [code]uv = (uv - pivot) * scale + pivot[/code]. [code]uv[/code] port is connected to [code]UV[/code] built-in by default. Scales [code]uv[/code] by using [code]scale[/code] and [code]pivot[/code] values using the following formula: [code]uv = (uv - pivot) * scale + pivot[/code]. [code]uv[/code] port is connected to [code]UV[/code] built-in by default.
</constant> </constant>
<constant name="FUNC_MAX" value="2" enum="Function"> <constant name="FUNC_MAX" value="2" enum="Function">
Represents the size of the [enum Function] enum. Represents the size of the [enum Function] enum.

File diff suppressed because it is too large Load Diff

View File

@ -5,7 +5,7 @@
</brief_description> </brief_description>
<description> <description>
This resource defines an OpenXR action. Actions can be used both for inputs (buttons/joystick/trigger/etc) and outputs (haptics). This resource defines an OpenXR action. Actions can be used both for inputs (buttons/joystick/trigger/etc) and outputs (haptics).
OpenXR performs automatic conversion between action type and input type whenever possible. An analogue trigger bound to a boolean action will thus return [code]false[/core] if the trigger is depressed and [code]true[/code] if pressed fully. OpenXR performs automatic conversion between action type and input type whenever possible. An analogue trigger bound to a boolean action will thus return [code]false[/code] if the trigger is depressed and [code]true[/code] if pressed fully.
Actions are not directly bound to specific devices, instead OpenXR recognises a limited number of top level paths that identify devices by usage. We can restrict which devices an action can be bound to by these top level paths. For instance an action that should only be used for hand held controllers can have the top level paths "/user/hand/left" and "/user/hand/right" associated with them. See the [url=https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#semantic-path-reserved]reserved path section in the OpenXR specification[/url] for more info on the top level paths. Actions are not directly bound to specific devices, instead OpenXR recognises a limited number of top level paths that identify devices by usage. We can restrict which devices an action can be bound to by these top level paths. For instance an action that should only be used for hand held controllers can have the top level paths "/user/hand/left" and "/user/hand/right" associated with them. See the [url=https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#semantic-path-reserved]reserved path section in the OpenXR specification[/url] for more info on the top level paths.
Note that the name of the resource is used to register the action with. Note that the name of the resource is used to register the action with.
</description> </description>