RE: [Qt-root-l] RE: PyQt and PyROOT

From: Fine, Valeri <fine_at_bnl.gov>
Date: Tue, 16 Jan 2007 10:32:04 -0500


> Note that by putting in the "main":

 . . .
> print qt.qApp
> print ROOT.gApplication

 . . .

> what we get is:

 . . .

> <qt.QApplication object at 0xb7ed302c>
> <ROOT.TApplication* object ("PyROOT::TPyROOTApplication") at 0x16d7f90>
 . . .

> meaning that both qt.qApp and ROOT.gApplication seem to exist, at that point.
> I guess I'm confused, now.
 

Yes, this is correct both of them MUST be present.  

Cheers, Valeri


From: qt-root-l-bounces_at_lists.bnl.gov on behalf of Qt-Root integration project Sent: Tue 1/16/2007 10:27 AM
To: Luca Baldini; qt-root-l_at_lists.bnl.gov Cc: WLavrijsen_at_lbl.gov; Johan Bregeon; ROOT Talk Subject: Re: [Qt-root-l] [ROOT] RE: PyQt and PyROOT

Hi Luca, Thank you very much for your update.

I'll investigate how PyROOT manages the ROOT event loop today to provide you the further assistance.

Mean time I need to know whether you did customize your $ROOTSYS/etc/system.rootrc or provide your custom ".rootrc" somewhere. Can you send me these files? May be we should discuss the QtRoot issue via http://lists.bnl.gov/mailman/listinfo/qt-root-l <http://lists.bnl.gov/mailman/listinfo/qt-root-l> to avoid the ROOTTALK pollution.

I had explained the nature of the warnings:

> Warning in <TClass::TClass>: no dictionary for class Qt is available
> Warning in <TClass::TClass>: no dictionary for class QPaintDevice is

and proposed the "way" to eliminate it. We need a Python's guru advice to avoid "qtcint" shared library usage. Please, let me know whether I should elaborate further.

Have a nice day, Valeri


From: Luca Baldini [mailto:luca.baldini_at_pi.infn.it] Sent: Tue 1/16/2007 9:53 AM
To: Fine, Valeri
Cc: Luca Baldini; Johan Bregeon; WLavrijsen_at_lbl.gov; ROOT Talk Subject: Re: [ROOT] RE: PyQt and PyROOT

Hi all,
adding some more entropy...
If we modify our "main" like this:

if __name__ == '__main__':

   qt.QObject.connect(qt.qApp, qt.SIGNAL("lastWindowClosed()"), qt.qApp, qt.SLOT("quit()"))

   w = MainWindow()
   w.resize(350, 350)
   w.show()
   qt.qApp.exec_loop()

i.e. adding the qt.qApp stuff, the windows behaves like we expect... sometimes! Often it hangs up without
the histogram inside, but once in a while it looks ok and we're able to get the shell back by closing the window. Also note that we made a fresh ROOT installation with the qtFullRoot package, as suggested by Valeri.
We don't have any error, anymore; just a couple of warnings:

[online_at_pcglast23 test]$ ./pyqtroot.py
** $Id: TGQt.cxx,v 1.146 2007/01/15 07:30:32 fine Exp $ this=0x89fb928 Warning in <TClass::TClass>: no dictionary for class Qt is available Warning in <TClass::TClass>: no dictionary for class QPaintDevice is available

Thanks a lot for your patience, hope that helps.

P.S. We also tried the ROOT.gApplication.Run(), and that does not help. Note that by putting in the "main":

if __name__ == '__main__':

   w = MainWindow()
   w.resize(350, 350)
   w.show()
   print qt.qApp
   print ROOT.gApplication

what we get is:

[online_at_pcglast23 test]$ ./pyqtroot.py
** $Id: TGQt.cxx,v 1.146 2007/01/15 07:30:32 fine Exp $ this=0x93078e8 Warning in <TClass::TClass>: no dictionary for class Qt is available Warning in <TClass::TClass>: no dictionary for class QPaintDevice is available
<qt.QApplication object at 0xb7ed302c>
<ROOT.TApplication* object ("PyROOT::TPyROOTApplication") at 0x16d7f90>

meaning that both qt.qApp and ROOT.gApplication seem to exist, at that point.
I guess I'm confused, now.

Cheers,
Johan, Luca



Qt-Root-l mailing list
Qt-Root-l_at_lists.bnl.gov
http://lists.bnl.gov/mailman/listinfo/qt-root-l Received on Tue Jan 16 2007 - 16:36:46 CET

This archive was generated by hypermail 2.2.0 : Tue Jan 16 2007 - 17:50:01 CET