# Interface: CanvasFontSpec

# Hierarchy

# Properties

# family

family: string

Default font family for all text, follows CSS font-family options.

Default

"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif"

# Inherited from

FontSpec.family

# Defined in

types/index.d.ts:1776 (opens new window)


# lineHeight

lineHeight: string | number

Height of an individual line of text (see MDN).

Default

1.2

# Inherited from

FontSpec.lineHeight

# Defined in

types/index.d.ts:1795 (opens new window)


# size

size: number

Default font size (in px) for text. Does not apply to radialLinear scale point labels.

Default

12

# Inherited from

FontSpec.size

# Defined in

types/index.d.ts:1781 (opens new window)


# string

string: string

# Defined in

types/index.d.ts:1799 (opens new window)


# style

style: "normal" | "inherit" | "italic" | "oblique" | "initial"

Default font style. Does not apply to tooltip title or footer. Does not apply to chart title. Follows CSS font-style options (i.e. normal, italic, oblique, initial, inherit)

Default

'normal'

# Inherited from

FontSpec.style

# Defined in

types/index.d.ts:1786 (opens new window)


# weight

weight: number | "bold" | "normal" | "lighter" | "bolder"

Default font weight (boldness). (see MDN).

# Inherited from

FontSpec.weight

# Defined in

types/index.d.ts:1790 (opens new window)