Hi, I have a QImage as a QGraphicsItem inside a QGraphicsView. I want to apply a 2 px border to this image(graphics item.). Is there a way to apply a stylesheet to this QGraphicsItem?
Is there a way to apply a stylesheet to this QGraphicsItem?
no. QSS is only available to QtWidgets
You have to draw the border yourself (maybe place the pixmap item inside a custom QGraphicsRectItem - which draws the border).
you should be able to do so by overriding the
QRectF boundingRect() constfunction. Just call the base function to get the current rect., and