Skip to content

Commit 0b889a7

Browse files
committed
Remove hard-coded streamplot zorder and let mlinesLine2D.zorder to be the default
1 parent 8ff57bb commit 0b889a7

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/matplotlib/axes/_axes.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4613,9 +4613,11 @@ def stackplot(self, x, *args, **kwargs):
46134613
label_namer=None)
46144614
def streamplot(self, x, y, u, v, density=1, linewidth=None, color=None,
46154615
cmap=None, norm=None, arrowsize=1, arrowstyle='-|>',
4616-
minlength=0.1, transform=None, zorder=2, start_points=None):
4616+
minlength=0.1, transform=None, zorder=None, start_points=None):
46174617
if not self._hold:
46184618
self.cla()
4619+
if zorder is None:
4620+
zorder = mlines.Line2D.zorder
46194621
stream_container = mstream.streamplot(self, x, y, u, v,
46204622
density=density,
46214623
linewidth=linewidth,

0 commit comments

Comments
 (0)