| @@ -7,7 +7,7 @@ | |||
| #' | |||
| #' Creates \pkg{ggplot2} themes to match the xaringanthemer theme used in the | |||
| #' \pkg{xaringan} slides that seamlessly matches the "normal" slide colors and | |||
| #' styles. | |||
| #' styles. See `vignette("ggplot2-themes")` for more information and examples. | |||
| #' | |||
| #' @param text_color Color for text and foreground, inherits from `text_color` | |||
| #' @param background_color Color for background, inherits from | |||
| @@ -99,7 +99,8 @@ theme_xaringan <- function( | |||
| #' **Lifecycle:** [Maturing](https://www.tidyverse.org/lifecycle/#maturing) | |||
| #' | |||
| #' A \pkg{ggplot2} xaringanthemer plot theme to seamlessly match the "inverse" | |||
| #' \pkg{xaringan} slide colors and styles as styled by [xaringanthemer]. | |||
| #' \pkg{xaringan} slide colors and styles as styled by [xaringanthemer]. See | |||
| #' `vignette("ggplot2-themes")` for more information and examples. | |||
| #' | |||
| #' @param text_color Color for text and foreground, inherits from `text_color` | |||
| #' @param background_color Color for background, inherits from | |||
| @@ -186,13 +187,14 @@ theme_xaringan_inverse <- function( | |||
| #' | |||
| #' **Lifecycle:** [Maturing](https://www.tidyverse.org/lifecycle/#maturing) | |||
| #' | |||
| #' Provides a base plot theme for \pkg{ggplot2} to match the \pkg{xaringan} slide theme | |||
| #' created by [xaringanthemer]. The theme is designed to create a general plot | |||
| #' style from two colors, a `background_color` and a `text_color` (or foreground | |||
| #' color). Also accepts an `accent_color` and an `accent_secondary_color` that are | |||
| #' [xaringanthemer] is not required for the base theme. Use | |||
| #' [theme_xaringan()] or [theme_xaringan_inverse()] in xaringan slides styled by | |||
| #' xaringanthemer for a plot theme that matches the slide style. | |||
| #' Provides a base plot theme for \pkg{ggplot2} to match the \pkg{xaringan} | |||
| #' slide theme created by [xaringanthemer]. The theme is designed to create a | |||
| #' general plot style from two colors, a `background_color` and a `text_color` | |||
| #' (or foreground color). Also accepts an `accent_color` and an | |||
| #' `accent_secondary_color` that are [xaringanthemer] is not required for the | |||
| #' base theme. Use [theme_xaringan()] or [theme_xaringan_inverse()] in xaringan | |||
| #' slides styled by xaringanthemer for a plot theme that matches the slide | |||
| #' style. See `vignette("ggplot2-themes")` for more information and examples. | |||
| #' | |||
| #' @param text_color Color for text and foreground | |||
| #' @param background_color Color for background | |||
| @@ -512,7 +514,9 @@ safely_set_geom <- function(geom, new) { | |||
| #' **Lifecycle:** [Maturing](https://www.tidyverse.org/lifecycle/#maturing) | |||
| #' | |||
| #' Color and fill single-color scales for discrete and continuous values, | |||
| #' created using the primary accent color of the xaringanthemer styles. | |||
| #' created using the primary accent color of the xaringanthemer styles. See | |||
| #' `vignette("ggplot2-themes")` for more information and examples of | |||
| #' \pkg{xaringanthemer}'s \pkg{ggplot2}-related functions. | |||
| #' | |||
| #' @param ... Arguments passed on to either the \pkg{colorspace} scale | |||
| #' functions — one of [colorspace::scale_color_discrete_sequential()], | |||
| @@ -78,6 +78,8 @@ Color and fill scales are also provided for matching sequential color | |||
| scales based on the primary color used in your slides. See | |||
| `?scale_xaringan` for more details. | |||
| More details and examples can be found in `vignette("ggplot2-themes")`. | |||
| ``` r | |||
| library(ggplot2) | |||
| ggplot(diamonds) + | |||
| @@ -43,6 +43,8 @@ for matching sequential color scales based on | |||
| the primary color used in your slides. | |||
| See `?scale_xaringan` for more details. | |||
| More details and examples can be found in `vignette("ggplot2-themes")`. | |||
| ```{r xaringanthemer-ggplot-setup, include=FALSE, eval=IS_README} | |||
| style_mono_accent( | |||
| base_color = "#1c5253", | |||
| @@ -99,7 +99,9 @@ value of \code{inverse_header_color}} | |||
| \strong{Lifecycle:} \href{https://www.tidyverse.org/lifecycle/#maturing}{Maturing} | |||
| Color and fill single-color scales for discrete and continuous values, | |||
| created using the primary accent color of the xaringanthemer styles. | |||
| created using the primary accent color of the xaringanthemer styles. See | |||
| \code{vignette("ggplot2-themes")} for more information and examples of | |||
| \pkg{xaringanthemer}'s \pkg{ggplot2}-related functions. | |||
| } | |||
| \examples{ | |||
| # Requires ggplot2 | |||
| @@ -76,7 +76,7 @@ A ggplot2 theme | |||
| Creates \pkg{ggplot2} themes to match the xaringanthemer theme used in the | |||
| \pkg{xaringan} slides that seamlessly matches the "normal" slide colors and | |||
| styles. | |||
| styles. See \code{vignette("ggplot2-themes")} for more information and examples. | |||
| } | |||
| \examples{ | |||
| # Requires ggplot2 | |||
| @@ -71,13 +71,14 @@ A ggplot2 theme | |||
| \description{ | |||
| \strong{Lifecycle:} \href{https://www.tidyverse.org/lifecycle/#maturing}{Maturing} | |||
| Provides a base plot theme for \pkg{ggplot2} to match the \pkg{xaringan} slide theme | |||
| created by \link{xaringanthemer}. The theme is designed to create a general plot | |||
| style from two colors, a \code{background_color} and a \code{text_color} (or foreground | |||
| color). Also accepts an \code{accent_color} and an \code{accent_secondary_color} that are | |||
| \link{xaringanthemer} is not required for the base theme. Use | |||
| \code{\link[=theme_xaringan]{theme_xaringan()}} or \code{\link[=theme_xaringan_inverse]{theme_xaringan_inverse()}} in xaringan slides styled by | |||
| xaringanthemer for a plot theme that matches the slide style. | |||
| Provides a base plot theme for \pkg{ggplot2} to match the \pkg{xaringan} | |||
| slide theme created by \link{xaringanthemer}. The theme is designed to create a | |||
| general plot style from two colors, a \code{background_color} and a \code{text_color} | |||
| (or foreground color). Also accepts an \code{accent_color} and an | |||
| \code{accent_secondary_color} that are \link{xaringanthemer} is not required for the | |||
| base theme. Use \code{\link[=theme_xaringan]{theme_xaringan()}} or \code{\link[=theme_xaringan_inverse]{theme_xaringan_inverse()}} in xaringan | |||
| slides styled by xaringanthemer for a plot theme that matches the slide | |||
| style. See \code{vignette("ggplot2-themes")} for more information and examples. | |||
| } | |||
| \examples{ | |||
| # Requires ggplot2 | |||
| @@ -75,7 +75,8 @@ A ggplot2 theme | |||
| \strong{Lifecycle:} \href{https://www.tidyverse.org/lifecycle/#maturing}{Maturing} | |||
| A \pkg{ggplot2} xaringanthemer plot theme to seamlessly match the "inverse" | |||
| \pkg{xaringan} slide colors and styles as styled by \link{xaringanthemer}. | |||
| \pkg{xaringan} slide colors and styles as styled by \link{xaringanthemer}. See | |||
| \code{vignette("ggplot2-themes")} for more information and examples. | |||
| } | |||
| \examples{ | |||
| # Requires ggplot2 | |||