Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions R/geom-.R
Original file line number Diff line number Diff line change
Expand Up @@ -126,9 +126,6 @@ Geom <- ggproto("Geom",
deprecate_soft0("3.4.0", I("Using the `size` aesthetic in this geom"), I("`linewidth` in the `default_aes` field and elsewhere"))
default_aes$linewidth <- default_aes$size
}
if (is_pattern(params$fill)) {
params$fill <- list(params$fill)
}

# Fill in missing aesthetics with their defaults
missing_aes <- setdiff(names(default_aes), names(data))
Expand Down
6 changes: 6 additions & 0 deletions R/layer.R
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,12 @@ layer <- function(geom = NULL, stat = NULL,

all <- c(geom$parameters(TRUE), stat$parameters(TRUE), geom$aesthetics())

# Take care of plain patterns provided as aesthetic
pattern <- vapply(aes_params, is_pattern, logical(1))
if (any(pattern)) {
aes_params[pattern] <- lapply(aes_params[pattern], list)
}

# Warn about extra params and aesthetics
extra_param <- setdiff(names(params), all)
# Take care of size->linewidth renaming in layer params
Expand Down