complete_theme: Complete a theme

View source: R/theme.R

complete_themeR Documentation

Complete a theme

Description

This function takes a theme and completes it so that it can be used downstream to render theme elements. Missing elements are filled in and every item is validated to the specifications of the element tree.

Usage

complete_theme(theme = NULL, default = theme_get())

Arguments

theme

An incomplete theme object to complete, or NULL to complete the default theme.

default

A complete theme to fill in missing pieces. Defaults to the global theme settings.

Value

A theme object.

Examples

my_theme <- theme(line = element_line(colour = "red"))
complete_theme(my_theme)

tidyverse/ggplot2 documentation built on July 1, 2024, 6:44 a.m.