[PyKDE] [PATCH] Features

2006-05-02 Thread Michael 'Mickey' Lauer
Attached is a patch that I need to get PyQt4 compiled against a lean-and-mean Qt4, where we disable some features to minimize its size for our embedded targets. It may not be complete, but it works for the following configuration: QT_CONFIG_FLAGS = -release -shared -qt-zlib -system-libjpeg

Re: [PyKDE] [PATCH] Features

2006-05-02 Thread Phil Thompson
On Tuesday 02 May 2006 12:40 pm, Michael 'Mickey' Lauer wrote: Attached is a patch that I need to get PyQt4 compiled against a lean-and-mean Qt4, where we disable some features to minimize its size for our embedded targets. It may not be complete, but it works for the following configuration:

Re: [PyKDE] Killing QApplication

2006-05-02 Thread Giovanni Bajo
Paul Waldo wrote: I'm trying to be a good boy, so I have a lot of unit tests for my python KDE application. Each of the tests run fine individually, but when I run them all together, it seems that the application refuses to die. The first test runs fine, but then subsequent tests give this

Re: [PyKDE] subclassing QAbstractListModel

2006-05-02 Thread Phil Thompson
On Tuesday 02 May 2006 5:59 pm, Tom Brown wrote: I am subclassing QAbstractListModel and getting an error in __init__(). Here is the code where I receive the error: class StringsModel(QAbstractListModel): def __init__(self, strings, parent=None): QAbstractListModel.__init__(parent)

Re: [PyKDE] subclassing QAbstractListModel

2006-05-02 Thread Andy Davidoff
What are you missing? Only this: QAbstractListModel.__init__(self, parent) On May 2, 2006, at 12:59 PM, Tom Brown wrote: QAbstractListModel.__init__(parent) ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de

Re: [PyKDE] subclassing QAbstractListModel

2006-05-02 Thread Tom Brown
On Tuesday 02 May 2006 10:13, Andy Davidoff wrote: What are you missing? Only this: QAbstractListModel.__init__(self, parent) Doh! That was stupid (sigh). Thanks for pointing that out. ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de

[PyKDE] QComboBox full but box is empty

2006-05-02 Thread Tom Brown
I have a QComboBox on my main window. I fill it with items using a model. I see the items in the drop down list. However, when I select an item, it does not show up in the box. When I call setCurrentIndex(0) the item at index 0 does not show up in the box. What am I doing wrong? Here is how I

Re: [PyKDE] QComboBox full but box is empty [SOLVED]

2006-05-02 Thread Tom Brown
My problem was solved by modifying the data() method of the StringsModel. This method needs to check for the EditRole as well as the DisplayRole as shown below. if role in [Qt.DisplayRole, Qt.EditRole]: return QVariant(self.strings[index.row()]) Thanks, Tom

[PyKDE] QComboBox signals

2006-05-02 Thread Tom Brown
I have connected just about all the signals of the QComboBox to a method in my main window. However, none of these methods are getting called. The combo box acts normally otherwise. Here is how I connect a signal: self.connect(self.ui.modelCB, SIGNAL('editTextChanged(const QString text)'),

Re: [PyKDE] QComboBox signals [SOLVED]

2006-05-02 Thread Tom Brown
On Tuesday 02 May 2006 18:07, Tom Brown wrote: self.connect(self.ui.modelCB, SIGNAL('editTextChanged(const QString text)'), self.modelChanged) Doh! This was another stupid mistake. I just had to remove the argument name from the signal so it looks like this: self.connect(self.ui.modelCB,