I have a QGraphicsView and a QGraphicsItem that added to graphicsView's scene. I override QGraphicsView wheelEvent to do scale view, but i want my graphics item width does not change.
For this purpose i set cosmetic true for pen in graphics item paint function. it is work fine but after some scale in (zoom), cosmetic feature does not work and graphics item width begins to grow up for more zoom (like cosmetic set to false) when i setup setViewport(new QGLWidget) in MyGraphicsView.
Scale code is like so:
Graphics item override paint function is like so: