r-lib / gtable

The layout packages that powers ggplot2
https://gtable.r-lib.org
Other
87 stars 18 forks source link

Can we have an `as.gtable()` generic? #97

Closed teunbrand closed 1 month ago

teunbrand commented 1 month ago

The idea is that it'd be inconvenient for several packages to declare their own conversion functions and instead could just write methods for an as.gtable() generic. Several instances of this are ggplot2::ggplotGrob()/ggplot2::ggplot_gtable() and gt::as_gtable().