-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xlims! error on GeoAxis #196
Comments
Seems to be the same issue as #191 |
Try running this code and see if it works? function Makie.xlims!(ax::GeoAxis, xlims)
if length(xlims) != 2
error("Invalid xlims length of $(length(xlims)), must be 2.")
elseif xlims[1] == xlims[2] && xlims[1] !== nothing
error("Can't set x limits to the same value $(xlims[1]).")
elseif all(x -> x isa Real, xlims) && xlims[1] > xlims[2]
xlims = reverse(xlims)
ax.xreversed[] = true
else
ax.xreversed[] = false
end
mlims = Makie.convert_limit_attribute(ax.limits[])
ax.limits.val = (xlims, mlims[2])
Makie.reset_limits!(ax; yauto=false)
return nothing
end It's basically what you suggested @jjgecon :) - if this works will create a new patch release with these two fixes! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm trying to set up a map with
xlims!
where
gives the error
MethodError: no method matching convert_limit_attribute(::Rect2{Float64})
I think there is an error in the source code
makie-axis.jl
because unlikeylims!
(which work) haveax.finallimits[]
in line 446 insteadax.limits[]
.The text was updated successfully, but these errors were encountered: