add guard against overexecution
This commit is contained in:
parent
86643058b6
commit
2bf3ddf45b
@ -419,7 +419,13 @@ function pgfx_axis!(opt::PGFPlotsX.Options, sp::Subplot, letter)
|
||||
end
|
||||
# --------------------------------------------------------------------------------------
|
||||
# display calls this and then _display, its called 3 times for plot(1:5)
|
||||
let n_calls = 0
|
||||
function _series_updated(plt::Plot{PGFPlotsXBackend}, series::Series)
|
||||
n_calls = 0
|
||||
end
|
||||
|
||||
function _update_plot_object(plt::Plot{PGFPlotsXBackend})
|
||||
if n_calls === 0
|
||||
plt.o = PGFPlotsX.GroupPlot()
|
||||
|
||||
for sp in plt.subplots
|
||||
@ -478,6 +484,8 @@ function _update_plot_object(plt::Plot{PGFPlotsXBackend})
|
||||
push!( plt.o, axis )
|
||||
end
|
||||
end
|
||||
n_calls += 1
|
||||
end
|
||||
|
||||
function _show(io::IO, mime::MIME"image/svg+xml", plt::Plot{PGFPlotsXBackend})
|
||||
show(io, mime, plt.o)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user