Hello,

I've recently switched to PySide 1.0.8 on my MacBook using macports.
It seems that it breaks part of matplotlib.

Not sure if this is pyside or matplotlib bug but
the attached change in matplotlib solved the issue for me.

Regards,

David


>From 1fd9b3c9e1a3caa59c42d161c222327f96b9f5b3 Mon Sep 17 00:00:00 2001
From: David Tremouilles <dtremoui@macnight.local>
Date: Sat, 29 Oct 2011 09:24:25 +0200
Subject: [PATCH] pyside 1.0.8 compatibility fix

---
 lib/matplotlib/backends/backend_qt4.py |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/lib/matplotlib/backends/backend_qt4.py 
b/lib/matplotlib/backends/backend_qt4.py
index a31191b..fa9769c 100644
--- a/lib/matplotlib/backends/backend_qt4.py
+++ b/lib/matplotlib/backends/backend_qt4.py
@@ -144,7 +144,11 @@ class FigureCanvasQT( QtGui.QWidget, FigureCanvasBase ):
                 QtCore.Qt.Key_PageDown : 'pagedown',
                }
     # left 1, middle 2, right 3
-    buttond = {1:1, 2:3, 4:2}
+   #buttond = {1:1, 2:3, 4:2}
+    buttond = {QtCore.Qt.LeftButton : 1,
+               QtCore.Qt.MiddleButton : 3,
+               QtCore.Qt.RightButton : 2}
+
     def __init__( self, figure ):
         if DEBUG: print 'FigureCanvasQt: ', figure
         _create_qApp()
-- 
1.7.7.1

------------------------------------------------------------------------------
Get your Android app more play: Bring it to the BlackBerry PlayBook 
in minutes. BlackBerry App World&#153; now supports Android&#153; Apps 
for the BlackBerry&reg; PlayBook&#153;. Discover just how easy and simple 
it is! http://p.sf.net/sfu/android-dev2dev
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to