TerminalExtensions.jl + iterm2

TerminalExtensions.jl + iterm2 work nicely under 0.6.4 to visualize Gadfly and Plots.jl plots.

using TerminalExtensions, Gadfly, Plots
Plots.plot(1:10)
Gadfly.plot(x=1:10)

commands above generate figures in the xtem2 terminal.

However, this fails in julia 0.7 and 1.0. The figures go to the default app (browser, GKS, …)

How to make them show in the terminal?

1 Like
import Base: display
function display(p::Gadfly.Plot)
Gadfly.draw(Gadfly.PNG(), p)
println()
end

resolves this

I don’t have a mac, so I can’t test this, but have you tried reversing the using order so that TerminalExtensions gets imported last, i.e:

using Gadfly, Plots, TerminalExtensions
Plots.plot(1:10)
Gadfly.plot(x=1:10)