On 2009-07-02 13:14-0400 Hazen Babcock wrote: > Alban Rochel wrote: >> Hello all, >> >> Actually, this is one of the few days I am in contact, so: >> - I must have misunderstood something about dynamic casts because I >> believed that QtPLDriver* widget=(QtPLDriver*)(pls->dev) would have >> created a "pure" QtPLDriver* object, and thus the member functions >> called after this would have been e.g. QtPLDriver::drawLine rather than >> e.g. QtRasterDevice::drawLine (no call of the virtual functions). This >> was the meaning of my "cryptic comment". >> - There is a simple and straightforward way to fix that without worrying >> about RTTI or whatever (well, at least for that): just define >> plD_whatever functions for every kind of driver, using simple C-casts. > > I went ahead and implemented this fix for the extqt driver only as that > is the driver that the PyQt4 bindings are using. If I ever figure out > what the underlying issue is will try and clean up the ugliness I've > added via this copy-paste approach.
Thanks, Hazen, for dealing with this subtle issue. The result passes my much-beloved ldd -r tests for qt.so, libplplotqt.so, qt_example, and plplot_pyqt4.so. Also, qt_example continues to work well and continues to give a clean valgrind result As of revision 10114, I got rid of the old version of the pyqt4 example since the new one supersedes it, and I fixed the issue with the new example that occurred for a non-standard PLplot installation prefix. The new pyqt4 example works fine for me which I was very happy to see! Now that you have gotten pyqt4 to work correctly with PLplot, I am looking forward to you extending the present example and/or adding additional pyqt4 examples to demonstrate the pyqt4 PLplot possibilities that have now opened up. What do you think of removing the pyqt3 example (prova.py and qplplot.py) in examples/python now that we have a working pyqt4 example? Maintenance releases of pyqt3 continue as can be seen at http://freshmeat.net/projects/pyqt/releases/301031. So we cannot justify removing our pyqt3 example based on pyqt3 no longer being viable, but on the other hand, nobody has worked on our pyqt3 bindings or our one pyqt3 example since they were donated years ago, and we now seem to have a pyqt4 alternative that is being actively developed and used by you. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); PLplot scientific plotting software package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ ------------------------------------------------------------------------------ _______________________________________________ Plplot-devel mailing list Plplot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/plplot-devel