QGraphicsPixmapItem not selectable
问题 I want my QGraphicsPixmapItem become selectable (i.e. clickable in more general way) on QGraphicScene but it doesn't. I'm actually modifying Qt 's Diagram Scene sample, where QGraphicsItem 's subclass is used and is selectable. I appreciate your help. cpp code (partial): #include <iostream> #include <QtGui> #include "overlayPixmapItem.h" OverlayPixmapItem::OverlayPixmapItem(DiagramType diagramType, QMenu *contextMenu, QPixmap img, QGraphicsItem *parent, QGraphicsScene *scene) :