Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 1759259

Summary: Qt5 popup menus misplaced or missing
Product: [Fedora] Fedora Reporter: Dima Ryazanov <dima>
Component: qt5-qtwaylandAssignee: Jan Grulich <jgrulich>
Status: ASSIGNED --- QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 34CC: awilliam, jgrulich, jreznik, kde-sig, lkundrak, pierluigi.fiorini, rdieter, than
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-11-24 17:38:23 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1965576    
Attachments:
Description Flags
Screenshot none

Description Dima Ryazanov 2019-10-07 17:46:11 UTC
Created attachment 1623290 [details]
Screenshot

Description of problem:
When using Wayland and a multi-monitor setup, Qt5 does not place popup menus correctly - they're displayed at an offset, or missing completely if the offset would make it appear outside of the parent window.
Gtk+ used to have the exact same problem: it would try to calculate the popup position based on the parent window coordinates and screen dimensions - but Wayland does not expose window coordinates. I'm guessing Qt5 is doing the same thing.
The bug has probably always been there - but Qt5 didn't use Wayland by default until Fedora 31.

Version-Release number of selected component (if applicable):
qt5-qtwayland-5.12.5-1.fc31.x86_64

How reproducible:
Depends on the window location, but for a given location, happens consistently

Steps to Reproduce:
1. Make sure you have multiple monitors side by side
2. Open /usr/lib64/qt5/examples/widgets/richtext/textedit/textedit on the monitor to the right
3. Right-click the text or open File/Edit/etc. menus

Actual results:
Popup menu is shifted to the right

Expected results:
Popup menu should work as usual

Additional info:

Comment 1 Jan Grulich 2019-10-08 05:03:22 UTC
This is unfortunately a known regression in qtwayland, see [1] and fixing this properly requires significant amount of work. This can be workarounded on per-app basis, but it's not probably what we want to do for every application.

[1] - https://bugreports.qt.io/browse/QTBUG-68636

Comment 2 Ben Cotton 2020-11-03 17:04:18 UTC
This message is a reminder that Fedora 31 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 31 on 2020-11-24.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '31'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 31 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 3 Ben Cotton 2020-11-24 17:38:23 UTC
Fedora 31 changed to end-of-life (EOL) status on 2020-11-24. Fedora 31 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 4 Jan Grulich 2021-07-15 10:58:45 UTC
*** Bug 1900838 has been marked as a duplicate of this bug. ***