Header menu logo Nao

TextStyle Type

Character-level styling for a run of text. Every field is optional so a run can inherit from its context and writers only emit what is explicitly set.

Record fields

Record Field Description

Background

Full Usage: Background

Field type: Color option
Field type: Color option

Color

Full Usage: Color

Field type: Color option
Field type: Color option

Decorations

Full Usage: Decorations

Field type: TextDecoration list
Field type: TextDecoration list

Features

Full Usage: Features

Field type: Map<string, string>

Extensible bag for things the model doesn't name (OpenType features, super/subscript, letter-spacing, ...).

Field type: Map<string, string>

FontFamily

Full Usage: FontFamily

Field type: string option
Field type: string option

FontSize

Full Usage: FontSize

Field type: Length option
Field type: Length option

Style

Full Usage: Style

Field type: FontStyleKind option
Field type: FontStyleKind option

Weight

Full Usage: Weight

Field type: FontWeight option
Field type: FontWeight option

Static members

Static member Description

TextStyle.Bold

Full Usage: TextStyle.Bold

Returns: TextStyle
Returns: TextStyle

TextStyle.Default

Full Usage: TextStyle.Default

Returns: TextStyle

An empty style — inherit everything from context.

Returns: TextStyle

TextStyle.Italic

Full Usage: TextStyle.Italic

Returns: TextStyle
Returns: TextStyle

Type something to start searching.