blob: 9149e14a6240b36d63b0c6a265f5d08969efe4ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
|
<?xml version="1.0" encoding="UTF-8" ?>
<class name="DynamicFont" inherits="Font" category="Core" version="3.0-alpha">
<brief_description>
DynamicFont renders vector font files at runtime.
</brief_description>
<description>
DynamicFont renders vector font files (such as TTF or OTF) dynamically at runtime instead of using a prerendered texture atlas like [BitmapFont]. This trades the faster loading time of [BitmapFont]s for the ability to change font parameters like size and spacing during runtime. [DynamicFontData] is used for referencing the font file paths.
</description>
<tutorials>
</tutorials>
<demos>
</demos>
<methods>
<method name="add_fallback">
<return type="void">
</return>
<argument index="0" name="data" type="DynamicFontData">
</argument>
<description>
Adds a fallback font.
</description>
</method>
<method name="get_fallback" qualifiers="const">
<return type="DynamicFontData">
</return>
<argument index="0" name="idx" type="int">
</argument>
<description>
Returns the fallback font at index [code]idx[/code].
</description>
</method>
<method name="get_fallback_count" qualifiers="const">
<return type="int">
</return>
<description>
Returns the number of fallback fonts.
</description>
</method>
<method name="get_font_data" qualifiers="const">
<return type="DynamicFontData">
</return>
<description>
</description>
</method>
<method name="get_size" qualifiers="const">
<return type="int">
</return>
<description>
Returns the font size in pixels.
</description>
</method>
<method name="get_spacing" qualifiers="const">
<return type="int">
</return>
<argument index="0" name="type" type="int">
</argument>
<description>
Returns the given type of spacing in pixels. See [code]SPACING_*[/code] constants.
</description>
</method>
<method name="get_use_filter" qualifiers="const">
<return type="bool">
</return>
<description>
Returns [code]true[/code] if filtering is used.
</description>
</method>
<method name="get_use_mipmaps" qualifiers="const">
<return type="bool">
</return>
<description>
Returns [code]true[/code] if mipmapping is used.
</description>
</method>
<method name="remove_fallback">
<return type="void">
</return>
<argument index="0" name="idx" type="int">
</argument>
<description>
Removes the fallback font at index [code]idx[/code].
</description>
</method>
<method name="set_fallback">
<return type="void">
</return>
<argument index="0" name="idx" type="int">
</argument>
<argument index="1" name="data" type="DynamicFontData">
</argument>
<description>
Sets the fallback font at index [code]idx[/code].
</description>
</method>
<method name="set_font_data">
<return type="void">
</return>
<argument index="0" name="data" type="DynamicFontData">
</argument>
<description>
Sets the [DynamicFontData].
</description>
</method>
<method name="set_size">
<return type="void">
</return>
<argument index="0" name="data" type="int">
</argument>
<description>
Sets the font size.
</description>
</method>
<method name="set_spacing">
<return type="void">
</return>
<argument index="0" name="type" type="int">
</argument>
<argument index="1" name="value" type="int">
</argument>
<description>
Sets the spacing of the given type. See [code]SPACING_*[/code] constants.
</description>
</method>
<method name="set_use_filter">
<return type="void">
</return>
<argument index="0" name="enable" type="bool">
</argument>
<description>
Set to [code]true[/code] to use filtering.
</description>
</method>
<method name="set_use_mipmaps">
<return type="void">
</return>
<argument index="0" name="enable" type="bool">
</argument>
<description>
Set to [code]true[/code] to use mipmapping.
</description>
</method>
</methods>
<members>
<member name="extra_spacing_bottom" type="int" setter="set_spacing" getter="get_spacing">
Extra spacing at the bottom in pixels.
</member>
<member name="extra_spacing_char" type="int" setter="set_spacing" getter="get_spacing">
Extra character spacing in pixels.
</member>
<member name="extra_spacing_space" type="int" setter="set_spacing" getter="get_spacing">
Extra space spacing in pixels.
</member>
<member name="extra_spacing_top" type="int" setter="set_spacing" getter="get_spacing">
Extra spacing at the top in pixels.
</member>
<member name="font_data" type="DynamicFontData" setter="set_font_data" getter="get_font_data">
The font data.
</member>
<member name="size" type="int" setter="set_size" getter="get_size">
The font size.
</member>
<member name="use_filter" type="bool" setter="set_use_filter" getter="get_use_filter">
If [code]true[/code] filtering is used.
</member>
<member name="use_mipmaps" type="bool" setter="set_use_mipmaps" getter="get_use_mipmaps">
If [code]true[/code] mipmapping is used.
</member>
</members>
<constants>
<constant name="SPACING_TOP" value="0">
Spacing at the top.
</constant>
<constant name="SPACING_BOTTOM" value="1">
Spacing at the bottom.
</constant>
<constant name="SPACING_CHAR" value="2">
Character spacing.
</constant>
<constant name="SPACING_SPACE" value="3">
Space spacing.
</constant>
</constants>
</class>
|