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

Skip to content

Commit 0c6dc13

Browse files
author
pkienzle
committed
patches: use None rather than 0 for full wedge
svn path=/trunk/matplotlib/; revision=6405
1 parent d8e8a65 commit 0c6dc13

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/matplotlib/patches.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -718,7 +718,7 @@ class Wedge(Patch):
718718
def __str__(self):
719719
return "Wedge(%g,%g)"%(self.theta1,self.theta2)
720720

721-
def __init__(self, center, r, theta1, theta2, width=0, **kwargs):
721+
def __init__(self, center, r, theta1, theta2, width=None, **kwargs):
722722
"""
723723
Draw a wedge centered at *x*, *y* center with radius *r* that
724724
sweeps *theta1* to *theta2* (in degrees). If *width* is given,
@@ -745,7 +745,7 @@ def __init__(self, center, r, theta1, theta2, width=0, **kwargs):
745745
# Form the outer ring
746746
arc = Path.arc(theta1,theta2)
747747

748-
if width != 0:
748+
if width is not None:
749749
# Partial annulus needs to draw the outter ring
750750
# followed by a reversed and scaled inner ring
751751
v1 = arc.vertices

0 commit comments

Comments
 (0)