Fix figure display for Gadfly

pull/94/head
Matti Pastell 2017-05-15 17:13:18 +03:00
parent 2e65f08e0e
commit 4bc5435e6d
3 changed files with 11 additions and 1 deletions

View File

@ -6,4 +6,4 @@ Highlights
Mustache
Documenter
YAML
Compat 0.17.0
Compat 0.25.0

View File

@ -2,6 +2,10 @@ import Gadfly
Gadfly.set_default_plot_format(:svg)
function Base.display(report::Report, m::MIME"image/png", p::Gadfly.Plot)
display(report, MIME("image/svg+xml"), p)
end
#Gadfly doesn't call the default display methods, this catches
#all Gadfly plots
function Base.display(report::Report, m::MIME"image/svg+xml", p::Gadfly.Plot)

View File

@ -52,6 +52,7 @@ julia> x = 1:10
1:10
julia> plot(x = x, y = x)
Plot(...)
~~~~~~~~~~~~~
@ -63,6 +64,7 @@ julia> plot(x = x, y = x)
julia> print(x)
1:10
julia> plot(x = x, y = x)
Plot(...)
~~~~~~~~~~~~~
@ -89,6 +91,7 @@ julietta> x = 1:10
1:10
julietta> plot(x = x, y = x)
Plot(...)
~~~~~~~~~~~~~
@ -100,6 +103,7 @@ julietta> plot(x = x, y = x)
julietta> print(x)
1:10
julietta> plot(x = x, y = x)
Plot(...)
~~~~~~~~~~~~~
@ -180,6 +184,7 @@ julia> x = 1:10
1:10
julia> plot(x = x, y = x)
Plot(...)
~~~~~~~~~~~~~
@ -191,6 +196,7 @@ julia> plot(x = x, y = x)
julia> print(x)
1:10
julia> plot(x = x, y = x)
Plot(...)
~~~~~~~~~~~~~