> Probably, you have messed up with screenPos() and scenePos() methods
> of QGraphicsSceneMouseEvent class? Please, double check your test code.
You're right. I really used screenPos instead of scenePos at one place...
Thank you for the hint!
Alexander
___
As for me the output of the code below is as expected when placed into
QGraphicsItem::mousePressEvent():
qDebug() << "scene:" << event->scenePos();
qDebug() << "map to scene:" << mapToScene(event->pos());
qDebug() << "local:" << event->pos();
qDebug() << "map to local:" << mapFromS
Hi Dima,
> are talking about screen or scene coordinates?
I meant sceenPos() of course...
Alexander
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest
Alexander,
are talking about screen or scene coordinates? I don't see any
screen-related map-functions among the list of QGraphicsItem class' members.
Regards,
Dmitrii.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailma
Hi,
I'm having here a problem with mapFrom/mapTo-functions. In a class derived
from QGraphicsItem I override mousePressEvent and I get for
mapFromScreen(event->screenPos()) a point that is different from event->pos().
Similarly, mapToScreen(event->pos()) doesn't lead to event->screenPos(). Why?