Interface: StyledTextSegment
Defined in: mobjects/text/MarkupText.ts:47
A styled text segment produced by the Pango markup parser. Each segment is a leaf span of text sharing the same style.
Properties
backgroundColor
backgroundColor:
string
Defined in: mobjects/text/MarkupText.ts:61
Background color as CSS string (drawn as rect behind text)
baselineShift
baselineShift:
number
Defined in: mobjects/text/MarkupText.ts:67
Vertical offset factor for super/subscript. 0 = normal, negative = super, positive = sub
color
color:
string
Defined in: mobjects/text/MarkupText.ts:59
Foreground (fill) color as CSS string
fontFamily
fontFamily:
string
Defined in: mobjects/text/MarkupText.ts:51
CSS font-family
fontSize
fontSize:
number
Defined in: mobjects/text/MarkupText.ts:53
Font size in CSS pixels (before RESOLUTION_SCALE)
fontStyle
fontStyle:
string
Defined in: mobjects/text/MarkupText.ts:57
Font style: 'normal' | 'italic' | 'oblique'
fontVariant
fontVariant:
string
Defined in: mobjects/text/MarkupText.ts:71
CSS font-variant (e.g. 'small-caps')
fontWeight
fontWeight:
string|number
Defined in: mobjects/text/MarkupText.ts:55
Font weight: 'normal', 'bold', or numeric 100-900
relativeScale
relativeScale:
number
Defined in: mobjects/text/MarkupText.ts:69
Font size scale relative to parent (1 = same). Used for ///
strikethrough
strikethrough:
boolean
Defined in: mobjects/text/MarkupText.ts:65
Draw strikethrough decoration
text
text:
string
Defined in: mobjects/text/MarkupText.ts:49
The text content (no markup)
underline
underline:
boolean
Defined in: mobjects/text/MarkupText.ts:63
Draw underline decoration