Menu

#357 QwtPlotOpenGLCanvas devicePixelRatio Qt6

None
closed
None
5
2022-12-12
2022-11-11
peppermg
No

When using QwtPlotOpenGLCanvas if you have multiple screens with different resolutions and drag a plot from one screen to another the canvas will become offset. This behavior can be seen in the refreshtest example (screenshots attached). This issue was discovered after porting a project from Qt5.15.2 to Qt6.4, issue does not appear to happen in Qt5.

changing

const qreal pixelRatio = QwtPainter::devicePixelRatio( NULL );

to

const qreal pixelRatio = QwtPainter::devicePixelRatio( this );

in QwtPlotOpenGLCanvas::paintGL() appears to fix the issue

2 Attachments

Discussion

  • Uwe Rathmann

    Uwe Rathmann - 2022-12-12
    • status: open --> closed
    • Group: -->
     
  • Uwe Rathmann

    Uwe Rathmann - 2022-12-12

    Of course you are right. Fixed in all branches >= 6.2

     

Anonymous
Anonymous

Add attachments
Cancel