Revision: 3987 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=3987&view=rev Author: mdboom Date: 2007-10-23 12:16:11 -0700 (Tue, 23 Oct 2007)
Log Message: ----------- Fix bugs in log_demo.py Modified Paths: -------------- branches/transforms/lib/matplotlib/lines.py Modified: branches/transforms/lib/matplotlib/lines.py =================================================================== --- branches/transforms/lib/matplotlib/lines.py 2007-10-23 16:54:51 UTC (rev 3986) +++ branches/transforms/lib/matplotlib/lines.py 2007-10-23 19:16:11 UTC (rev 3987) @@ -284,7 +284,6 @@ self._xorig = npy.asarray([]) self._yorig = npy.asarray([]) self.set_data(xdata, ydata) - self._logcache = None def contains(self, mouseevent): """Test whether the mouse event occurred on the line. The pick radius determines @@ -386,6 +385,8 @@ self._xorig = x self._yorig = y self.recache() + else: + self._transformed_path = TransformedPath(self._path, self.get_transform()) def recache(self): #if self.axes is None: print 'recache no axes' @@ -418,7 +419,6 @@ self._xy = npy.concatenate((x, y), 1) self._x = self._xy[:, 0] # just a view self._y = self._xy[:, 1] # just a view - self._logcache = None # Masked arrays are now handled by the Path class itself self._path = Path(self._xy, closed=False) @@ -632,9 +632,7 @@ ACCEPTS: npy.array """ x = npy.asarray(x) - if x.shape != self._xorig.shape or npy.any(x != self._xorig): - self._xorig = x - self.recache() + self.set_data(x, self._yorig) def set_ydata(self, y): """ @@ -643,9 +641,7 @@ ACCEPTS: npy.array """ y = npy.asarray(y) - if y.shape != self._yorig.shape or npy.any(y != self._yorig): - self._yorig = y - self.recache() + self.set_data(self._xorig, y) def set_dashes(self, seq): """ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Matplotlib-checkins mailing list Matplotlib-checkins@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins