Hi,

I'm working on some examples for PyQt at the moment, and using the QListView, 
I found some "strange" things which look like bugs to me.

if self.listview.childCount() == 0: # AttributeError
        self.deletebutton.setEnabled(False)

The childCount is - although documented [0] - not a method of the QListView 
(not in dir(self.listview), if I insert it.

Attached, you find the small program I've encountered this issue with.

[0] http://doc.trolltech.com/3.3/qlistview.html#childCount

I'm running Debian sid with:

ii  python-qt-dev  3.14.1-2       Qt bindings for Python - Development files
ii  python-qt3     3.14.1-2       Qt3 bindings for Python (default version)
ii  python-qt3-doc 3.14.1-2       Qt bindings for Python - Documentation and e
ii  python-qtext   3.14.1-2       Qt extensions for PyQt (default version)

I'm at aKademy at the moment, and don't have my other machine at hand.

- Is that a bug?
- Is it already fixed in snapshots?
- Is there a better way to count the listviewitems?

Thanks for your enlightening,
-- 
sebas

 http://www.kde.nl | http://vizZzion.org |  GPG Key ID: 9119 0EF9 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
A day without sunshine is like a day without orange juice.

Attachment: testapp.py
Description: application/python

Attachment: testapp_ui.py
Description: application/python

Attachment: pgpz5IRZNedud.pgp
Description: PGP signature

_______________________________________________
PyKDE mailing list    [email protected]
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

Reply via email to