#
| source:
src/drawable/instance.Text.js, line 7
Members and methods attached to the
rac.Text
function.
The function contains ready-made convenience
Text
objects for usual values, all setup with the
owning Rac
instance.
Example
let rac = new Rac()
rac.Text.hello // ready-made hello-world text
rac.Text.hello.rac === rac // true
Namespaces
Members
hello :Rac.Text
#
| source:
src/drawable/instance.Text.js, line 125
A Text
for drawing hello world
with topLeft
format at
Point.zero
.
sphinx :Rac.Text
#
| source:
src/drawable/instance.Text.js, line 134
A Text
for drawing the pangram sphinx of black quartz, judge my vow
with topLeft
format at Point.zero
.
Methods
Format(hAlign, vAlign, angleopt, fontopt, sizeopt)
#
| source:
src/attachInstanceFunctions.js, line 373
Convenience function to create a new Text.Format
. Alias of
rac.TextFormat
.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
hAlign |
String
|
The horizontal alignment, left-to-right; one
of the values from |
||
vAlign |
String
|
The vertical alignment, top-to-bottom; one of
the values from |
||
angle |
Rac.Angle
|
<optional> |
rac.Angle.zero
|
The angle towards which the text is drawn |
font |
String
|
<optional> |
null
|
The font name |
size |
Number
|
<optional> |
null
|
The font size |