Am Mittwoch, 4. Februar 2015, 11:22:15 schrieben Sie:
> not sure how the graphicsitem comes into all of this, but no you cant draw
> on it.
Well, we use QGraphicsScene/View with QGraphicsItems. 

> you can draw on a QGraphicsWidget or you can derive from
> QGraphicsItem and draw in its paint() method.
The Curve-class is already derived from QGraphicsItem and I reimplement the 
paint()-function. As you suggested, I use the QPainter passed to this function 
to draw onto a QPixmap. Once I'm done with this I want to call 
painter->drawPixmap()  to draw on the QGraphicsItem...
Also, by making the painter to paint on the pixmap with painter.begin(&pixmap) 
I get the warning "QPainter is already active" - the painter is already 
initialized/prepared for the graphics item.

Any other ideas?

-- 
Alexander
_______________________________________________
Interest mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to