Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-92016

High DPI, bad SVG quality, wrong screen selected for current window

    XMLWordPrintable

Details

    • Windows
    • 8f539ac85 (dev), e4d533eb1 (6.7)

    Description

      On Windows 10 with two 1080p screens, one scaled at 100% and the other one at 125% (the primary screen is 125%), the main window does not seem to attach to the appropriate screen depending on its position.

      This results in a bad quality rendering, applying the wrong pixel ratio for the current screen (see "Capture.png" for the bad quality and "Capture2.png" for the right quality when I move my window to the primary screen scaled at 125%).

      From what I can see, the selected display when I manually call screen() from my widget is wrong, the main window should be on DISPLAY2

       

      Don't hesitate to ask me any details, I tried to include what I have in hands but I can provide more if you can point me to something of interest.

       

      ==== Screen returned by screen() =====
      		this	@0x185046f5340	QScreen
      			[QObject]	@0x185046f5340	QObject
      				[vptr]	__vfptr	 
      				d_ptr	@0x185046f53c0	QScopedPointer<QObjectData>
      					[QObjectPrivate]	@0x185046f53c0	QObjectPrivate
      						[QObjectData]	@0x185046f53c0	QObjectData
      						connections	@0x18504709e20	QAtomicPointer<QObjectPrivate::ConnectionData>
      						currentChildBeingDeleted	0x0	QObject*
      						declarativeData	0x0	QAbstractDeclarativeData*
      						extraData	0x0	QObjectPrivate::ExtraData*
      						sharedRefcount	@0x185046f54f0	QAtomicPointer<QtSharedPointer::ExternalRefCountData>
      						threadData	@0x18504681a50	QAtomicPointer<QThreadData>
      					120.0	120.0	std::pair<double,double>
      						first	120.0	double
      						second	120.0	double
      					availableGeometry	1536x824+0+0	QRect
      					geometry	1536x864+0+0	QRect
      					orientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      					platformScreen	@0x185046f4cc0	QWindowsScreen
      						[QPlatformScreen]	@0x185046f4cc0	QPlatformScreen
      						m_cursor	@0x185046f50e0	QScopedPointer<QPlatformCursor>
      						m_data	@0x185046f4cd0	QWindowsScreenData
      							120.0	120.0	std::pair<double,double>
      								first	120.0	double
      								second	120.0	double
      							availableGeometry	1920x1030+0+0	QRect
      							depth	32	int
      							flags	3	unsigned int
      							format	Format_RGB32 (4)	QImage::Format
      							geometry	1920x1080+0+0	QRect
      							hMonitor	0x20034	HMONITOR__*
      							name	"\\.\DISPLAY1"	QString
      							orientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      							physicalSizeMM	(344.0, 193.0)	QSizeF
      							refreshRateHz	60.0	double
      					primaryOrientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      					refreshRate	60.0	double	
          
      ====== Screen list =======> The following is "\\\\.\\DISPLAY1", the primary screen scaled at 125%
      	screens	<2 éléments>	QList<QScreen *>
      			[0]	@0x223f3470f20	QScreen
      				[QObject]	@0x223f3470f20	QObject
      					[vptr]	__vfptr	 
      					d_ptr	@0x223f3470fa0	QScopedPointer<QObjectData>
      						[QObjectPrivate]	@0x223f3470fa0	QObjectPrivate
      						120.0	120.0	std::pair<double,double>
      							first	120.0	double
      							second	120.0	double
      						availableGeometry	1536x824+0+0	QRect
      						geometry	1536x864+0+0	QRect
      							x1	0	int
      							y1	0	int
      							x2	1535	int
      							y2	863	int
      						orientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      						platformScreen	@0x223f34708a0	QWindowsScreen
      						primaryOrientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      						refreshRate	60.0	double
      					staticMetaObject		<Value unavailable error>
      				staticMetaObject		<Value unavailable error>
                      
      => The following is "\\\\.\\DISPLAY2", the current screen my window is on			[1]	@0x223f3471530	QScreen
      				[QObject]	@0x223f3471530	QObject
      					[vptr]	__vfptr	 
      					d_ptr	@0x223f34715b0	QScopedPointer<QObjectData>
      						[QObjectPrivate]	@0x223f34715b0	QObjectPrivate
      						96.0	96.0	std::pair<double,double>
      							first	96.0	double
      							second	96.0	double
      						availableGeometry	1920x1040-1920+0	QRect
      						geometry	1920x1080-1920+0	QRect
      							x1	-1920	int
      							y1	0	int
      							x2	-1	int
      							y2	1079	int
      						orientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      						platformScreen	@0x223f34711e0	QWindowsScreen
      						primaryOrientation	LandscapeOrientation (2)	Qt::ScreenOrientation
      						refreshRate	60.0	double
      					staticMetaObject		<Value unavailable error>
      				staticMetaObject	<inaccessible>	<Value unavailable error>
      					[0]		
      		session	<optimized out>	
      		this	@0x22395194b30	SongDetailsWidget
      

      Attachments

        1. Capture.PNG
          Capture.PNG
          0.9 kB
        2. Capture2.PNG
          Capture2.PNG
          1 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            sorvig Morten Sørvig
            pierre31 Pierre
            Veli-Pekka Heinonen Veli-Pekka Heinonen
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes