Skip to content

Commit 379597d

Browse files
authored
Adds support of rlang::list2 dynamic dots (#4764)
Fixes #4752
1 parent 00b762d commit 379597d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+84
-82
lines changed

NEWS.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# ggplot2 (development version)
22

3+
* `...` supports `rlang::list2` dynamic dots in all public functions. (@mone27, #4764)
4+
35
* `theme()` now has a `strip.clip` argument, that can be set to `"off"` to
46
prevent the clipping of strip text and background borders (@teunbrand, #4118)
57

R/geom-abline.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ geom_abline <- function(mapping = NULL, data = NULL,
112112
position = PositionIdentity,
113113
show.legend = show.legend,
114114
inherit.aes = FALSE,
115-
params = list(
115+
params = list2(
116116
na.rm = na.rm,
117117
...
118118
)

R/geom-bar.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ geom_bar <- function(mapping = NULL, data = NULL,
9696
position = position,
9797
show.legend = show.legend,
9898
inherit.aes = inherit.aes,
99-
params = list(
99+
params = list2(
100100
width = width,
101101
na.rm = na.rm,
102102
orientation = orientation,

R/geom-bin2d.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ geom_bin_2d <- function(mapping = NULL, data = NULL,
3939
position = position,
4040
show.legend = show.legend,
4141
inherit.aes = inherit.aes,
42-
params = list(
42+
params = list2(
4343
na.rm = na.rm,
4444
...
4545
)

R/geom-blank.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ geom_blank <- function(mapping = NULL, data = NULL,
2323
position = position,
2424
show.legend = show.legend,
2525
inherit.aes = inherit.aes,
26-
params = list(...),
26+
params = list2(...),
2727
check.aes = FALSE
2828
)
2929
}

R/geom-boxplot.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ geom_boxplot <- function(mapping = NULL, data = NULL,
141141
position = position,
142142
show.legend = show.legend,
143143
inherit.aes = inherit.aes,
144-
params = list(
144+
params = list2(
145145
outlier.colour = outlier.color %||% outlier.colour,
146146
outlier.fill = outlier.fill,
147147
outlier.shape = outlier.shape,

R/geom-col.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ geom_col <- function(mapping = NULL, data = NULL,
1616
position = position,
1717
show.legend = show.legend,
1818
inherit.aes = inherit.aes,
19-
params = list(
19+
params = list2(
2020
width = width,
2121
na.rm = na.rm,
2222
...

R/geom-contour.r

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ geom_contour <- function(mapping = NULL, data = NULL,
9393
position = position,
9494
show.legend = show.legend,
9595
inherit.aes = inherit.aes,
96-
params = list(
96+
params = list2(
9797
bins = bins,
9898
binwidth = binwidth,
9999
breaks = breaks,
@@ -125,7 +125,7 @@ geom_contour_filled <- function(mapping = NULL, data = NULL,
125125
position = position,
126126
show.legend = show.legend,
127127
inherit.aes = inherit.aes,
128-
params = list(
128+
params = list2(
129129
bins = bins,
130130
binwidth = binwidth,
131131
breaks = breaks,

R/geom-count.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ geom_count <- function(mapping = NULL, data = NULL,
5555
position = position,
5656
show.legend = show.legend,
5757
inherit.aes = inherit.aes,
58-
params = list(
58+
params = list2(
5959
na.rm = na.rm,
6060
...
6161
)

R/geom-crossbar.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ geom_crossbar <- function(mapping = NULL, data = NULL,
1616
position = position,
1717
show.legend = show.legend,
1818
inherit.aes = inherit.aes,
19-
params = list(
19+
params = list2(
2020
fatten = fatten,
2121
na.rm = na.rm,
2222
orientation = orientation,

R/geom-curve.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ geom_curve <- function(mapping = NULL, data = NULL,
2121
position = position,
2222
show.legend = show.legend,
2323
inherit.aes = inherit.aes,
24-
params = list(
24+
params = list2(
2525
arrow = arrow,
2626
arrow.fill = arrow.fill,
2727
curvature = curvature,

R/geom-density.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ geom_density <- function(mapping = NULL, data = NULL,
6969
position = position,
7070
show.legend = show.legend,
7171
inherit.aes = inherit.aes,
72-
params = list(
72+
params = list2(
7373
na.rm = na.rm,
7474
orientation = orientation,
7575
outline.type = outline.type,

R/geom-density2d.r

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ geom_density_2d <- function(mapping = NULL, data = NULL,
8181
position = position,
8282
show.legend = show.legend,
8383
inherit.aes = inherit.aes,
84-
params = list(
84+
params = list2(
8585
lineend = lineend,
8686
linejoin = linejoin,
8787
linemitre = linemitre,
@@ -124,7 +124,7 @@ geom_density_2d_filled <- function(mapping = NULL, data = NULL,
124124
position = position,
125125
show.legend = show.legend,
126126
inherit.aes = inherit.aes,
127-
params = list(
127+
params = list2(
128128
na.rm = na.rm,
129129
contour = TRUE,
130130
contour_var = contour_var,

R/geom-dotplot.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ geom_dotplot <- function(mapping = NULL, data = NULL,
159159
show.legend = show.legend,
160160
inherit.aes = inherit.aes,
161161
# Need to make sure that the binaxis goes to both the stat and the geom
162-
params = list(
162+
params = list2(
163163
binaxis = binaxis,
164164
binwidth = binwidth,
165165
binpositions = binpositions,

R/geom-errorbar.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ geom_errorbar <- function(mapping = NULL, data = NULL,
1515
position = position,
1616
show.legend = show.legend,
1717
inherit.aes = inherit.aes,
18-
params = list(
18+
params = list2(
1919
na.rm = na.rm,
2020
orientation = orientation,
2121
...

R/geom-errorbarh.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ geom_errorbarh <- function(mapping = NULL, data = NULL,
3838
position = position,
3939
show.legend = show.legend,
4040
inherit.aes = inherit.aes,
41-
params = list(
41+
params = list2(
4242
na.rm = na.rm,
4343
...
4444
)

R/geom-freqpoly.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ geom_freqpoly <- function(mapping = NULL, data = NULL,
77
show.legend = NA,
88
inherit.aes = TRUE) {
99

10-
params <- list(na.rm = na.rm, ...)
10+
params <- list2(na.rm = na.rm, ...)
1111
if (identical(stat, "bin")) {
1212
params$pad <- TRUE
1313
}

R/geom-function.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ geom_function <- function(mapping = NULL, data = NULL, stat = "function",
6767
position = position,
6868
show.legend = show.legend,
6969
inherit.aes = inherit.aes,
70-
params = list(
70+
params = list2(
7171
na.rm = na.rm,
7272
...
7373
)

R/geom-hex.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ geom_hex <- function(mapping = NULL, data = NULL,
4141
position = position,
4242
show.legend = show.legend,
4343
inherit.aes = inherit.aes,
44-
params = list(
44+
params = list2(
4545
na.rm = na.rm,
4646
...
4747
)

R/geom-histogram.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ geom_histogram <- function(mapping = NULL, data = NULL,
131131
position = position,
132132
show.legend = show.legend,
133133
inherit.aes = inherit.aes,
134-
params = list(
134+
params = list2(
135135
binwidth = binwidth,
136136
bins = bins,
137137
na.rm = na.rm,

R/geom-hline.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ geom_hline <- function(mapping = NULL, data = NULL,
3232
position = PositionIdentity,
3333
show.legend = show.legend,
3434
inherit.aes = FALSE,
35-
params = list(
35+
params = list2(
3636
na.rm = na.rm,
3737
...
3838
)

R/geom-jitter.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ geom_jitter <- function(mapping = NULL, data = NULL,
5757
position = position,
5858
show.legend = show.legend,
5959
inherit.aes = inherit.aes,
60-
params = list(
60+
params = list2(
6161
na.rm = na.rm,
6262
...
6363
)

R/geom-label.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ geom_label <- function(mapping = NULL, data = NULL,
3131
position = position,
3232
show.legend = show.legend,
3333
inherit.aes = inherit.aes,
34-
params = list(
34+
params = list2(
3535
parse = parse,
3636
label.padding = label.padding,
3737
label.r = label.r,

R/geom-linerange.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ geom_linerange <- function(mapping = NULL, data = NULL,
7878
position = position,
7979
show.legend = show.legend,
8080
inherit.aes = inherit.aes,
81-
params = list(
81+
params = list2(
8282
na.rm = na.rm,
8383
orientation = orientation,
8484
...

R/geom-map.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ geom_map <- function(mapping = NULL, data = NULL,
9292
position = PositionIdentity,
9393
show.legend = show.legend,
9494
inherit.aes = inherit.aes,
95-
params = list(
95+
params = list2(
9696
map = map,
9797
na.rm = na.rm,
9898
...

R/geom-path.r

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ geom_path <- function(mapping = NULL, data = NULL,
112112
position = position,
113113
show.legend = show.legend,
114114
inherit.aes = inherit.aes,
115-
params = list(
115+
params = list2(
116116
lineend = lineend,
117117
linejoin = linejoin,
118118
linemitre = linemitre,
@@ -248,7 +248,7 @@ geom_line <- function(mapping = NULL, data = NULL, stat = "identity",
248248
position = position,
249249
show.legend = show.legend,
250250
inherit.aes = inherit.aes,
251-
params = list(
251+
params = list2(
252252
na.rm = na.rm,
253253
orientation = orientation,
254254
...
@@ -293,7 +293,7 @@ geom_step <- function(mapping = NULL, data = NULL, stat = "identity",
293293
position = position,
294294
show.legend = show.legend,
295295
inherit.aes = inherit.aes,
296-
params = list(
296+
params = list2(
297297
direction = direction,
298298
na.rm = na.rm,
299299
...

R/geom-point.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ geom_point <- function(mapping = NULL, data = NULL,
9797
position = position,
9898
show.legend = show.legend,
9999
inherit.aes = inherit.aes,
100-
params = list(
100+
params = list2(
101101
na.rm = na.rm,
102102
...
103103
)

R/geom-pointrange.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ geom_pointrange <- function(mapping = NULL, data = NULL,
1616
position = position,
1717
show.legend = show.legend,
1818
inherit.aes = inherit.aes,
19-
params = list(
19+
params = list2(
2020
fatten = fatten,
2121
na.rm = na.rm,
2222
orientation = orientation,

R/geom-polygon.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ geom_polygon <- function(mapping = NULL, data = NULL,
9393
position = position,
9494
show.legend = show.legend,
9595
inherit.aes = inherit.aes,
96-
params = list(
96+
params = list2(
9797
na.rm = na.rm,
9898
rule = rule,
9999
...

R/geom-quantile.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ geom_quantile <- function(mapping = NULL, data = NULL,
4747
position = position,
4848
show.legend = show.legend,
4949
inherit.aes = inherit.aes,
50-
params = list(
50+
params = list2(
5151
lineend = lineend,
5252
linejoin = linejoin,
5353
linemitre = linemitre,

R/geom-raster.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ geom_raster <- function(mapping = NULL, data = NULL,
2929
position = position,
3030
show.legend = show.legend,
3131
inherit.aes = inherit.aes,
32-
params = list(
32+
params = list2(
3333
hjust = hjust,
3434
vjust = vjust,
3535
interpolate = interpolate,

R/geom-rect.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ geom_rect <- function(mapping = NULL, data = NULL,
1515
position = position,
1616
show.legend = show.legend,
1717
inherit.aes = inherit.aes,
18-
params = list(
18+
params = list2(
1919
linejoin = linejoin,
2020
na.rm = na.rm,
2121
...

R/geom-ribbon.r

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ geom_ribbon <- function(mapping = NULL, data = NULL,
5959
position = position,
6060
show.legend = show.legend,
6161
inherit.aes = inherit.aes,
62-
params = list(
62+
params = list2(
6363
na.rm = na.rm,
6464
orientation = orientation,
6565
outline.type = outline.type,
@@ -214,7 +214,7 @@ geom_area <- function(mapping = NULL, data = NULL, stat = "identity",
214214
position = position,
215215
show.legend = show.legend,
216216
inherit.aes = inherit.aes,
217-
params = list(
217+
params = list2(
218218
na.rm = na.rm,
219219
orientation = orientation,
220220
outline.type = outline.type,

R/geom-rug.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ geom_rug <- function(mapping = NULL, data = NULL,
7070
position = position,
7171
show.legend = show.legend,
7272
inherit.aes = inherit.aes,
73-
params = list(
73+
params = list2(
7474
outside = outside,
7575
sides = sides,
7676
length = length,

R/geom-segment.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ geom_segment <- function(mapping = NULL, data = NULL,
8585
position = position,
8686
show.legend = show.legend,
8787
inherit.aes = inherit.aes,
88-
params = list(
88+
params = list2(
8989
arrow = arrow,
9090
arrow.fill = arrow.fill,
9191
lineend = lineend,

R/geom-sf.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ geom_sf <- function(mapping = aes(), data = NULL, stat = "sf",
230230
position = position,
231231
show.legend = show.legend,
232232
inherit.aes = inherit.aes,
233-
params = list(
233+
params = list2(
234234
na.rm = na.rm,
235235
...
236236
)
@@ -273,7 +273,7 @@ geom_sf_label <- function(mapping = aes(), data = NULL,
273273
position = position,
274274
show.legend = show.legend,
275275
inherit.aes = inherit.aes,
276-
params = list(
276+
params = list2(
277277
parse = parse,
278278
label.padding = label.padding,
279279
label.r = label.r,
@@ -317,7 +317,7 @@ geom_sf_text <- function(mapping = aes(), data = NULL,
317317
position = position,
318318
show.legend = show.legend,
319319
inherit.aes = inherit.aes,
320-
params = list(
320+
params = list2(
321321
parse = parse,
322322
check_overlap = check_overlap,
323323
na.rm = na.rm,

R/geom-smooth.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ geom_smooth <- function(mapping = NULL, data = NULL,
9393
show.legend = NA,
9494
inherit.aes = TRUE) {
9595

96-
params <- list(
96+
params <- list2(
9797
na.rm = na.rm,
9898
orientation = orientation,
9999
se = se,

0 commit comments

Comments
 (0)