Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.12
-
None
-
PyQt5
Description
Hi,
It comes to my attention that it seems that sometimes Qt fails to trigger hoverEnter/hoverLeave event for nested Widgets in a QGraphicsScene.
This problem can be easily reproduced in this open-source project.
https://gitlab.com/pavel.krupala/pyqt-node-editor
There is an example_test demo in it.
By moving the cursor in and out the socket region, you will notice that sometime the cursor turns into a cross style cursor. While sometimes, it fails to do so because the hoverEnter event is not properly triggered.
The exact same problem can be reproduced in this open-source project too.
https://github.com/jchanvfx/NodeGraphQt
There is an example in the root folder named example.py. Hovering on and off the checkbox in the node can easily reveal the problem.
Someone also demonstrated the problem here in this twitter
https://twitter.com/Jiayin_Cao/status/1407747807381884932
This existed Jira ticket seems to mention the same thing, which was fixed in version 4.6.0.
https://bugreports.qt.io/browse/QTBUG-4339?jql=text%20~%20%22hoverEnter%22
But it looks like the bug is back in PyQt5.
Alexis Menard may know more about it and his fix on this issue.
Thanks