Hi,
I found a small bug in matplotlib.axes.Axes.add_artist method. matplotlib.artist.Artist.set_axes method is called twice.
def add_artist(self, a):
'''
Add any :class:`~matplotlib.artist.Artist` to the axes.
Returns the artist.
'''
* a.set_axes(self) *
self.artists.append(a)
self._set_artist_props(a)
a.set_clip_path(self.patch)
a._remove_method = lambda h: self.artists.remove(h)
return a
def _set_artist_props(self, a):
'set the boilerplate props for artists added to axes'
a.set_figure(self.figure)
if not a.is_transform_set():
a.set_transform(self.transData)
* a.set_axes(self) *
matplotlib version: 0.99.1.1
Regards,
Yann