Skip to content

Commit

Permalink
Removed assignment to environment via <<-
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristinaSchmidt1 committed Oct 30, 2024
1 parent d74377c commit ff2a662
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions R/HelperPlots.R
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@ adjust_title <- function(gtbl, titles) {

#------- Width: Check how much width is needed for the figure title/subtitle
title_width <- titles %>% char2cm %>% max %>% cm
gtbl <<- gtbl

gtbl %<>% set_width(
c('guide-box-right', 'legend'),
sprintf('%.02fcm', title_width - gtbl$width),
Expand Down Expand Up @@ -378,7 +378,6 @@ adjust_legend <- function(
log_trace('Sections: %s', paste0(sections, collapse = ', '))

Legend <- get_legend(InputPlot) # Extract legend to adjust separately
leg <<- Legend

#------- Legend widths
## Legend titles:
Expand Down

0 comments on commit ff2a662

Please sign in to comment.