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

Skip to content

Commit 8dda8ba

Browse files
committed
Applied Tony's circle patch
svn path=/trunk/matplotlib/; revision=7132
1 parent 3093ce9 commit 8dda8ba

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

examples/user_interfaces/embedding_in_wx3.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ def OnInit(self):
147147
return True
148148

149149
def OnBang(self,event):
150-
bang_count = XRCCTRL(self.frame,"bang_count")
150+
bang_count = xrc.XRCCTRL(self.frame,"bang_count")
151151
bangs = bang_count.GetValue()
152152
bangs = int(bangs)+1
153153
bang_count.SetValue(str(bangs))

lib/matplotlib/patches.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1131,6 +1131,14 @@ def __init__(self, xy, radius=5, **kwargs):
11311131
self.radius = radius
11321132
Ellipse.__init__(self, xy, radius*2, radius*2, **kwargs)
11331133
__init__.__doc__ = cbook.dedent(__init__.__doc__) % artist.kwdocd
1134+
1135+
def radius():
1136+
def fget(self):
1137+
return self.width / 2.
1138+
def fset(self, radius):
1139+
self.width = self.height = 2 * radius
1140+
return locals()
1141+
radius = property(**radius())
11341142

11351143
class Arc(Ellipse):
11361144
"""

0 commit comments

Comments
 (0)