Revision: 5214
http://matplotlib.svn.sourceforge.net/matplotlib/?rev=5214&view=rev
Author: jdh2358
Date: 2008-05-22 07:32:56 -0700 (Thu, 22 May 2008)
Log Message:
-----------
Merged revisions 5211,5213 via svnmerge from
https://matplotlib.svn.sourceforge.net/svnroot/matplotlib/branches/v0_91_maint
........
r5211 | mdboom | 2008-05-21 08:06:51 -0500 (Wed, 21 May 2008) | 2 lines
Backport TkAgg segfault fix.
........
r5213 | jdh2358 | 2008-05-22 09:21:10 -0500 (Thu, 22 May 2008) | 1 line
applied stans wx figsize patch
........
Modified Paths:
--------------
trunk/matplotlib/CHANGELOG
trunk/matplotlib/lib/matplotlib/backends/backend_wx.py
trunk/matplotlib/lib/matplotlib/figure.py
Property Changed:
----------------
trunk/matplotlib/
Property changes on: trunk/matplotlib
___________________________________________________________________
Name: svnmerge-integrated
- /branches/v0_91_maint:1-5207
+ /branches/v0_91_maint:1-5213
Modified: trunk/matplotlib/CHANGELOG
===================================================================
--- trunk/matplotlib/CHANGELOG 2008-05-22 14:21:10 UTC (rev 5213)
+++ trunk/matplotlib/CHANGELOG 2008-05-22 14:32:56 UTC (rev 5214)
@@ -1,3 +1,5 @@
+2008-05-21 Fix segfault in TkAgg backend - MGD
+
2008-05-21 Fix a "local variable unreferenced" bug in plotfile - MM
2008-05-19 Fix crash when Windows can not access the registry to
Modified: trunk/matplotlib/lib/matplotlib/backends/backend_wx.py
===================================================================
--- trunk/matplotlib/lib/matplotlib/backends/backend_wx.py 2008-05-22
14:21:10 UTC (rev 5213)
+++ trunk/matplotlib/lib/matplotlib/backends/backend_wx.py 2008-05-22
14:32:56 UTC (rev 5214)
@@ -1226,14 +1226,15 @@
pos =wx.Point(20,20)
l,b,w,h = fig.bbox.bounds
wx.Frame.__init__(self, parent=None, id=-1, pos=pos,
- title="Figure %d" % num,
- size=(w,h))
+ title="Figure %d" % num)
+ # Frame will be sized later by the Fit method
DEBUG_MSG("__init__()", 1, self)
self.num = num
statbar = StatusBarWx(self)
self.SetStatusBar(statbar)
self.canvas = self.get_canvas(fig)
+ self.canvas.SetInitialSize(wx.Size(fig.bbox.width(),
fig.bbox.height()))
self.sizer =wx.BoxSizer(wx.VERTICAL)
self.sizer.Add(self.canvas, 1, wx.TOP | wx.LEFT | wx.EXPAND)
# By adding toolbar in sizer, we are able to put it at the bottom
@@ -1352,6 +1353,11 @@
def set_window_title(self, title):
self.window.SetTitle(title)
+ def resize(self, width, height)
+ 'Set the canvas size in pixels'
+ self.canvas.SetInitialSize(wx.Size(width, height))
+ self.window.GetSizer().Fit(self.window)
+
# Identifiers for toolbar controls - images_wx contains bitmaps for the images
# used in the controls. wxWindows does not provide any stock images, so I've
# 'stolen' those from GTK2, and transformed them into the appropriate format.
Modified: trunk/matplotlib/lib/matplotlib/figure.py
===================================================================
--- trunk/matplotlib/lib/matplotlib/figure.py 2008-05-22 14:21:10 UTC (rev
5213)
+++ trunk/matplotlib/lib/matplotlib/figure.py 2008-05-22 14:32:56 UTC (rev
5214)
@@ -414,6 +414,7 @@
from the shell
WARNING: forward=True is broken on all backends except GTK*
+ and WX*
ACCEPTS: a w,h tuple with w,h in inches
"""
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: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins