@@ -4,7 +4,7 @@ module PyPlot
4
4
5
5
using PyCall
6
6
import PyCall: PyObject, pygui, pycall, pyexists
7
- import Base: convert, == , isequal, hash, getindex, setindex!, haskey, keys, show, mimewritable
7
+ import Base: convert, == , isequal, hash, getindex, setindex!, haskey, keys, show, showable
8
8
export Figure, plt, matplotlib, pygui, withfig
9
9
10
10
using Compat
@@ -78,14 +78,14 @@ for (mime,fmt) in aggformats
78
78
f. o[" canvas" ][" print_figure" ](io, format= $ fmt, bbox_inches= " tight" )
79
79
end
80
80
if fmt != " svg"
81
- @eval mimewritable (:: MIME{Symbol($mime)} , f:: Figure ) = ! isempty (f) && haskey (pycall (f. o[" canvas" ][" get_supported_filetypes" ], PyDict), $ fmt)
81
+ @eval showable (:: MIME{Symbol($mime)} , f:: Figure ) = ! isempty (f) && haskey (pycall (f. o[" canvas" ][" get_supported_filetypes" ], PyDict), $ fmt)
82
82
end
83
83
end
84
84
85
85
# disable SVG output by default, since displaying large SVGs (large datasets)
86
86
# in IJulia is slow, and browser SVG display is buggy. (Similar to IPython.)
87
87
const SVG = [false ]
88
- mimewritable (:: MIME"image/svg+xml" , f:: Figure ) = SVG[1 ] && ! isempty (f) && haskey (pycall (f. o[" canvas" ][" get_supported_filetypes" ], PyDict), " svg" )
88
+ showable (:: MIME"image/svg+xml" , f:: Figure ) = SVG[1 ] && ! isempty (f) && haskey (pycall (f. o[" canvas" ][" get_supported_filetypes" ], PyDict), " svg" )
89
89
svg () = SVG[1 ]
90
90
svg (b:: Bool ) = (SVG[1 ] = b)
91
91
0 commit comments