copy plot_XXX attributes to suptitle subplot

This commit is contained in:
t-bltg 2021-07-03 18:28:49 +02:00
parent 300af83397
commit ee98506c56

View File

@ -291,6 +291,17 @@ function _add_plot_title!(plt)
subplot = Subplot(backend(), parent = plt.layout[1, 1]) subplot = Subplot(backend(), parent = plt.layout[1, 1])
subplot.plt = plt subplot.plt = plt
subplot[:title] = plot_title subplot[:title] = plot_title
for sym (
:titlefontsize,
:title_location,
:titlefontfamily,
:titlefonthalign,
:titlefontvalign,
:titlefontrotation,
:titlefontcolor,
)
subplot[sym] = plt[Symbol("plot_" * string(sym))]
end
subplot[:subplot_index] = last(plt.subplots)[:subplot_index] + 1 subplot[:subplot_index] = last(plt.subplots)[:subplot_index] + 1
subplot[:framestyle] = :none subplot[:framestyle] = :none
plt.layout.grid[1, 1] = subplot plt.layout.grid[1, 1] = subplot