limit subplot attr when setting subplot kw

This commit is contained in:
Tom Breloff 2016-11-16 09:23:39 -05:00
parent ee2e807cc2
commit 247fe27f03

View File

@ -283,7 +283,11 @@ function _subplot_setup(plt::Plot, d::KW, kw_list::Vector{KW})
# override subplot/axis args. `sp_attrs` take precendence # override subplot/axis args. `sp_attrs` take precendence
for (idx,sp) in enumerate(plt.subplots) for (idx,sp) in enumerate(plt.subplots)
attr = merge(d, get(sp_attrs, sp, KW())) attr = if !haskey(d, :subplot) || d[:subplot] == idx
merge(d, get(sp_attrs, sp, KW()))
else
get(sp_attrs, sp, KW())
end
_update_subplot_args(plt, sp, attr, idx, false) _update_subplot_args(plt, sp, attr, idx, false)
end end