소스 검색

Link to ggplot2-themes vignette in various places

tags/v0.3.0
Garrick Aden-Buie 6 년 전
부모
커밋
d1d3042906
7개의 변경된 파일32개의 추가작업 그리고 20개의 파일을 삭제
  1. +14
    -10
      R/ggplot2.R
  2. +2
    -0
      index.md
  3. +2
    -0
      man/fragments/_quick-intro.Rmd
  4. +3
    -1
      man/scale_xaringan.Rd
  5. +1
    -1
      man/theme_xaringan.Rd
  6. +8
    -7
      man/theme_xaringan_base.Rd
  7. +2
    -1
      man/theme_xaringan_inverse.Rd

+ 14
- 10
R/ggplot2.R 파일 보기

@@ -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()],

+ 2
- 0
index.md 파일 보기

@@ -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) +

+ 2
- 0
man/fragments/_quick-intro.Rmd 파일 보기

@@ -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",

+ 3
- 1
man/scale_xaringan.Rd 파일 보기

@@ -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

+ 1
- 1
man/theme_xaringan.Rd 파일 보기

@@ -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

+ 8
- 7
man/theme_xaringan_base.Rd 파일 보기

@@ -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

+ 2
- 1
man/theme_xaringan_inverse.Rd 파일 보기

@@ -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

Loading…
취소
저장