cell centered ticks

This commit is contained in:
t-bltg 2022-02-16 19:12:46 +01:00
parent 3629be15a2
commit 35388dcf4e
2 changed files with 2 additions and 3 deletions

View File

@ -677,7 +677,6 @@ end
# we return (continuous_value, discrete_index)
function discrete_value!(axis::Axis, dv)
cv_idx = get(axis[:discrete_map], dv, -1)
# @show axis[:discrete_map], axis[:discrete_values], dv
if cv_idx == -1
ex = axis[:extrema]
cv = NaNMath.max(0.5, ex.emax + 1.0)

View File

@ -1380,7 +1380,7 @@ function clamp_greys!(mat::AMat{<:Gray})
end
@recipe function f(mat::AMat{<:Gray})
n, m = map(a -> 0:(a.stop), axes(mat))
n, m = map(a -> range(0.5, stop = a.stop + 0.5), axes(mat))
if is_seriestype_supported(:image)
seriestype := :image
@ -1399,7 +1399,7 @@ end
# images - colors
@recipe function f(mat::AMat{T}) where {T<:Colorant}
n, m = map(a -> 0:(a.stop), axes(mat))
n, m = map(a -> range(0.5, stop = a.stop + 0.5), axes(mat))
if is_seriestype_supported(:image)
seriestype := :image