Re: [PyQt] How to insert a picture

2012-01-05 Thread Fabien Lafont
t; > - Mail original - > De: "Fabien Lafont" > À: pyqt@riverbankcomputing.com > Envoyé: Jeudi 5 Janvier 2012 10:57:18 > Objet: [PyQt]  How to insert a picture > > Hello, > > I'm trying to insert a picture in PyQt. I've tried > > LED = QLabel.setPixmap(QPixma

Re: [PyQt] How to insert a picture

2012-01-05 Thread daitheflu
Hi Fabien, I think you'll need a QLabel instance : led = QLabel() led.setPixmap(QPixmap("LED_ON.PNG") Should do the job. Cheers, -- François - Mail original - De: "Fabien Lafont" À: pyqt@riverbankcomputing.com Envoyé: Jeudi 5 Janvier 2012 10:57

Re: [PyQt] How to insert a picture

2012-01-05 Thread Matteo Bertozzi
On Thu, 2012-01-05 at 10:57 +0100, Fabien Lafont wrote: > Hello, > > I'm trying to insert a picture in PyQt. I've tried > > LED = QLabel.setPixmap(QPixmap("LED_ON.PNG")) > > but it returns: > > LED = QLabel.setPixmap(QPixmap("LED_ON.PNG")) > TypeError: QLabel.setPixmap(QPixmap): first argument

[PyQt] How to insert a picture

2012-01-05 Thread Fabien Lafont
Hello, I'm trying to insert a picture in PyQt. I've tried LED = QLabel.setPixmap(QPixmap("LED_ON.PNG")) but it returns: LED = QLabel.setPixmap(QPixmap("LED_ON.PNG")) TypeError: QLabel.setPixmap(QPixmap): first argument of unbound method must have type 'QLabel' Any Idea? ___