Skip to content

Commit 70a094e

Browse files
carywreamsyutannihilation
authored andcommitted
address duplicate aesthetic listings in documentation, re #3618 (#3657)
1 parent 48660e1 commit 70a094e

File tree

6 files changed

+4
-29
lines changed

6 files changed

+4
-29
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,6 +253,6 @@ Collate:
253253
'zxx.r'
254254
'zzz.r'
255255
VignetteBuilder: knitr
256-
RoxygenNote: 7.0.1
256+
RoxygenNote: 7.0.2
257257
Roxygen: list(markdown = TRUE)
258258
Encoding: UTF-8

R/utilities-help.r

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
rd_aesthetics <- function(type, name) {
32
obj <- switch(type,
43
geom = check_subclass(name, "Geom", env = globalenv()),
@@ -22,7 +21,9 @@ rd_aesthetics <- function(type, name) {
2221
rd_aesthetics_item <- function(x) {
2322
req <- x$required_aes
2423
req <- sub("|", "} \\emph{or} \\code{", req, fixed = TRUE)
25-
all <- union(req, sort(x$aesthetics()))
24+
req_aes <- unlist(strsplit(x$required_aes, "|", fixed = TRUE))
25+
optional_aes <- setdiff(x$aesthetics(), req_aes)
26+
all <- union(req, sort(optional_aes))
2627

2728
ifelse(all %in% req,
2829
paste0("\\strong{\\code{", all, "}}"),

man/geom_bar.Rd

Lines changed: 0 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/geom_boxplot.Rd

Lines changed: 0 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/geom_linerange.Rd

Lines changed: 0 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/geom_ribbon.Rd

Lines changed: 0 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)