Skip to content

Commit

Permalink
check for matplotlibs.colormaps before matplotlibs.colormaps.register (
Browse files Browse the repository at this point in the history
  • Loading branch information
stevengj authored Jul 5, 2024
1 parent 28826e0 commit c229e30
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/colormaps.jl
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ function init_colormaps()
copy!(LinearSegmentedColormap, colorsm."LinearSegmentedColormap")

copy!(cm_get_cmap, haskey(plt, "get_cmap") ? plt."get_cmap" : cm."get_cmap")
copy!(cm_register_cmap, haskey(matplotlib.colormaps, "register") ? matplotlib.colormaps."register" : cm."register_cmap")
copy!(cm_register_cmap, haskey(matplotlib, "colormaps") && haskey(matplotlib."colormaps", "register") ? matplotlib."colormaps"."register" : cm."register_cmap")

copy!(ScalarMappable, cm."ScalarMappable")
copy!(Normalize01, pycall(colorsm."Normalize",PyAny,vmin=0,vmax=1))
Expand Down

0 comments on commit c229e30

Please sign in to comment.