Detect click event (signal?) of QGraphicsSvgItem



  • I'm new to Qt. How can I capture click events/signals of a QGraphicsSvgItem inside a QGraphicsScene? I have the following code:

    @
    QGraphicsScene *scene = new QGraphicsScene(this);
    QGraphicsSvgItem *svgItem = new QGraphicsSvgItem(":/SomeGraphic.svg");
    svgItem->scale(0.1, 0.1);
    svgItem->setPos(-200,-200);
    scene->addItem(svgItem);
    @

    Is it possible to connect() the click() signal of svgItem to a slot?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.