Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 36bb21e

Browse files
committed
Use _axis_method_wrapper for Axes3D.get_zscale
This matches the 2D case, and fixes the docstring.
1 parent 0eb2433 commit 36bb21e

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

lib/mpl_toolkits/mplot3d/axes3d.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
import matplotlib.image as mimage
2727
import matplotlib.lines as mlines
2828
import matplotlib.patches as mpatches
29-
import matplotlib.scale as mscale
3029
import matplotlib.container as mcontainer
3130
import matplotlib.transforms as mtransforms
3231
from matplotlib.axes import Axes, rcParams
@@ -672,12 +671,7 @@ def get_zlim(self):
672671
"""Get 3D z limits."""
673672
return tuple(self.zz_viewLim.intervalx)
674673

675-
def get_zscale(self):
676-
"""
677-
Return the zaxis scale string %s
678-
679-
""" % (", ".join(mscale.get_scale_names()))
680-
return self.zaxis.get_scale()
674+
get_zscale = _axis_method_wrapper("zaxis", "get_scale")
681675

682676
# We need to slightly redefine these to pass scalez=False
683677
# to their calls of autoscale_view.

0 commit comments

Comments
 (0)