% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/theme.r
\name{theme_update}
\alias{theme_get}
\alias{theme_set}
\alias{theme_update}
\title{Get, set and update themes.}
\usage{
theme_update(...)

theme_get()

theme_set(new)
}
\arguments{
\item{...}{named list of theme settings}

\item{new}{new theme (a list of theme elements)}
}
\description{
Use \code{theme_update} to modify a small number of elements of the current
theme or use \code{theme_set} to completely override it.
}
\examples{
p <- ggplot(mtcars, aes(mpg, wt)) +
  geom_point()
p
old <- theme_set(theme_bw())
p
theme_set(old)
p

old <- theme_update(panel.background = element_rect(colour = "pink"))
p
theme_set(old)
theme_get()

ggplot(mtcars, aes(mpg, wt)) +
  geom_point(aes(color = mpg)) +
  theme(legend.position = c(0.95, 0.95),
        legend.justification = c(1, 1))
last_plot() +
 theme(legend.background = element_rect(fill = "white", colour = "white", size = 3))
}
\seealso{
\code{\link{\%+replace\%}} and \code{\link{+.gg}}
}

