[Qt-interest] QLineEdit signal

Luca Ottaviano lottaviano at develer.com
Thu Mar 26 11:25:45 CET 2009


Il giorno gio, 26/03/2009 alle 10.15 +0100, NARCISO, Rui ha scritto:
> Apparently not...
> I'm getting the following error on the line just after the creation of
> MyQLineEdit (self.path = MyQLineEdit(self)   )
> Traceback (most recent call last):
> 
> File
> "/home/cfdqdv2/to96665/TOOLS/EGADYT/integration/Version_0.9.4/CampaignManager/MainWindow.py", line 302, in addCalculationMenu
> 
> diag = AddCalculationDlg(self, self.statusList)
> 
> File
> "/home/cfdqdv2/to96665/TOOLS/EGADYT/integration/Version_0.9.4/CampaignManager/AddCalculationDialog.py", line 36, in __init__
> 
> layout.addWidget(self.path, 3,1)
> 
> RuntimeError: underlying C/C++ object has been deleted

You have to be careful in the way you create objects in PyQt. If you
don't specify a python object as parent, the ownership of the object
remains to c++ code which will delete the object without notifying
python.

Hope this helps. I bet, however, that you will receive more precise
answers on the pyqt mailing list.

Best regards,

-- 
Ing. Luca Ottaviano - lottaviano at develer.com
Develer S.r.l. - http://www.develer.com/
.hardware .software .innovation
Tel.: +39 055 3986627 - ext.: 218




More information about the Qt-interest-old mailing list