wilkelab / cowplot

cowplot: Streamlined Plot Theme and Plot Annotations for ggplot2
https://wilkelab.org/cowplot/
701 stars 84 forks source link

plot_grid not preserving italic font #171

Open kevinVervier opened 3 years ago

kevinVervier commented 3 years ago

Good day,

I had created multi-figures ggpubr panels where the tick labels are in italic using options like font.label=c(9,"italic") However, when creating a plot_grid with them, the tick labels are no longer in italic.

 initial_grid <- plot_grid(pa,pd,pb,pe,pc,pf,
          labels=c('(a)','(b)','(c)','(d)','(e)','(f)'),ncol=2)

cow_G <- plot_grid(NULL, pg,
                    rel_heights = c(0.1, 1.85),
                    ncol = 1,
                    label_y = 1 + 0.07 /1.85,
                    labels = c("","(g)"))

all_cow <- plot_grid(initial_grid, cow_G,nrow = 2)

svg(filename = 'myplot.svg',width = 12, height = 17)
 ggdraw(all_cow) +
   draw_plot(all_cow)
 dev.off()

Thanks, Kevin