-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclassFont.html
More file actions
662 lines (596 loc) · 33.4 KB
/
classFont.html
File metadata and controls
662 lines (596 loc) · 33.4 KB
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
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
<!-- HTML header for doxygen 1.15.0-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.16.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Hatch Game Engine Documentation: Font Class Reference</title>
<link rel="icon" href="favicon.ico" type="image/x-icon" />
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
$(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr id="projectrow">
<td id="projectlogo"><img alt="Logo" src="logo.svg" width="55" height="55"/></td>
<td id="projectalign">
<div id="projectname">Hatch Game Engine Documentation<span id="projectnumber"> v1.4.0</span>
</div>
<div id="projectbrief">The documentation for the Hatch Game Engine</div>
</td>
<td> <div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<span id="MSearchSelect" class="search-icon" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()"><span class="search-icon-dropdown"></span></span>
<input type="text" id="MSearchField" value="" placeholder="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><div id="MSearchCloseImg" class="close-icon"></div></a>
</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.16.0 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search/",'.html');
</script>
<script type="text/javascript">
$(function() { codefold.init(); });
</script>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
$(function(){initNavTree('classFont.html','','classFont-members'); });
</script>
<div id="container">
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>
<div class="header">
<div class="headertitle"><div class="title">Font Class Reference<div class="ingroups"><a class="el" href="group__hsl.html">HSL</a></div></div></div>
</div><!--header-->
<div class="contents">
<p>Representation of a TrueType font.
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 id="header-pub-methods" class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a7d59be915c8e6377a58c01c40c83cbd5" id="r_a7d59be915c8e6377a58c01c40c83cbd5"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#a7d59be915c8e6377a58c01c40c83cbd5">GetPixelsPerUnit</a> ()</td></tr>
<tr class="memdesc:a7d59be915c8e6377a58c01c40c83cbd5"><td class="mdescLeft"> </td><td class="mdescRight">Gets the pixels per unit value of the font. The default for all fonts is <span class="tt">40</span>. <br /></td></tr>
<tr class="memitem:a91d911054a46777ec4b345d80cab37a5" id="r_a91d911054a46777ec4b345d80cab37a5"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#a91d911054a46777ec4b345d80cab37a5">GetAscent</a> ()</td></tr>
<tr class="memdesc:a91d911054a46777ec4b345d80cab37a5"><td class="mdescLeft"> </td><td class="mdescRight">Gets the distance in pixels above the baseline. <br /></td></tr>
<tr class="memitem:ae93231f69051a078f13867a56c775575" id="r_ae93231f69051a078f13867a56c775575"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#ae93231f69051a078f13867a56c775575">GetDescent</a> ()</td></tr>
<tr class="memdesc:ae93231f69051a078f13867a56c775575"><td class="mdescLeft"> </td><td class="mdescRight">Gets the distance in pixels below the baseline. <br /></td></tr>
<tr class="memitem:ab1b1a1b89ac438e3cd71f5b249444f45" id="r_ab1b1a1b89ac438e3cd71f5b249444f45"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#ab1b1a1b89ac438e3cd71f5b249444f45">GetLeading</a> ()</td></tr>
<tr class="memdesc:ab1b1a1b89ac438e3cd71f5b249444f45"><td class="mdescLeft"> </td><td class="mdescRight">Gets the distance between lines in pixels. <br /></td></tr>
<tr class="memitem:a354c5d8155077e139d26d985f06815b3" id="r_a354c5d8155077e139d26d985f06815b3"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#a354c5d8155077e139d26d985f06815b3">GetSpaceWidth</a> ()</td></tr>
<tr class="memdesc:a354c5d8155077e139d26d985f06815b3"><td class="mdescLeft"> </td><td class="mdescRight">Gets the width of the space character. <br /></td></tr>
<tr class="memitem:a344ce52bb363d1d1df9c26c83126e34f" id="r_a344ce52bb363d1d1df9c26c83126e34f"><td class="memItemLeft">integer </td><td class="memItemRight"><a class="el" href="#a344ce52bb363d1d1df9c26c83126e34f">GetOversampling</a> ()</td></tr>
<tr class="memdesc:a344ce52bb363d1d1df9c26c83126e34f"><td class="mdescLeft"> </td><td class="mdescRight">Gets the oversampling value. The default is <span class="tt">1</span> for all fonts. <br /></td></tr>
<tr class="memitem:a6f5513b216514d73cec89ba4a42da48b" id="r_a6f5513b216514d73cec89ba4a42da48b"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#a6f5513b216514d73cec89ba4a42da48b">GetPixelCoverageThreshold</a> ()</td></tr>
<tr class="memdesc:a6f5513b216514d73cec89ba4a42da48b"><td class="mdescLeft"> </td><td class="mdescRight">Gets the pixel coverage threshold value. Pixels with coverage under this value become fully transparent, and pixels with coverage equal to or above this value become fully opaque. The default is <span class="tt">0.5</span> for all fonts. <br /></td></tr>
<tr class="memitem:a123e224803f016cb6679adbe8a20156d" id="r_a123e224803f016cb6679adbe8a20156d"><td class="memItemLeft">decimal </td><td class="memItemRight"><a class="el" href="#a123e224803f016cb6679adbe8a20156d">GetGlyphAdvance</a> (integer codepoint)</td></tr>
<tr class="memdesc:a123e224803f016cb6679adbe8a20156d"><td class="mdescLeft"> </td><td class="mdescRight">Gets the advance width of a given glyph through its code point, if it exists in the font. <br /></td></tr>
<tr class="memitem:a12b12a0e0ae33cd2eff9faefec2e5ad4" id="r_a12b12a0e0ae33cd2eff9faefec2e5ad4"><td class="memItemLeft">boolean </td><td class="memItemRight"><a class="el" href="#a12b12a0e0ae33cd2eff9faefec2e5ad4">IsAntialiasingEnabled</a> ()</td></tr>
<tr class="memdesc:a12b12a0e0ae33cd2eff9faefec2e5ad4"><td class="mdescLeft"> </td><td class="mdescRight">Gets whether the font has anti-aliasing enabled. <br /></td></tr>
<tr class="memitem:aa0fd78cca931d349a9e096e6438dd9cf" id="r_aa0fd78cca931d349a9e096e6438dd9cf"><td class="memItemLeft">boolean </td><td class="memItemRight"><a class="el" href="#aa0fd78cca931d349a9e096e6438dd9cf">HasGlyph</a> (integer codepoint)</td></tr>
<tr class="memdesc:aa0fd78cca931d349a9e096e6438dd9cf"><td class="mdescLeft"> </td><td class="mdescRight">Checks if the font has a glyph for the given code point. <br /></td></tr>
<tr class="memitem:abfa8e7ef09eb02938ff0982471ca4444" id="r_abfa8e7ef09eb02938ff0982471ca4444"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#abfa8e7ef09eb02938ff0982471ca4444">SetPixelsPerUnit</a> (number pixelsPerUnit)</td></tr>
<tr class="memdesc:abfa8e7ef09eb02938ff0982471ca4444"><td class="mdescLeft"> </td><td class="mdescRight">Sets the pixels per unit value of the font. Higher values improve the clarity, at the cost of increased memory usage. Note that this causes all glyphs to be reloaded, so this should usually only be called once. <br /></td></tr>
<tr class="memitem:a7270c4931e39b313bcf8d5c2b8b9f0c1" id="r_a7270c4931e39b313bcf8d5c2b8b9f0c1"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#a7270c4931e39b313bcf8d5c2b8b9f0c1">SetAscent</a> (number ascent)</td></tr>
<tr class="memdesc:a7270c4931e39b313bcf8d5c2b8b9f0c1"><td class="mdescLeft"> </td><td class="mdescRight">Sets the distance in pixels above the baseline. <br /></td></tr>
<tr class="memitem:ababe93507a4ab8d3e327a8cfb586d8ef" id="r_ababe93507a4ab8d3e327a8cfb586d8ef"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#ababe93507a4ab8d3e327a8cfb586d8ef">SetDescent</a> (number descent)</td></tr>
<tr class="memdesc:ababe93507a4ab8d3e327a8cfb586d8ef"><td class="mdescLeft"> </td><td class="mdescRight">Sets the distance in pixels below the baseline. <br /></td></tr>
<tr class="memitem:a78e5d218ef68ccc22a0a232041ec8c05" id="r_a78e5d218ef68ccc22a0a232041ec8c05"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#a78e5d218ef68ccc22a0a232041ec8c05">SetLeading</a> (number leading)</td></tr>
<tr class="memdesc:a78e5d218ef68ccc22a0a232041ec8c05"><td class="mdescLeft"> </td><td class="mdescRight">Sets the distance between lines in pixels. <br /></td></tr>
<tr class="memitem:a6c9fef7690d9cca1201ab680dddc5326" id="r_a6c9fef7690d9cca1201ab680dddc5326"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#a6c9fef7690d9cca1201ab680dddc5326">SetSpaceWidth</a> (number spaceWidth)</td></tr>
<tr class="memdesc:a6c9fef7690d9cca1201ab680dddc5326"><td class="mdescLeft"> </td><td class="mdescRight">Sets the width of the space character. <br /></td></tr>
<tr class="memitem:ae312c2aa71e4b48f016cfc45c8b96b14" id="r_ae312c2aa71e4b48f016cfc45c8b96b14"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#ae312c2aa71e4b48f016cfc45c8b96b14">SetOversampling</a> (integer oversampling)</td></tr>
<tr class="memdesc:ae312c2aa71e4b48f016cfc45c8b96b14"><td class="mdescLeft"> </td><td class="mdescRight">Sets the oversampling value. Higher values increase font quality. Changing this value causes all font glyphs to be reloaded. <br /></td></tr>
<tr class="memitem:ae93b28b362ea1410b4737509fc06d076" id="r_ae93b28b362ea1410b4737509fc06d076"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#ae93b28b362ea1410b4737509fc06d076">SetPixelCoverageThreshold</a> (decimal threshold)</td></tr>
<tr class="memdesc:ae93b28b362ea1410b4737509fc06d076"><td class="mdescLeft"> </td><td class="mdescRight">Sets the pixel coverage threshold value. Pixels with coverage under this value become fully transparent, and pixels with coverage equal to or above this value become fully opaque. This only has an effect on fonts with anti-aliasing disabled. <br /></td></tr>
<tr class="memitem:a3a6fefd5c106fdb6cd5bee848e260d55" id="r_a3a6fefd5c106fdb6cd5bee848e260d55"><td class="memItemLeft">void </td><td class="memItemRight"><a class="el" href="#a3a6fefd5c106fdb6cd5bee848e260d55">SetAntialiasing</a> (boolean useAntialiasing)</td></tr>
<tr class="memdesc:a3a6fefd5c106fdb6cd5bee848e260d55"><td class="mdescLeft"> </td><td class="mdescRight">Enables or disables anti-aliasing on the font. If disabling, you may want to increase the pixel coverage value with <a class="el" href="#ae93b28b362ea1410b4737509fc06d076" title="Font.SetPixelCoverageThreshold">Font.SetPixelCoverageThreshold</a>. <br /></td></tr>
<tr class="memitem:a50162138949a7f27cd560ed1956e3f5d" id="r_a50162138949a7f27cd560ed1956e3f5d"><td class="memItemLeft"> </td><td class="memItemRight"><a class="el" href="#a50162138949a7f27cd560ed1956e3f5d">Font</a> (string font)</td></tr>
<tr class="memdesc:a50162138949a7f27cd560ed1956e3f5d"><td class="mdescLeft"> </td><td class="mdescRight">Loads a font from the given resource path. <br /></td></tr>
<tr class="memitem:a2c3f3a27df600ecdba036297cd5c5a94" id="r_a2c3f3a27df600ecdba036297cd5c5a94"><td class="memItemLeft"> </td><td class="memItemRight"><a class="el" href="#a2c3f3a27df600ecdba036297cd5c5a94">Font</a> (stream font)</td></tr>
<tr class="memdesc:a2c3f3a27df600ecdba036297cd5c5a94"><td class="mdescLeft"> </td><td class="mdescRight">Loads a font from the given stream. <br /></td></tr>
<tr class="memitem:a1c8fd851009fd1b76eecc7ce7b139030" id="r_a1c8fd851009fd1b76eecc7ce7b139030"><td class="memItemLeft"> </td><td class="memItemRight"><a class="el" href="#a1c8fd851009fd1b76eecc7ce7b139030">Font</a> (array font)</td></tr>
<tr class="memdesc:a1c8fd851009fd1b76eecc7ce7b139030"><td class="mdescLeft"> </td><td class="mdescRight">Loads a font from the given array containing resource paths or streams. <br /></td></tr>
</table>
<a name="details" id="details"></a><h2 id="header-details" class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Representation of a TrueType font. </p>
</div><a name="doc-constructors" id="doc-constructors"></a><h2 id="header-doc-constructors" class="groupheader">Constructor & Destructor Documentation</h2>
<a id="a50162138949a7f27cd560ed1956e3f5d" name="a50162138949a7f27cd560ed1956e3f5d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a50162138949a7f27cd560ed1956e3f5d">◆ </a></span>Font() <span class="overload">[1/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">Font.Font </td>
<td>(</td>
<td class="paramtype">string</td> <td class="paramname"><span class="paramname"><em>font</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Loads a font from the given resource path. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">font</td><td>The font. If this argument is not given, it will use font the application was built with, if one is present. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a2c3f3a27df600ecdba036297cd5c5a94" name="a2c3f3a27df600ecdba036297cd5c5a94"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2c3f3a27df600ecdba036297cd5c5a94">◆ </a></span>Font() <span class="overload">[2/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">Font.Font </td>
<td>(</td>
<td class="paramtype">stream</td> <td class="paramname"><span class="paramname"><em>font</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Loads a font from the given stream. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">font</td><td>The font. If this argument is not given, it will use font the application was built with, if one is present. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a1c8fd851009fd1b76eecc7ce7b139030" name="a1c8fd851009fd1b76eecc7ce7b139030"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1c8fd851009fd1b76eecc7ce7b139030">◆ </a></span>Font() <span class="overload">[3/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">Font.Font </td>
<td>(</td>
<td class="paramtype">array</td> <td class="paramname"><span class="paramname"><em>font</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Loads a font from the given array containing resource paths or streams. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">font</td><td>The list of fonts. If this argument is not given, it will use font the application was built with, if one is present. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a name="doc-func-members" id="doc-func-members"></a><h2 id="header-doc-func-members" class="groupheader">Member Function Documentation</h2>
<a id="a91d911054a46777ec4b345d80cab37a5" name="a91d911054a46777ec4b345d80cab37a5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a91d911054a46777ec4b345d80cab37a5">◆ </a></span>GetAscent()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetAscent </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the distance in pixels above the baseline. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value. </dd></dl>
</div>
</div>
<a id="ae93231f69051a078f13867a56c775575" name="ae93231f69051a078f13867a56c775575"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae93231f69051a078f13867a56c775575">◆ </a></span>GetDescent()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetDescent </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the distance in pixels below the baseline. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value. </dd></dl>
</div>
</div>
<a id="a123e224803f016cb6679adbe8a20156d" name="a123e224803f016cb6679adbe8a20156d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a123e224803f016cb6679adbe8a20156d">◆ </a></span>GetGlyphAdvance()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetGlyphAdvance </td>
<td>(</td>
<td class="paramtype">integer</td> <td class="paramname"><span class="paramname"><em>codepoint</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the advance width of a given glyph through its code point, if it exists in the font. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">codepoint</td><td>An Unicode code point. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value, or <span class="tt">null</span> if no glyph representing the given code point exists in the font. </dd></dl>
</div>
</div>
<a id="ab1b1a1b89ac438e3cd71f5b249444f45" name="ab1b1a1b89ac438e3cd71f5b249444f45"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab1b1a1b89ac438e3cd71f5b249444f45">◆ </a></span>GetLeading()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetLeading </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the distance between lines in pixels. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value. </dd></dl>
</div>
</div>
<a id="a344ce52bb363d1d1df9c26c83126e34f" name="a344ce52bb363d1d1df9c26c83126e34f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a344ce52bb363d1d1df9c26c83126e34f">◆ </a></span>GetOversampling()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">integer Font.GetOversampling </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the oversampling value. The default is <span class="tt">1</span> for all fonts. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns an integer value. </dd></dl>
</div>
</div>
<a id="a6f5513b216514d73cec89ba4a42da48b" name="a6f5513b216514d73cec89ba4a42da48b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6f5513b216514d73cec89ba4a42da48b">◆ </a></span>GetPixelCoverageThreshold()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetPixelCoverageThreshold </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the pixel coverage threshold value. Pixels with coverage under this value become fully transparent, and pixels with coverage equal to or above this value become fully opaque. The default is <span class="tt">0.5</span> for all fonts. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value. </dd></dl>
</div>
</div>
<a id="a7d59be915c8e6377a58c01c40c83cbd5" name="a7d59be915c8e6377a58c01c40c83cbd5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7d59be915c8e6377a58c01c40c83cbd5">◆ </a></span>GetPixelsPerUnit()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetPixelsPerUnit </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the pixels per unit value of the font. The default for all fonts is <span class="tt">40</span>. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value. </dd></dl>
</div>
</div>
<a id="a354c5d8155077e139d26d985f06815b3" name="a354c5d8155077e139d26d985f06815b3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a354c5d8155077e139d26d985f06815b3">◆ </a></span>GetSpaceWidth()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">decimal Font.GetSpaceWidth </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the width of the space character. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns a decimal value. </dd></dl>
</div>
</div>
<a id="aa0fd78cca931d349a9e096e6438dd9cf" name="aa0fd78cca931d349a9e096e6438dd9cf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa0fd78cca931d349a9e096e6438dd9cf">◆ </a></span>HasGlyph()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">boolean Font.HasGlyph </td>
<td>(</td>
<td class="paramtype">integer</td> <td class="paramname"><span class="paramname"><em>codepoint</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks if the font has a glyph for the given code point. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">codepoint</td><td>An Unicode code point. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns whether there is a glyph for the given code point. </dd></dl>
</div>
</div>
<a id="a12b12a0e0ae33cd2eff9faefec2e5ad4" name="a12b12a0e0ae33cd2eff9faefec2e5ad4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a12b12a0e0ae33cd2eff9faefec2e5ad4">◆ </a></span>IsAntialiasingEnabled()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">boolean Font.IsAntialiasingEnabled </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets whether the font has anti-aliasing enabled. </p>
<dl class="section return"><dt>Returns</dt><dd>Returns whether anti-aliasing is enabled. </dd></dl>
</div>
</div>
<a id="a3a6fefd5c106fdb6cd5bee848e260d55" name="a3a6fefd5c106fdb6cd5bee848e260d55"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3a6fefd5c106fdb6cd5bee848e260d55">◆ </a></span>SetAntialiasing()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetAntialiasing </td>
<td>(</td>
<td class="paramtype">boolean</td> <td class="paramname"><span class="paramname"><em>useAntialiasing</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Enables or disables anti-aliasing on the font. If disabling, you may want to increase the pixel coverage value with <a class="el" href="#ae93b28b362ea1410b4737509fc06d076" title="Font.SetPixelCoverageThreshold">Font.SetPixelCoverageThreshold</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">useAntialiasing</td><td>Whether or not to use anti-aliasing. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a7270c4931e39b313bcf8d5c2b8b9f0c1" name="a7270c4931e39b313bcf8d5c2b8b9f0c1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7270c4931e39b313bcf8d5c2b8b9f0c1">◆ </a></span>SetAscent()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetAscent </td>
<td>(</td>
<td class="paramtype">number</td> <td class="paramname"><span class="paramname"><em>ascent</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the distance in pixels above the baseline. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">ascent</td><td>The distance. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="ababe93507a4ab8d3e327a8cfb586d8ef" name="ababe93507a4ab8d3e327a8cfb586d8ef"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ababe93507a4ab8d3e327a8cfb586d8ef">◆ </a></span>SetDescent()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetDescent </td>
<td>(</td>
<td class="paramtype">number</td> <td class="paramname"><span class="paramname"><em>descent</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the distance in pixels below the baseline. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">descent</td><td>The distance. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a78e5d218ef68ccc22a0a232041ec8c05" name="a78e5d218ef68ccc22a0a232041ec8c05"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a78e5d218ef68ccc22a0a232041ec8c05">◆ </a></span>SetLeading()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetLeading </td>
<td>(</td>
<td class="paramtype">number</td> <td class="paramname"><span class="paramname"><em>leading</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the distance between lines in pixels. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">leading</td><td>The distance. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="ae312c2aa71e4b48f016cfc45c8b96b14" name="ae312c2aa71e4b48f016cfc45c8b96b14"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae312c2aa71e4b48f016cfc45c8b96b14">◆ </a></span>SetOversampling()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetOversampling </td>
<td>(</td>
<td class="paramtype">integer</td> <td class="paramname"><span class="paramname"><em>oversampling</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the oversampling value. Higher values increase font quality. Changing this value causes all font glyphs to be reloaded. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">oversampling</td><td>The oversampling value. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="ae93b28b362ea1410b4737509fc06d076" name="ae93b28b362ea1410b4737509fc06d076"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae93b28b362ea1410b4737509fc06d076">◆ </a></span>SetPixelCoverageThreshold()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetPixelCoverageThreshold </td>
<td>(</td>
<td class="paramtype">decimal</td> <td class="paramname"><span class="paramname"><em>threshold</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the pixel coverage threshold value. Pixels with coverage under this value become fully transparent, and pixels with coverage equal to or above this value become fully opaque. This only has an effect on fonts with anti-aliasing disabled. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">threshold</td><td>The threshold value, from <span class="tt">0.0</span> to <span class="tt">1.0</span>. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="abfa8e7ef09eb02938ff0982471ca4444" name="abfa8e7ef09eb02938ff0982471ca4444"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abfa8e7ef09eb02938ff0982471ca4444">◆ </a></span>SetPixelsPerUnit()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetPixelsPerUnit </td>
<td>(</td>
<td class="paramtype">number</td> <td class="paramname"><span class="paramname"><em>pixelsPerUnit</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the pixels per unit value of the font. Higher values improve the clarity, at the cost of increased memory usage. Note that this causes all glyphs to be reloaded, so this should usually only be called once. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">pixelsPerUnit</td><td>The pixels per unit value. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a6c9fef7690d9cca1201ab680dddc5326" name="a6c9fef7690d9cca1201ab680dddc5326"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6c9fef7690d9cca1201ab680dddc5326">◆ </a></span>SetSpaceWidth()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Font.SetSpaceWidth </td>
<td>(</td>
<td class="paramtype">number</td> <td class="paramname"><span class="paramname"><em>spaceWidth</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the width of the space character. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">spaceWidth</td><td>The width. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<div id="page-nav" class="page-nav-panel">
<div id="page-nav-resize-handle"></div>
<div id="page-nav-tree">
<div id="page-nav-contents">
</div><!-- page-nav-contents -->
</div><!-- page-nav-tree -->
</div><!-- page-nav -->
</div><!-- container -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="navelem"><a href="classFont.html">Font</a></li>
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.16.0 </li>
</ul>
</div>
</body>
</html>