Skip to main content

Interface: TitleOptions

Defined in: mobjects/text/TextExtensions.ts:276

Options for creating a Title mobject

Properties

color?

optional color: string

Defined in: mobjects/text/TextExtensions.ts:286

Text color as CSS color string. Default: '#ffffff'


fillOpacity?

optional fillOpacity: number

Defined in: mobjects/text/TextExtensions.ts:288

Fill opacity from 0 to 1. Default: 1


fontFamily?

optional fontFamily: string

Defined in: mobjects/text/TextExtensions.ts:282

Font family. Default: 'sans-serif'


fontSize?

optional fontSize: number

Defined in: mobjects/text/TextExtensions.ts:280

Font size in pixels. Default: 72 (large)


fontWeight?

optional fontWeight: string | number

Defined in: mobjects/text/TextExtensions.ts:284

Font weight. Default: 'bold'


includeUnderline?

optional includeUnderline: boolean

Defined in: mobjects/text/TextExtensions.ts:290

Whether to include an underline. Default: false


text

text: string

Defined in: mobjects/text/TextExtensions.ts:278

The title text to display


underlineBuffer?

optional underlineBuffer: number

Defined in: mobjects/text/TextExtensions.ts:298

Space between text and underline in world units. Default: 0.15


underlineColor?

optional underlineColor: string

Defined in: mobjects/text/TextExtensions.ts:292

Underline color. Default: same as text color


underlineStrokeWidth?

optional underlineStrokeWidth: number

Defined in: mobjects/text/TextExtensions.ts:296

Underline stroke width. Default: 4


underlineWidth?

optional underlineWidth: number

Defined in: mobjects/text/TextExtensions.ts:294

Underline width in world units. Default: auto (match text width)


yPosition?

optional yPosition: number

Defined in: mobjects/text/TextExtensions.ts:300

Y position from top of frame. Default: 3.5 (near top of standard 8-unit frame)