value : String -> AFrame.Properties.Property
The actual content of the text. Line breaks and tabs are supported with \n
and \t
.
Default : ''
font : AFrame.Variants.Text.Font.Font -> AFrame.Properties.Property
Font to render text, either the name of one of A-Frame’s stock fonts or a URL to a font file.
Default : default
fontImage : String -> AFrame.Properties.Property
Font image texture path to render text. Defaults to the font‘s name with extension replaced to .png. Don’t need to specify if using a stock font.
Default : derived from font name
color : Color -> AFrame.Properties.Property
Text color.
Default : white
opacity : Basics.Float -> AFrame.Properties.Property
Opacity, on a scale from 0 to 1, where 0 means fully transparent and 1 means fully opaque.
Default : 1.0
transparent : Basics.Bool -> AFrame.Properties.Property
Whether text is transparent.
Default : true
shader : String -> AFrame.Properties.Property
Shader used to render text.
Default : sdf
npot : Basics.Bool -> AFrame.Properties.Property
Use settings for non-power-of-two (NPOT) texture.
Default : false
side : AFrame.Variants.Side.Side -> AFrame.Properties.Property
Side to render. (front
, back
, double
)
Default : front
dithering : Basics.Bool -> AFrame.Properties.Property
Whether material is dithered with noise. Removes banding from gradients like ones produced by lighting.
Default : true
flatShading : Basics.Bool -> AFrame.Properties.Property
Use THREE.FlatShading
rather than THREE.StandardShading
.
Default : false
width : Basics.Float -> AFrame.Properties.Property
Width in meters.
Default : derived from geometry if exists
height : Basics.Float -> AFrame.Properties.Property
Height of text block.
Default : derived from text size
align : AFrame.Variants.Text.Align.Align -> AFrame.Properties.Property
Multi-line text alignment (left
, center
, right
).
Default : left
anchor : AFrame.Variants.Text.Anchor.Anchor -> AFrame.Properties.Property
Horizontal positioning (left
, center
, right
, align
).
Default : center
baseline : AFrame.Variants.Text.Baseline.Baseline -> AFrame.Properties.Property
Vertical positioning (top
, center
, bottom
).
Default : center
lineHeight : Basics.Float -> AFrame.Properties.Property
Line height in pixels.
Default : derived from font file
whiteSpace : AFrame.Variants.Text.WhiteSpace.WhiteSpace -> AFrame.Properties.Property
How whitespace should be handled (i.e., normal
, pre
, nowrap
).
Default : normal
wrapCount : Basics.Int -> AFrame.Properties.Property
Number of characters before wrapping text (more or less).
Default : 40
wrapPixels : Basics.Int -> AFrame.Properties.Property
Number of pixels before wrapping text.
Default : derived from wrapCount
letterSpacing : Basics.Float -> AFrame.Properties.Property
Letter spacing in pixels.
Default : 0
tabSize : Basics.Int -> AFrame.Properties.Property
Tab size in spaces.
Default : 4
offset : Basics.Float -> Basics.Float -> AFrame.Properties.Property
Texture offset to be used.
Default : {x: 0, y: 0}
xOffset : Basics.Float -> AFrame.Properties.Property
X-offset to apply to add padding.
Default : 0
zOffset : Basics.Float -> AFrame.Properties.Property
Z-offset to apply to avoid Z-fighting if using with a geometry as a background.
Default : 0.001
repeat : Basics.Float -> Basics.Float -> AFrame.Properties.Property
Texture repeat to be used.
Default : {x: 1, y: 1}
alphaTest : Basics.Float -> AFrame.Properties.Property
Discard text pixels if alpha is less than this value.
Default : 0
depthTest : Basics.Bool -> AFrame.Properties.Property
Whether depth testing is enabled when rendering the material.
Default : true
visible : Basics.Bool -> AFrame.Properties.Property
Whether material is visible. Raycasters will ignore invisible materials.
Default : true