theme-set

Set the global default theme for all subsequent plots.

Usage

theme-set(
  theme,
)

Parameters

Parameter Default Description
theme Theme dictionary from theme-grey, theme-minimal, theme-classic, theme-void, or theme.

Returns

None.

Examples

Set the project default once so every plot inherits it.

#theme-set(theme-minimal())
// All plots below use theme-minimal() by default.

Pin a custom theme as the project default.

#theme-set(theme(
  panel-background: element-rect(fill: rgb("#fff7e6")),
  panel-grid: element-line(colour: rgb("#d9cfbf")),
))

See also

theme-get, theme.

Back to top