[PyKDE] pyuic + images + listItems
Hans-Peter Jansen
hpj at urpla.net
Sat Apr 12 17:23:00 BST 2003
Hi Petr,
it's a well known problem, fixed in current snapshots or wait for
the 3.6 release.
Hth,
Pete
On Saturday 12 April 2003 15:19, Petr Vaněk wrote:
> hello.
>
> I've got this problem after calling pyuic on UI xml file:
>
> ---BOF---
> ...
> image0_data = blahblah...
>
> class Blah(blahblah...):
>
> def __init__(self,parent = None,name = None,modal = 0,fl = 0):
> QDialog.__init__(self,parent,name,modal,fl)
>
> image0 = QPixmap(image0_data)
>
> def languageChange(self):
> ...
> self.listBox.insertItem(image0,self.tr("Common"))
> ...
> ---EOF--
>
> But python scream (logically :D) about "NameError: global name
> 'image0' is not defined" in languageChange method.
> Is it pyuic bug or did I something wrong? (writing self.image0 after
> each pyuicing isn't comfortable :))
>
> best regards
More information about the PyQt
mailing list