gr extrema fix; themes gradient_name fix

This commit is contained in:
Thomas Breloff 2016-10-13 13:24:25 -04:00
parent 0a8d88a4fe
commit b1835a91af
2 changed files with 5 additions and 5 deletions

View File

@ -732,10 +732,10 @@ function gr_display(sp::Subplot{GRBackend}, w, h, viewport_canvas)
# recompute data # recompute data
if typeof(z) <: Surface if typeof(z) <: Surface
if st == :heatmap # if st == :heatmap
expand_extrema!(sp[:xaxis], (x[1]-0.5*(x[2]-x[1]), x[end]+0.5*(x[end]-x[end-1]))) # expand_extrema!(sp[:xaxis], (x[1]-0.5*(x[2]-x[1]), x[end]+0.5*(x[end]-x[end-1])))
expand_extrema!(sp[:yaxis], (y[1]-0.5*(y[2]-y[1]), y[end]+0.5*(y[end]-y[end-1]))) # expand_extrema!(sp[:yaxis], (y[1]-0.5*(y[2]-y[1]), y[end]+0.5*(y[end]-y[end-1])))
end # end
z = vec(transpose_z(series, z.surf, false)) z = vec(transpose_z(series, z.surf, false))
elseif ispolar(sp) elseif ispolar(sp)
if frng != nothing if frng != nothing

View File

@ -23,7 +23,7 @@ function theme(s::Symbol; kw...)
# update the default gradient and other defaults # update the default gradient and other defaults
thm = PlotThemes._themes[s] thm = PlotThemes._themes[s]
if thm.gradient != nothing if thm.gradient != nothing
PlotUtils._default_gradient[] = s PlotUtils._default_gradient[] = PlotThemes.gradient_name(s)
end end
default(; default(;
bg = thm.bg_secondary, bg = thm.bg_secondary,