So i trying to do paint and i run into some problems. When i try to draw QGraphicsRectItem it doesnt get positioned where i want it.
QColor neki1(23, 145, 195);
QPen pen1(neki1, 2, Qt::DashLine, Qt::RoundCap, Qt::RoundJoin);
QGraphicsRectItem* sel = new QGraphicsRectItem(0,0,100,100);
sel->setPen(pen1);
sel->setBrush(Qt::transparent);
addItem(sel);
this is the code and picture and you can see it get position like somewhere in the middle of the screen. On the begining of the program i set scene->setSceneRect(QRectF(0, 0, 1000, 1000));
but cordinates in top left corner of scene are not 0,0. Is there anyway to solve this?
Thank you for your help.