SF.net SVN: matplotlib:[6813] trunk/matplotlib/ttconv/pprdrv_tt.cpp

2009-01-21 Thread mdboom
Revision: 6813
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6813&view=rev
Author:   mdboom
Date: 2009-01-21 14:25:11 + (Wed, 21 Jan 2009)

Log Message:
---
Remove %%EOF comment from embedded fonts, in an attempt to resolve Paul Novak's 
strange Postscript error.

Modified Paths:
--
trunk/matplotlib/ttconv/pprdrv_tt.cpp

Modified: trunk/matplotlib/ttconv/pprdrv_tt.cpp
===
--- trunk/matplotlib/ttconv/pprdrv_tt.cpp   2009-01-20 02:08:37 UTC (rev 
6812)
+++ trunk/matplotlib/ttconv/pprdrv_tt.cpp   2009-01-21 14:25:11 UTC (rev 
6813)
@@ -1070,7 +1070,7 @@
} /* end of if Type 42 not understood. */
 
 stream.putline("FontName currentdict end definefont pop");
-stream.putline("%%EOF");
+/* stream.putline("%%EOF"); */
 } /* end of ttfont_trailer() */
 
 /*--


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:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
___
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins


SF.net SVN: matplotlib:[6814] trunk/matplotlib/src/agg_py_path_iterator.h

2009-01-21 Thread mdboom
Revision: 6814
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6814&view=rev
Author:   mdboom
Date: 2009-01-21 14:52:26 + (Wed, 21 Jan 2009)

Log Message:
---
Change simplification algorithm so it always returns points from the original 
data, rather than extrapolated ones.  This is somewhat experimental.

Modified Paths:
--
trunk/matplotlib/src/agg_py_path_iterator.h

Modified: trunk/matplotlib/src/agg_py_path_iterator.h
===
--- trunk/matplotlib/src/agg_py_path_iterator.h 2009-01-21 14:25:11 UTC (rev 
6813)
+++ trunk/matplotlib/src/agg_py_path_iterator.h 2009-01-21 14:52:26 UTC (rev 
6814)
@@ -142,8 +142,8 @@
 m_do_clipping(width > 0.0 && height > 0.0),
 m_origdx(0.0), m_origdy(0.0),
 m_origdNorm2(0.0), m_dnorm2Max(0.0), m_dnorm2Min(0.0),
-m_haveMin(false), m_lastMax(false), m_maxX(0.0), m_maxY(0.0),
-m_minX(0.0), m_minY(0.0), m_lastWrittenX(0.0), m_lastWrittenY(0.0)
+m_lastMax(false), m_nextX(0.0), m_nextY(0.0),
+m_lastWrittenX(0.0), m_lastWrittenY(0.0)
 #if DEBUG_SIMPLIFY
 , m_pushed(0), m_skipped(0)
 #endif
@@ -302,13 +302,12 @@
 //set all the variables to reflect this new orig vector
 m_dnorm2Max = m_origdNorm2;
 m_dnorm2Min = 0.0;
-m_haveMin = false;
 m_lastMax = true;
 
-m_lastx = m_maxX = *x;
-m_lasty = m_maxY = *y;
-m_lastWrittenX = m_minX = m_lastx;
-m_lastWrittenY = m_minY = m_lasty;
+m_nextX = m_lastWrittenX = m_lastx;
+m_nextY = m_lastWrittenY = m_lasty;
+m_lastx = *x;
+m_lasty = *y;
 #if DEBUG_SIMPLIFY
 m_skipped++;
 #endif
@@ -358,18 +357,17 @@
 {
 m_lastMax = true;
 m_dnorm2Max = paradNorm2;
-m_maxX = m_lastWrittenX + paradx;
-m_maxY = m_lastWrittenY + parady;
+m_nextX = *x;
+m_nextY = *y;
 }
 }
 else
 {
-m_haveMin = true;
 if (paradNorm2 > m_dnorm2Min)
 {
 m_dnorm2Min = paradNorm2;
-m_minX = m_lastWrittenX + paradx;
-m_minY = m_lastWrittenY + parady;
+m_nextX = *x;
+m_nextY = *y;
 }
 }
 
@@ -394,17 +392,12 @@
 }
 
 // Fill the queue with the remaining vertices if we've finished the
-// path in the above loop.  Mark the path as done, so we don't call
-// m_source->vertex again and segfault.
+// path in the above loop.
 if (cmd == agg::path_cmd_stop)
 {
 if (m_origdNorm2 != 0.0)
 {
-if (m_haveMin)
-{
-queue_push(agg::path_cmd_line_to, m_minX, m_minY);
-}
-queue_push(agg::path_cmd_line_to, m_maxX, m_maxY);
+queue_push(agg::path_cmd_line_to, m_nextX, m_nextY);
 }
 queue_push(agg::path_cmd_stop, 0.0, 0.0);
 }
@@ -459,12 +452,9 @@
 double m_origdNorm2;
 double m_dnorm2Max;
 double m_dnorm2Min;
-bool   m_haveMin;
 bool   m_lastMax;
-double m_maxX;
-double m_maxY;
-double m_minX;
-double m_minY;
+double m_nextX;
+double m_nextY;
 double m_lastWrittenX;
 double m_lastWrittenY;
 
@@ -517,11 +507,7 @@
 
 inline void _push(double* x, double* y)
 {
-if (m_haveMin)
-{
-queue_push(agg::path_cmd_line_to, m_minX, m_minY);
-}
-queue_push(agg::path_cmd_line_to, m_maxX, m_maxY);
+queue_push(agg::path_cmd_line_to, m_nextX, m_nextY);
 
 //if we clipped some segments between this line and the next line
 //we are starting, we also need to move to the last point.
@@ -546,12 +532,11 @@
 
 m_dnorm2Max = m_origdNorm2;
 m_dnorm2Min = 0.0;
-m_haveMin = false;
 m_lastMax = true;
-m_lastx = m_maxX = *x;
-m_lasty = m_maxY = *y;
-m_lastWrittenX = m_minX = m_lastx;
-m_lastWrittenY = m_minY = m_lasty;
+m_lastWrittenX = m_queue[m_queue_write-1].x;
+m_lastWrittenY = m_queue[m_queue_write-1].y;
+m_lastx = m_nextX = *x;
+m_lasty = m_nextY = *y;
 
 m_clipped = false;
 #if DEBUG_SIMPLIFY


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

--

SF.net SVN: matplotlib:[6815] trunk/matplotlib

2009-01-21 Thread jdh2358
Revision: 6815
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6815&view=rev
Author:   jdh2358
Date: 2009-01-21 19:09:15 + (Wed, 21 Jan 2009)

Log Message:
---
changed defaults on acorr and xcorr to norm, usevlines and maxlags=10

Modified Paths:
--
trunk/matplotlib/CHANGELOG
trunk/matplotlib/doc/api/api_changes.rst
trunk/matplotlib/lib/matplotlib/axes.py

Modified: trunk/matplotlib/CHANGELOG
===
--- trunk/matplotlib/CHANGELOG  2009-01-21 14:52:26 UTC (rev 6814)
+++ trunk/matplotlib/CHANGELOG  2009-01-21 19:09:15 UTC (rev 6815)
@@ -1,3 +1,7 @@
+2009-01-21 Changed the defaults of acorr and xcorr to use
+   usevlines=True, maxlags=10 and normed=True since these are
+   the best defaults
+
 2009-01-19 Fix bug in quiver argument handling. - EF
 
 2009-01-19 Fix bug in backend_gtk: don't delete nonexistent toolbar. - EF

Modified: trunk/matplotlib/doc/api/api_changes.rst
===
--- trunk/matplotlib/doc/api/api_changes.rst2009-01-21 14:52:26 UTC (rev 
6814)
+++ trunk/matplotlib/doc/api/api_changes.rst2009-01-21 19:09:15 UTC (rev 
6815)
@@ -19,20 +19,24 @@
 
 Changes for 0.98.x
 ==
+
+* Changed the defaults of acorr and xcorr to use usevlines=True,
+  maxlags=10 and normed=True since these are the best defaults
+
 * Following keyword parameters for :class:`matplotlib.label.Label` are now
-  deprecated and new set of parameters are introduced. The new parameters 
-  are given as a fraction of the font-size. Also, *scatteryoffsets*, 
+  deprecated and new set of parameters are introduced. The new parameters
+  are given as a fraction of the font-size. Also, *scatteryoffsets*,
   *fancybox* and *columnspacing* are added as keyword parameters.
 
    
 Deprecated New
    
-padborderpad  
-labelsep   labelspacing   
-handlelen  handlelength   
-handlestextsep handletextpad  
-axespad   borderaxespad  
-      
+padborderpad
+labelsep   labelspacing
+handlelen  handlelength
+handlestextsep handletextpad
+axespad   borderaxespad
+   
 
 
 * Removed the configobj and experiemtnal traits rc support

Modified: trunk/matplotlib/lib/matplotlib/axes.py
===
--- trunk/matplotlib/lib/matplotlib/axes.py 2009-01-21 14:52:26 UTC (rev 
6814)
+++ trunk/matplotlib/lib/matplotlib/axes.py 2009-01-21 19:09:15 UTC (rev 
6815)
@@ -3543,8 +3543,8 @@
 """
 call signature::
 
-acorr(x, normed=False, detrend=mlab.detrend_none, usevlines=False,
-  maxlags=None, **kwargs)
+acorr(x, normed=True, detrend=mlab.detrend_none, usevlines=True,
+  maxlags=10, **kwargs)
 
 Plot the autocorrelation of *x*.  If *normed* = *True*,
 normalize the data by the autocorrelation at 0-th lag.  *x* is
@@ -3602,13 +3602,13 @@
 return self.xcorr(x, x, **kwargs)
 acorr.__doc__ = cbook.dedent(acorr.__doc__) % martist.kwdocd
 
-def xcorr(self, x, y, normed=False, detrend=mlab.detrend_none,
-  usevlines=False, maxlags=None, **kwargs):
+def xcorr(self, x, y, normed=True, detrend=mlab.detrend_none,
+  usevlines=True, maxlags=10, **kwargs):
 """
 call signature::
 
-  xcorr(x, y, normed=False, detrend=mlab.detrend_none,
-usevlines=False, **kwargs):
+def xcorr(self, x, y, normed=True, detrend=mlab.detrend_none,
+  usevlines=True, maxlags=10, **kwargs):
 
 Plot the cross correlation between *x* and *y*.  If *normed* =
 *True*, normalize the data by the cross correlation at 0-th


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:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
___
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins


SF.net SVN: matplotlib:[6816] branches/v0_98_5_maint/lib/matplotlib/ backends/backend_cocoaagg.py

2009-01-21 Thread jdh2358
Revision: 6816
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6816&view=rev
Author:   jdh2358
Date: 2009-01-22 02:48:32 + (Thu, 22 Jan 2009)

Log Message:
---
fixed a cocoaagg import bug

Modified Paths:
--
branches/v0_98_5_maint/lib/matplotlib/backends/backend_cocoaagg.py

Modified: branches/v0_98_5_maint/lib/matplotlib/backends/backend_cocoaagg.py
===
--- branches/v0_98_5_maint/lib/matplotlib/backends/backend_cocoaagg.py  
2009-01-21 19:09:15 UTC (rev 6815)
+++ branches/v0_98_5_maint/lib/matplotlib/backends/backend_cocoaagg.py  
2009-01-22 02:48:32 UTC (rev 6816)
@@ -29,7 +29,7 @@
 
 import matplotlib
 from matplotlib.figure import Figure
-from matplotlib.backend_bases import FigureManagerBase
+from matplotlib.backend_bases import FigureManagerBase, FigureCanvasBase
 from backend_agg import FigureCanvasAgg
 from matplotlib._pylab_helpers import Gcf
 


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:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
___
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins


SF.net SVN: matplotlib:[6817] trunk/matplotlib

2009-01-21 Thread jdh2358
Revision: 6817
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6817&view=rev
Author:   jdh2358
Date: 2009-01-22 02:54:23 + (Thu, 22 Jan 2009)

Log Message:
---
Merged revisions 6816 via svnmerge from 
https://matplotlib.svn.sourceforge.net/svnroot/matplotlib/branches/v0_98_5_maint


  r6816 | jdh2358 | 2009-01-21 20:48:32 -0600 (Wed, 21 Jan 2009) | 1 line
  
  fixed a cocoaagg import bug


Modified Paths:
--
trunk/matplotlib/lib/matplotlib/backends/backend_cocoaagg.py

Property Changed:

trunk/matplotlib/


Property changes on: trunk/matplotlib
___
Modified: svnmerge-integrated
   - /branches/v0_91_maint:1-6428 /branches/v0_98_5_maint:1-6811
   + /branches/v0_91_maint:1-6428 /branches/v0_98_5_maint:1-6816

Modified: trunk/matplotlib/lib/matplotlib/backends/backend_cocoaagg.py
===
--- trunk/matplotlib/lib/matplotlib/backends/backend_cocoaagg.py
2009-01-22 02:48:32 UTC (rev 6816)
+++ trunk/matplotlib/lib/matplotlib/backends/backend_cocoaagg.py
2009-01-22 02:54:23 UTC (rev 6817)
@@ -29,7 +29,7 @@
 
 import matplotlib
 from matplotlib.figure import Figure
-from matplotlib.backend_bases import FigureManagerBase
+from matplotlib.backend_bases import FigureManagerBase, FigureCanvasBase
 from backend_agg import FigureCanvasAgg
 from matplotlib._pylab_helpers import Gcf
 


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:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
___
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins


SF.net SVN: matplotlib:[6818] branches/v0_98_5_maint/lib/matplotlib/legend. py

2009-01-21 Thread jdh2358
Revision: 6818
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6818&view=rev
Author:   jdh2358
Date: 2009-01-22 03:06:44 + (Thu, 22 Jan 2009)

Log Message:
---
fixed line collections legmarker sf bug 2511280

Modified Paths:
--
branches/v0_98_5_maint/lib/matplotlib/legend.py

Modified: branches/v0_98_5_maint/lib/matplotlib/legend.py
===
--- branches/v0_98_5_maint/lib/matplotlib/legend.py 2009-01-22 02:54:23 UTC 
(rev 6817)
+++ branches/v0_98_5_maint/lib/matplotlib/legend.py 2009-01-22 03:06:44 UTC 
(rev 6818)
@@ -272,7 +272,7 @@
 self._set_artist_props(self.legendPatch)
 
 self._drawFrame = True
-
+
 # init with null renderer
 self._init_legend_box(handles, labels)
 
@@ -327,9 +327,9 @@
 
 def findoffset(width, height, xdescent, ydescent):
 return _findoffset(width, height, xdescent, ydescent, renderer)
-
+
 self._legend_box.set_offset(findoffset)
-
+
 fontsize = renderer.points_to_pixels(self.fontsize)
 
 # if mode == fill, set the width of the legend_box to the
@@ -623,8 +623,11 @@
 ydata = ((height-descent)/2.)*np.ones(xdata.shape, float)
 legline.set_data(xdata, ydata)
 
-legline_marker = legline._legmarker
-legline_marker.set_data(xdata_marker, 
ydata[:len(xdata_marker)])
+# if a line collection is added, the legmarker attr is
+# not set so we don't need to handle it
+if hasattr(handle, "_legmarker"):
+legline_marker = legline._legmarker
+legline_marker.set_data(xdata_marker, 
ydata[:len(xdata_marker)])
 
 elif isinstance(handle, Patch):
 p = handle
@@ -765,7 +768,7 @@
   C:"C"}
 
 c = anchor_coefs[loc]
-
+
 fontsize = renderer.points_to_pixels(self.fontsize)
 container = parentbbox.padded(-(self.borderaxespad) * fontsize)
 anchored_box = bbox.anchored(c, container=container)


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:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
___
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins


SF.net SVN: matplotlib:[6819] trunk/matplotlib

2009-01-21 Thread jdh2358
Revision: 6819
  http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6819&view=rev
Author:   jdh2358
Date: 2009-01-22 03:12:53 + (Thu, 22 Jan 2009)

Log Message:
---
Merged revisions 6818 via svnmerge from 
https://matplotlib.svn.sourceforge.net/svnroot/matplotlib/branches/v0_98_5_maint


  r6818 | jdh2358 | 2009-01-21 21:06:44 -0600 (Wed, 21 Jan 2009) | 1 line
  
  fixed line collections legmarker sf bug 2511280


Modified Paths:
--
trunk/matplotlib/lib/matplotlib/legend.py

Property Changed:

trunk/matplotlib/


Property changes on: trunk/matplotlib
___
Modified: svnmerge-integrated
   - /branches/v0_91_maint:1-6428 /branches/v0_98_5_maint:1-6816
   + /branches/v0_91_maint:1-6428 /branches/v0_98_5_maint:1-6818

Modified: trunk/matplotlib/lib/matplotlib/legend.py
===
--- trunk/matplotlib/lib/matplotlib/legend.py   2009-01-22 03:06:44 UTC (rev 
6818)
+++ trunk/matplotlib/lib/matplotlib/legend.py   2009-01-22 03:12:53 UTC (rev 
6819)
@@ -272,7 +272,7 @@
 self._set_artist_props(self.legendPatch)
 
 self._drawFrame = True
-
+
 # init with null renderer
 self._init_legend_box(handles, labels)
 
@@ -327,9 +327,9 @@
 
 def findoffset(width, height, xdescent, ydescent):
 return _findoffset(width, height, xdescent, ydescent, renderer)
-
+
 self._legend_box.set_offset(findoffset)
-
+
 fontsize = renderer.points_to_pixels(self.fontsize)
 
 # if mode == fill, set the width of the legend_box to the
@@ -623,8 +623,11 @@
 ydata = ((height-descent)/2.)*np.ones(xdata.shape, float)
 legline.set_data(xdata, ydata)
 
-legline_marker = legline._legmarker
-legline_marker.set_data(xdata_marker, 
ydata[:len(xdata_marker)])
+# if a line collection is added, the legmarker attr is
+# not set so we don't need to handle it
+if hasattr(handle, "_legmarker"):
+legline_marker = legline._legmarker
+legline_marker.set_data(xdata_marker, 
ydata[:len(xdata_marker)])
 
 elif isinstance(handle, Patch):
 p = handle
@@ -765,7 +768,7 @@
   C:"C"}
 
 c = anchor_coefs[loc]
-
+
 fontsize = renderer.points_to_pixels(self.fontsize)
 container = parentbbox.padded(-(self.borderaxespad) * fontsize)
 anchored_box = bbox.anchored(c, container=container)


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:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
___
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins