classref: Run doctool and merge BitmapFont

BitmapFont was split from the Font class, so the relevant method
descriptions were readded manually.
This commit is contained in:
Rémi Verschelde 2016-04-29 18:28:07 +02:00
parent 6aae63fce2
commit 18c09acf9f
1 changed files with 209 additions and 203 deletions

View File

@ -5540,7 +5540,7 @@
</signals> </signals>
<constants> <constants>
<constant name="DRAW_NORMAL" value="0"> <constant name="DRAW_NORMAL" value="0">
The normal state(Are not pressed, not hovered, not toggled and enabled) of buttons. The normal state (i.e. not pressed, not hovered, not toggled and enabled) of buttons.
</constant> </constant>
<constant name="DRAW_PRESSED" value="1"> <constant name="DRAW_PRESSED" value="1">
The state of buttons are pressed. The state of buttons are pressed.
@ -5611,6 +5611,130 @@
<constants> <constants>
</constants> </constants>
</class> </class>
<class name="BitmapFont" inherits="Font" category="Core">
<brief_description>
</brief_description>
<description>
</description>
<methods>
<method name="create_from_fnt">
<return type="int">
</return>
<argument index="0" name="path" type="String">
</argument>
<description>
</description>
</method>
<method name="set_height">
<argument index="0" name="px" type="float">
</argument>
<description>
Set the total font height (ascent plus descent) in pixels.
</description>
</method>
<method name="set_ascent">
<argument index="0" name="px" type="float">
</argument>
<description>
Set the font ascent (number of pixels above the baseline).
</description>
</method>
<method name="add_kerning_pair">
<argument index="0" name="char_a" type="int">
</argument>
<argument index="1" name="char_b" type="int">
</argument>
<argument index="2" name="kerning" type="int">
</argument>
<description>
Add a kerning pair to the [BitmapFont] as a difference. Kerning pairs are special cases where a typeface advance is determined by the next character.
</description>
</method>
<method name="get_kerning_pair" qualifiers="const">
<return type="int">
</return>
<argument index="0" name="char_a" type="int">
</argument>
<argument index="1" name="char_b" type="int">
</argument>
<description>
Return a kerning pair as a difference.
</description>
</method>
<method name="add_texture">
<argument index="0" name="texture" type="Texture">
</argument>
<description>
Add a texture to the [BitmapFont].
</description>
</method>
<method name="add_char">
<argument index="0" name="character" type="int">
</argument>
<argument index="1" name="texture" type="int">
</argument>
<argument index="2" name="rect" type="Rect2">
</argument>
<argument index="3" name="align" type="Vector2" default="Vector2(0,0)">
</argument>
<argument index="4" name="advance" type="float" default="-1">
</argument>
<description>
Add a character to the font, where [i]character[/i] is the unicode value, [i]texture[/i] is the texture index, [i]rect[/i] is the region in the texture (in pixels!), [i]align[/i] is the (optional) alignment for the character and [i]advance[/i] is the (optional) advance.
</description>
</method>
<method name="get_texture_count" qualifiers="const">
<return type="int">
</return>
<description>
</description>
</method>
<method name="get_texture" qualifiers="const">
<return type="Texture">
</return>
<argument index="0" name="idx" type="int">
</argument>
<description>
</description>
</method>
<method name="get_char_size" qualifiers="const">
<return type="Vector2">
</return>
<argument index="0" name="char" type="int">
</argument>
<argument index="1" name="next" type="int" default="0">
</argument>
<description>
Return the size of a character, optionally taking kerning into account if the next character is provided.
</description>
</method>
<method name="set_distance_field_hint">
<argument index="0" name="enable" type="bool">
</argument>
<description>
</description>
</method>
<method name="clear">
<description>
Clear all the font data.
</description>
</method>
<method name="set_fallback">
<argument index="0" name="fallback" type="Object">
</argument>
<description>
</description>
</method>
<method name="get_fallback" qualifiers="const">
<return type="Object">
</return>
<description>
</description>
</method>
</methods>
<constants>
</constants>
</class>
<class name="BoneAttachment" inherits="Spatial" category="Core"> <class name="BoneAttachment" inherits="Spatial" category="Core">
<brief_description> <brief_description>
</brief_description> </brief_description>
@ -12151,33 +12275,19 @@ Returns an empty String "" at the end of the list.
Font contains an unicode compatible character set, as well as the ability to draw it with variable width, ascent, descent and kerning. For creating fonts from TTF files (or other font formats), see the editor support for fonts. TODO check wikipedia for graph of ascent/baseline/descent/height/etc. Font contains an unicode compatible character set, as well as the ability to draw it with variable width, ascent, descent and kerning. For creating fonts from TTF files (or other font formats), see the editor support for fonts. TODO check wikipedia for graph of ascent/baseline/descent/height/etc.
</description> </description>
<methods> <methods>
<method name="create_from_fnt"> <method name="draw" qualifiers="const">
<return type="int"> <argument index="0" name="canvas_item" type="RID">
</return> </argument>
<argument index="0" name="path" type="String"> <argument index="1" name="pos" type="Vector2">
</argument>
<argument index="2" name="string" type="String">
</argument>
<argument index="3" name="modulate" type="Color" default="Color(1,1,1,1)">
</argument>
<argument index="4" name="clip_w" type="int" default="-1">
</argument> </argument>
<description> <description>
</description> Draw "string" into a canvas item using the font at a given "pos" position, with "modulate" color, and optionally clipping the width. "pos" specifies the baseline, not the top. To draw from the top, [i]ascent[/i] must be added to the Y axis.
</method>
<method name="set_height">
<argument index="0" name="px" type="float">
</argument>
<description>
Set the total font height (ascent plus descent) in pixels.
</description>
</method>
<method name="get_height" qualifiers="const">
<return type="float">
</return>
<description>
Return the total font height (ascent plus descent) in pixels.
</description>
</method>
<method name="set_ascent">
<argument index="0" name="px" type="float">
</argument>
<description>
Set the font ascent (number of pixels above the baseline).
</description> </description>
</method> </method>
<method name="get_ascent" qualifiers="const"> <method name="get_ascent" qualifiers="const">
@ -12194,75 +12304,19 @@ Returns an empty String "" at the end of the list.
Return the font descent (number of pixels below the baseline). Return the font descent (number of pixels below the baseline).
</description> </description>
</method> </method>
<method name="add_kerning_pair"> <method name="get_height" qualifiers="const">
<argument index="0" name="char_a" type="int"> <return type="float">
</argument>
<argument index="1" name="char_b" type="int">
</argument>
<argument index="2" name="kerning" type="int">
</argument>
<description>
Add a kerning pair to the [Font] as a difference. Kerning pairs are special cases where a typeface advance is determined by the next character.
</description>
</method>
<method name="get_kerning_pair" qualifiers="const">
<return type="int">
</return>
<argument index="0" name="char_a" type="int">
</argument>
<argument index="1" name="char_b" type="int">
</argument>
<description>
Return a kerning pair as a difference. Kerning pairs are special cases where a typeface advance is determined by the next character.
</description>
</method>
<method name="add_texture">
<argument index="0" name="texture" type="Texture">
</argument>
<description>
Add a texture to the [Font].
</description>
</method>
<method name="add_char">
<argument index="0" name="character" type="int">
</argument>
<argument index="1" name="texture" type="int">
</argument>
<argument index="2" name="rect" type="Rect2">
</argument>
<argument index="3" name="align" type="Vector2" default="Vector2(0,0)">
</argument>
<argument index="4" name="advance" type="float" default="-1">
</argument>
<description>
Add a character to the font, where "character" is the unicode value, "texture" is the texture index, "rect" is the region in the texture (in pixels!), "align" is the (optional) alignment for the character and "advance" is the (optional) advance.
</description>
</method>
<method name="get_texture_count" qualifiers="const">
<return type="int">
</return> </return>
<description> <description>
Return the total font height (ascent plus descent) in pixels.
</description> </description>
</method> </method>
<method name="get_texture" qualifiers="const"> <method name="is_distance_field_hint" qualifiers="const">
<return type="Texture"> <return type="bool">
</return> </return>
<argument index="0" name="idx" type="int">
</argument>
<description> <description>
</description> </description>
</method> </method>
<method name="get_char_size" qualifiers="const">
<return type="Vector2">
</return>
<argument index="0" name="char" type="int">
</argument>
<argument index="1" name="next" type="int" default="0">
</argument>
<description>
Return the size of a character, optionally taking kerning into account if the next character is provided.
</description>
</method>
<method name="get_string_size" qualifiers="const"> <method name="get_string_size" qualifiers="const">
<return type="Vector2"> <return type="Vector2">
</return> </return>
@ -12272,38 +12326,6 @@ Returns an empty String "" at the end of the list.
Return the size of a string, taking kerning and advance into account. Return the size of a string, taking kerning and advance into account.
</description> </description>
</method> </method>
<method name="set_distance_field_hint">
<argument index="0" name="enable" type="bool">
</argument>
<description>
</description>
</method>
<method name="is_distance_field_hint" qualifiers="const">
<return type="bool">
</return>
<description>
</description>
</method>
<method name="clear">
<description>
Clear all the font data.
</description>
</method>
<method name="draw" qualifiers="const">
<argument index="0" name="canvas_item" type="RID">
</argument>
<argument index="1" name="pos" type="Vector2">
</argument>
<argument index="2" name="string" type="String">
</argument>
<argument index="3" name="modulate" type="Color" default="Color(1,1,1,1)">
</argument>
<argument index="4" name="clip_w" type="int" default="-1">
</argument>
<description>
Draw "string" into a canvas item using the font at a given "pos" position, with "modulate" color, and optionally clipping the width. "pos" specifies the baseline, not the top. To draw from the top, [i]ascent[/i] must be added to the Y axis.
</description>
</method>
<method name="draw_char" qualifiers="const"> <method name="draw_char" qualifiers="const">
<return type="float"> <return type="float">
</return> </return>
@ -12321,18 +12343,6 @@ Returns an empty String "" at the end of the list.
Draw character "char" into a canvas item using the font at a given "pos" position, with "modulate" color, and optionally kerning if "next" is passed. clipping the width. "pos" specifies the baseline, not the top. To draw from the top, [i]ascent[/i] must be added to the Y axis. The width used by the character is returned, making this function useful for drawing strings character by character. Draw character "char" into a canvas item using the font at a given "pos" position, with "modulate" color, and optionally kerning if "next" is passed. clipping the width. "pos" specifies the baseline, not the top. To draw from the top, [i]ascent[/i] must be added to the Y axis. The width used by the character is returned, making this function useful for drawing strings character by character.
</description> </description>
</method> </method>
<method name="set_fallback">
<argument index="0" name="fallback" type="Object">
</argument>
<description>
</description>
</method>
<method name="get_fallback" qualifiers="const">
<return type="Object">
</return>
<description>
</description>
</method>
</methods> </methods>
<constants> <constants>
</constants> </constants>
@ -40564,16 +40574,12 @@ This method controls whether the position between two cached points is interpola
</methods> </methods>
<members> <members>
<member name="x" type="float"> <member name="x" type="float">
The X axis value when treated as point(The first value in the pair).
</member> </member>
<member name="y" type="float"> <member name="y" type="float">
The Y axis value when treated as point(The second value in the pair).
</member> </member>
<member name="width" type="float"> <member name="width" type="float">
The width value when treated as size(The first value in the pair).
</member> </member>
<member name="height" type="float"> <member name="height" type="float">
The height value when treated as size(The second value in the pair).
</member> </member>
</members> </members>
<constants> <constants>