lemon icon indicating copy to clipboard operation
lemon copied to clipboard

New grid version causes lemon_plot to fail

Open stefanedwards opened this issue 4 years ago • 0 comments

Paul Murrel wrote on 24. feb 2020:

Thomas Lin Pedersen and I have been working on a change to the internals of 'grid' ...

https://github.com/thomasp85/grid/tree/new-unit

... and those changes cause your package to fail R CMD check.

I have looked far enough to see that your package has (in ggplot_gtable.built_lemon()) code like this ...

do.call(grid::unit.pmax, c(widths, gtable$widths[gtable$layout$l[i]]))

... where the c() call is combining a list of units with a single unit. To be honest, I am not sure how this ever worked, but now at least that should be something like this ... ?

  do.call(grid::unit.pmax,
       c(widths,
         list(gtable$widths[gtable$layout$l[i]])))

(there are 3 other instances in ggplot_gtable.built_lemon())

stefanedwards avatar Apr 02 '20 12:04 stefanedwards