@@ -7193,15 +7193,26 @@ def hist(self, x, bins=None, range=None, density=False, weights=None,
71937193 labels = [] if label is None else np .atleast_1d (np .asarray (label , str ))
71947194
71957195 if histtype == "step" :
7196- edgecolors = itertools .cycle (np .atleast_1d (kwargs .get ('edgecolor' ,
7197- colors )))
7196+ ec = kwargs .get ('edgecolor' , colors )
71987197 else :
7199- edgecolors = itertools .cycle (np .atleast_1d (kwargs .get ("edgecolor" , None )))
7198+ ec = kwargs .get ('edgecolor' , None )
7199+ if ec is None or cbook ._str_lower_equal (ec , 'none' ):
7200+ edgecolors = itertools .repeat (ec )
7201+ else :
7202+ edgecolors = itertools .cycle (mcolors .to_rgba_array (ec ))
7203+
7204+ fc = kwargs .get ('facecolor' , colors )
7205+ if cbook ._str_lower_equal (fc , 'none' ):
7206+ facecolors = itertools .repeat (fc )
7207+ else :
7208+ facecolors = itertools .cycle (mcolors .to_rgba_array (fc ))
72007209
7201- facecolors = itertools .cycle (np .atleast_1d (kwargs .get ('facecolor' , colors )))
72027210 hatches = itertools .cycle (np .atleast_1d (kwargs .get ('hatch' , None )))
72037211 linewidths = itertools .cycle (np .atleast_1d (kwargs .get ('linewidth' , None )))
7204- linestyles = itertools .cycle (np .atleast_1d (kwargs .get ('linestyle' , None )))
7212+ if 'linestyle' in kwargs :
7213+ linestyles = itertools .cycle (mlines ._get_dash_patterns (kwargs ['linestyle' ]))
7214+ else :
7215+ linestyles = itertools .repeat (None )
72057216
72067217 for patch , lbl in itertools .zip_longest (patches , labels ):
72077218 if not patch :
0 commit comments