Skip to content

Commit 9e9554e

Browse files
authored
Merge pull request #14348 from anntzer/markers
Cleanup markers.py.
2 parents 4e5d83e + f62b9ba commit 9e9554e

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

lib/matplotlib/markers.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -274,9 +274,7 @@ def set_fillstyle(self, fillstyle):
274274
"""
275275
if fillstyle is None:
276276
fillstyle = rcParams['markers.fillstyle']
277-
if fillstyle not in self.fillstyles:
278-
raise ValueError("Unrecognized fillstyle %s"
279-
% ' '.join(self.fillstyles))
277+
cbook._check_in_list(self.fillstyles, fillstyle=fillstyle)
280278
self._fillstyle = fillstyle
281279
self._recache()
282280

@@ -396,9 +394,7 @@ def _set_mathtext_path(self):
396394
self._snap = False
397395

398396
def _half_fill(self):
399-
fs = self.get_fillstyle()
400-
result = fs in self._half_fillstyles
401-
return result
397+
return self.get_fillstyle() in self._half_fillstyles
402398

403399
def _set_circle(self, reduction=1.0):
404400
self._transform = Affine2D().scale(0.5 * reduction)

0 commit comments

Comments
 (0)