Gaston: disable legends in contour plots

This commit is contained in:
t-bltg 2021-07-29 21:49:10 +02:00 committed by GitHub
parent 914ea027d0
commit cbc0417cea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -177,6 +177,7 @@ function gaston_seriesconf!(sp, series::Series)
st = series[:seriestype]
clims = get_clims(sp, series)
label = "title \"$(series[:label])\""
if st (:scatter, :scatter3d)
pt, ps, lc = gaston_mk_ms_mc(series)
push!(curveconf, "with points pt $pt ps $ps lc $lc")
@ -198,10 +199,12 @@ function gaston_seriesconf!(sp, series::Series)
elseif st == :steppost
push!(curveconf, "with fsteps") # Not sure if not the other way
elseif st (:contour, :contour3d)
label = "notitle"
push!(curveconf, "with lines")
if st == :contour
gsp.axesconf *= "\nset view map\nunset surface"
end
gsp.axesconf *= "\nunset key"
levels = join(map(string, collect(contour_levels(series, clims))), ", ")
gsp.axesconf *= "\nset contour base\nset cntrparam levels discrete $levels"
elseif st (:surface, :heatmap)
@ -218,8 +221,7 @@ function gaston_seriesconf!(sp, series::Series)
@warn "Gaston: $st is not implemented yet"
end
# label
push!(curveconf, "title \"$(series[:label])\"")
push!(curveconf, label)
return join(curveconf, " ")
end