fix vector of colors as gradient
This commit is contained in:
parent
79fd7f282d
commit
e7f79e9144
@ -134,6 +134,7 @@ _cycle(cl::PlotUtils.AbstractColorList, idx::Int) = cl[mod1(idx, end)]
|
||||
_cycle(cl::PlotUtils.AbstractColorList, idx::AVec{Int}) = cl[mod1.(idx, end)]
|
||||
|
||||
_as_gradient(grad) = grad
|
||||
_as_gradient(v::AbstractVector{<:Colorant}) = cgrad(v)
|
||||
_as_gradient(cp::ColorPalette) = cgrad(cp, categorical = true)
|
||||
_as_gradient(c::Colorant) = ColorGradient([c,c])
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user