Top "Qgraphicsitem" questions

The QGraphicsItem class is the base class for all graphical items in a QGraphicsScene.

Can I get mouse events in a QGraphicsItem?

I have subclassed QGraphicsRectItem, and it's not receiving any mouse events. I've seen other questions similar to this say I …

qt qgraphicsview qgraphicsitem qmouseevent
QGraphicsScene::clear() clearing scene but not the view

I use a custom class (Configuration) derived from QGraphicsItem and I add its objects to a QGraphicsScene, which is then …

qt debugging qgraphicsview qgraphicsitem qgraphicsscene
Find screen position of a QGraphicsItem

Use case: This should be a fairly common problem. In a normal QMainWindow with QMdiArea lives an mdiChild with a …

c++ qt position viewport qgraphicsitem
Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call

I created a simple program that demonstrates the runtime error I'm getting with my Qt application that uses multiple inheritance. …

c++ visual-studio qt multiple-inheritance qgraphicsitem
Selection of items in QGraphicsScene

I am trying to understand how it is possible to redefine the way items are selected and transformed (once selected) …

qt selection qgraphicsitem
Drawing widgets (such as buttons) over QGraphicsView

How do I draw interactive widgets such as QButtons and Line Edits over a QGraphicsView? For ex, I have selected …

qt qgraphicsview qgraphicsitem
QGraphicsItem doesn't receive mouse hover events

I have a class derived from QGraphicsView, which contains QGraphicsItem-derived elements. I want these elements to change color whenever the …

c++ qt events qgraphicsview qgraphicsitem
Qt: resize a QGraphicsItem (boundingRect()) into a QGraphicsScene with the mouse

I would like to resize the boundingRect() of my QGraphicsItem using the mouse. To build this I found this topic. …

c++ qt resize mouseevent qgraphicsitem
QT: trouble with qobject_cast

I have derived QGraphicsItem and QGraphicsScene classes. I want the items to be able to call scene() and get a …

qt casting qgraphicsitem
Qt GraphicsView stretch scene to fit

Ok, so I am using Qt and C++ as my environment. I draw out a QGraphicsView in my UI. I …

c++ qt qgraphicsitem