Details
-
Bug
-
Resolution: Out of scope
-
P2: Important
-
None
-
5.12.0
Description
Adding a qt.conf with dpiawareness=1 changes the behavior of QMenu when a dockwidget is moved to a different screen.
Expected behavior:
QMenu should be below the toolbar at all times. Please see the image expected.png
Actual behavior:
QMenu is entirely detached from the toolbar and outside the MainWindow, positioned towards the upper right or left corner of the screen. Please see the image actual.png.
Steps to reproduce the issue:
- Build the Dock Widgets example
- Add qt.conf with dpiawareness=1 (See attachment: qt.conf)
- Run Dock Widgets example
- Move either of the dock widgets to a different screen
- Click on any QToolbar
Observations:
The actual position of the QMenu seems to remain relative to the MainWindow. The QMenu may appear on the upper right or left corner of the screen and this seems to be dependent on whether a dockwidget was moved to a screen on left or right respectively.
The QMenus returns to normal after the dockwidget is moved back to the same screen and the MainWindow is moved a bit.
Additionally, the buttons on the drop down can be clicked on both their expected position (right under the toolbar) and where the QMenu is actually displayed.
This bug has been reproduced with:
- 3 screen setup: 2560 x 1440 (200%), 3840 x 2160 (200%), 1600 x 1200 (100%)
- 2 screen setup: 2560 x 1600 (100%) and 2160 x 3840 (150%).
Attachments
Issue Links
- is duplicated by
-
QTBUG-70457 Windows 10: Incorrect position of menu drop down when Qt HiDPI support is disabled at dpiawareness 1,0
- Closed