Skip to content

Commit ef603ea

Browse files
thomasp85hadley
authored andcommitted
Use 'top left' if plot.tag.position is NULL (#2603)
Fixes #2595
1 parent 13b7a78 commit ef603ea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

R/plot-build.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ ggplot_gtable.ggplot_built <- function(data) {
271271
plot_table <- gtable_add_rows(plot_table, unit(0, 'pt'), pos = -1)
272272
plot_table <- gtable_add_cols(plot_table, unit(0, 'pt'), pos = -1)
273273

274-
tag_pos <- theme$plot.tag.position
274+
tag_pos <- theme$plot.tag.position %||% "topleft"
275275
if (length(tag_pos) == 2) tag_pos <- "manual"
276276
valid_pos <- c("topleft", "top", "topright", "left", "right", "bottomleft",
277277
"bottom", "bottomright")

0 commit comments

Comments
 (0)