Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 5

Qt-interest Archive, April 2007
Drawing in a pixmap


Message 1 in thread

Hey guys,

I'm trying to paint in a Pixmap to generate an icon :

QPixmap pixmap(rect.x(), rect.y());

QPainter painter(&pixmap);

DrawRadialSphere(painter, rect, status);

QIcon icon(pixmap);



for some reason, I have the following error :

QPainter::begin : Pain device returned engine == 0, type == 2.

And the drawing doesn't seem to work, any idea ?

Ben.

Message 2 in thread

bunjee schrieb:
> ...
> QPixmap pixmap(rect.x(), rect.y());

What's the value of x() and y()? Are you sure you don't mean width() and
height() instead?

Cheers, Oliver

--
 [ signature omitted ] 

Message 3 in thread

Oh man,

Thank you very much...
Too much coding kills the coding.

----- Original Message ----- 
From: "Till Oliver Knoll" <oliver.knoll@xxxxxxxxxxx>
To: "Qt Interest List" <qt-interest@xxxxxxxxxxxxx>
Sent: Tuesday, April 17, 2007 5:07 PM
Subject: Re: Drawing in a pixmap


> bunjee schrieb:
>> ...
>> QPixmap pixmap(rect.x(), rect.y());
>
> What's the value of x() and y()? Are you sure you don't mean width() and
> height() instead?
>
> Cheers, Oliver
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with 
> "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
>
> 

--
 [ signature omitted ]