Skip to content

Commit

Permalink
cell centered ticks
Browse files Browse the repository at this point in the history
  • Loading branch information
t-bltg committed Feb 16, 2022
1 parent 3de4576 commit 9fd6a73
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion src/axes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
4 changes: 2 additions & 2 deletions src/recipes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -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(.5, stop = a.stop + .5), axes(mat))

if is_seriestype_supported(:image)
seriestype := :image
Expand All @@ -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(.5, stop = a.stop + .5), axes(mat))

if is_seriestype_supported(:image)
seriestype := :image
Expand Down

0 comments on commit 9fd6a73

Please sign in to comment.