Merge 8294615d33a2a4849ed4f17596b0ef14e043bad9 into f4b798765dff217739b850e26c4552df72deb2f2

This commit is contained in:
YongHee Kim 2017-05-08 23:56:11 +00:00 committed by GitHub
commit 95eca8b336

View File

@ -117,7 +117,15 @@ function savefig(plt::Plot, fn::AbstractString)
end end
savefig(fn::AbstractString) = savefig(current(), fn) savefig(fn::AbstractString) = savefig(current(), fn)
function Base.tempname()
tempfile_limit = UInt32(30)
global tempname_counter = if isdefined(Plots, :tempname_counter)
tempname_counter + UInt32(1)
else
UInt32(1)
end
return tempname(tempname_counter % tempfile_limit)
end
# --------------------------------------------------------- # ---------------------------------------------------------
gui(plt::Plot = current()) = display(PlotsDisplay(), plt) gui(plt::Plot = current()) = display(PlotsDisplay(), plt)