Re: [PyKDE] qt.QStyle problems on PyQt-snapshot-20050404
On Thursday 07 April 2005 3:15 pm, Ümit Öztosun wrote: Hello, We are using a custom QPushButton derived widget in our application. I tried PyQt-x11-gpl-snapshot-20050404.tar.gz together with sip-snapshot-20050403.tar.gz, and I am getting TypeError: qt.QStyle represents a C++ abstract class and cannot be instantiated errors. The problem occurs when using KDE styles, i.e. 'plastik', 'highcolor' etc. If style is set to one of the builtin styles such as 'platinum' problem does not occur. Attached script demonstrates the problem; when the script is run as is within a KDE desktop, using a KDE-specific theme, we got the following error: TypeError: qt.QStyle represents a C++ abstract class and cannot be instantiated Traceback (most recent call last): File style_test.py, line 10, in drawButton self.style().drawControl(QStyle.CE_PushButton, painter, self, On the other hand, if line 38 is uncommented out to set a built-in style, it works flawlessly. In both cases, using PyQt-3.14.1 and SIP-4.2.1 gives no errors. Should be fixed in the next SIP snapshot. Thanks, Phil ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [review] Re: [PyKDE] PyKDE and KDE 3.4.0
On Apr 8, 2005 1:19 AM, Jim Bublitz [EMAIL PROTECTED] wrote: On Thursday 07 April 2005 14:25, Karsten Vieth wrote: Trying to install PyKDE with KDE 3.4.0 kdesu Traceback (most recent call last): File importTest.py, line 19, in ? exec (import + mod) File string, line 1, in ? ImportError: /usr/lib/python2.3/site-packages/kdesu.so: undefined symbol: _ZN7KCookie16setDcopTransportERK8QCString 2. You can use c++filt to identify the missing symbol: [EMAIL PROTECTED]:~ c++filt _ZN7KCookie16setDcopTransportERK8QCString KCookie::setDcopTransport(QCString const) Find the .sip file in PyKDE/sip/kdesu that holds the KCookie class and comment out the setDcopTransport(QCString const) method (// or /* ... */). I found setDcopTransport(QCString const) in ./sip/kdesu/kcookie.sip Comment it out //void setDcopTransport (const QCString); configured and compiled but nothing changes: kdesu Traceback (most recent call last): File importTest.py, line 19, in ? exec (import + mod) File string, line 1, in ? ImportError: /usr/lib/python2.3/site-packages/kdesu.so: undefined symbol: _ZN7KCookie16setDcopTransportERK8QCString ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] keypressevent + qdatedit
i try it and don't work self.lineEdit1.keyPressEvent = self.lineEdit_KeyPress El vie, 08-04-2005 a las 01:31 +0200, Torsten Marek escribió: self.lineEdit1.keyPressEvent = self.lineEdit_KeyPress ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[PyKDE] crashes in eric/python
The latest snapshots of eric are crashing for me when I try and use eric to debug any script. I have been looking into it today and have found what the culprit appears to be. I am going to provide a snippet of code to explain what I am seeing and see if there is anyone has any thoughts on what is going on. To begin with I am using the following versions: Python 2.3.3 Qt 3.2.2 PyQt3.8.1 OS Windows XP the particular crash I am seeing in Eric is I can launch eric, open a python script, then from the debug menu, select Debug script. The dialog opens to prompt for working directory etc., when I select ok, my python.exe that is running eric crashes on windows and eric disappears... With some probing and debugging, I have closed it down to what appears to be a garbage/memory collection issue in python, specifically in the latest eric snapshot in the code for the getData method of the StartDialog (in the eric source base it is in Debugger\StartDialog.py the current getData looks like: def getData(self): return (self.cmdlineCombo.currentText().replace(os.linesep, ), self.workdirCombo.currentText().replace(os.linesep, ), self.environmentCombo.currentText().replace(os.linesep, ), self.exceptionCheckBox.isChecked()) where self is the StartDialog which is a QDialog instance. cmdlineCombo is a QComboBox instance workdirCombo is a QComboBox instance environmentCombo is a QComboBox instance exceptionsCheckBox is a QCheckButton Anyway, when accessing any of the textdata from this returned tuple, the application crashes. In inspecting the data with the limited debug information I have, the basic problem is data seems to have been trashed/delete etc. Now if I change the above code to read as follows: def getData(self): cmdLine = self.cmdlineCombo.currentText() cmdLine = cmdLine.replace(os.linesep, ) workdir = self.workdirCombo.currentText() workdir.replace(os.linesep, ) environ = self.environmentCombo.currentText() environ.replace(os.linesep, ) return (cmdLine, workdir, environ, self.exceptionCheckBox.isChecked()) Then eric works just fine and I have no crashes. It seems I have to make the local python reference to the QString from currentText before trying to replace and return the reference to it. Does this make sense? I know we have somewhat old versions of qt/pyqt so could this have been something changed in the latest versions of qt/pyqt? Thanks in advance for any insight, -- Andrew Bushnell Lead Development Engineer Fluent Inc. 10 Cavendish Court Centerra Resource Park Lebanon, NH 03766 [EMAIL PROTECTED] Phone: 603-643-2600, ext. 757 Fax: 603-643-1721 www.fluent.com ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] QMessageBox, avoiding virtual desktop switching
Am Freitag, 8. April 2005 20:38 schrieb Alfred Young: I'm having a bit of trouble here, I've got a Qt prog that runs in the background and I consistently work in other desktops. However, when QMessageBox shows, the virtual desktop automatically switches to the originating desktop. Is there a way to prevent this from happening? That certainly is a behaviour created by your windowmanager - which one do you use? I e.g. use KDE, and new windows are communicated by flashing their tag in the windowlist in my panel. So go and try to reconfigure your WM. Diez ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[PyKDE] QPEApplication complains about ZCS file
I started using QPEApplication rather than QApplication to integrate my application in Qtopia. The first problem that I had was a complaint that there was no libsl.qmid file. I figured out that this file is related to internationalization. I created a trivial .pro file and ran pylupdate on it to produce an empty .ts. Then I ran lrelease on the .ts to produce a .qm. I renamed it libsl.qmid and put it in the right place. The complaint disappeared. However, in its place, I am now getting the complaint it seems this file is not ZCS file. This one has me stumped as I can find no reference to ZCS files in the Qt-interest mailing list, this group, or a blanket Google search. Any suggestions? -- Jeffrey Barish ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde