Hi,
I've used Qt Designer to construct a GUI.  An element of the GUI is a 
QGridLayout.  I've been trying to display a matplotlib plot in this 
QGridLayout.  I'm new at Python and have been trying to figure this out for the 
last week without success.  Essentially I'm trying to use elements of the 
example shown here:user_interfaces example code: embedding_in_qt4.py — 
Matplotlib 1.4.2 documentation

in my code shown here:http://paste.ofcode.org/JA2Hm8cP4jYD4c9NXgVGaE

Lines 23-25 is the problem area.  The error I get now is:RuntimeError: 
super-class __init__() of type MyStaticMplCanvas was never called

Conceptually what I think I'm doing is:# Line 24  Create an object of type 
MyStaticMplCanvas called thePlot.  This object is essentially a QWidget.thePlot 
= MyStaticMplCanvas(self.main_widget)
# Line 25  Pass thePlot as an argument to the addWidget method of the 
gridLayout I created in Qt Designer.self.ui.gridLayout.addWidget(thePlot)

Thx for the help.  I've spent about twenty hour trying to figure out this 
myself.  Any help you can give me would be great!
Matt

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to