[prev in list] [next in list] [prev in thread] [next in thread]
List: pykde
Subject: Re: [PyQt] Bug - Context menus not refreshing properly on pyqt5.14.x
From: BPL <spscener84 () gmail ! com>
Date: 2020-03-31 23:35:47
Message-ID: CAAfY3fb+=aAw8kq=YTww5E6ZgGB1Qg2TqtBiUxOqjjd7xsiDuQ () mail ! gmail ! com
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
In addition to my previous mail I've made couple of more tests... I've
decided to create new wheels using pyqt-bundle with qtbase version 5.14.2
and (5.15.0 beta - the one that contained this suspicious commit
https://github.com/qt/qtbase/commit/8f88a3962a )
On both attempts this bug was still present so I give up for now... if you
know if this bug has been solved please let me know the commit hash and
I'll give it a shot.
On Tue, Mar 31, 2020 at 4:59 PM BPL <spscener84@gmail.com> wrote:
> There is a really nasty bug related to context menu refreshing with
> versions 5.14.0, 5.14.1, please take a look:
>
> - On versions 5.13.0, 5.13.1, 5.13.2 there is NO bug, demo here
> <https://dl.dropboxusercontent.com/s/0q29e06om06an2i/2020-03-31_16-51-23.mp4>
> - On versions 5.14.0, 5.14.1 there IS a bug, demo here
> <https://dl.dropboxusercontent.com/s/qjg38hy4cxy4ukp/2020-03-31_16-55-00.mp4>
>
> Mcve below:
>
> from PyQt5.Qt import *
>
> if __name__ == '__main__':
> app = QApplication([])
>
> x = QTreeWidget()
> x.setContextMenuPolicy(Qt.CustomContextMenu)
> i1 = QTreeWidgetItem(x, ["A"])
> i2 = QTreeWidgetItem(i1, ["bar", "i", "ii"])
> i3 = QTreeWidgetItem(i2, ["baz", "a", "b"])
>
> def callback(point):
> menu = QMenu()
> menu.addAction("Foo")
> menu.addSeparator()
> menu.addAction("Bar")
> menu.exec_(x.mapToGlobal(point))
>
> x.customContextMenuRequested.connect(callback)
> x.show()
> app.exec_()
>
> I've tested this on windows7 / python3.6.2.
>
> Could you please confirm/advice? I would really like to upgrade my apps to
> >5.14 :/
>
[Attachment #5 (text/html)]
<div dir="ltr">In addition to my previous mail I've made couple of more tests... \
I've decided to create new wheels using pyqt-bundle with qtbase version 5.14.2 \
and (5.15.0 beta - the one that contained this suspicious commit <a \
href="https://github.com/qt/qtbase/commit/8f88a3962a">https://github.com/qt/qtbase/commit/8f88a3962a</a> \
)<div><br></div><div>On both attempts this bug was still present so I give up for \
now... if you know if this bug has been solved please let me know the commit hash and \
I'll give it a shot.</div><div><br></div><div><br></div><div><br></div><div><br></div></div><br><div \
class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Mar 31, 2020 at 4:59 PM \
BPL <<a href="mailto:spscener84@gmail.com">spscener84@gmail.com</a>> \
wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px \
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">There \
is a really nasty bug related to context menu refreshing with versions 5.14.0, \
5.14.1, please take a look:<div><br></div><div>- On versions 5.13.0, 5.13.1, 5.13.2 \
there is NO bug, demo <a \
href="https://dl.dropboxusercontent.com/s/0q29e06om06an2i/2020-03-31_16-51-23.mp4" \
target="_blank">here</a></div><div>- On versions 5.14.0, 5.14.1 there IS a bug, demo \
<a href="https://dl.dropboxusercontent.com/s/qjg38hy4cxy4ukp/2020-03-31_16-55-00.mp4" \
target="_blank">here</a></div><div><br></div><div>Mcve \
below:</div><div><br></div><div>from PyQt5.Qt import *<br><br>if __name__ == \
'__main__':<br> app = QApplication([])<br><br> x = \
QTreeWidget()<br> x.setContextMenuPolicy(Qt.CustomContextMenu)<br> i1 = \
QTreeWidgetItem(x, ["A"])<br> i2 = QTreeWidgetItem(i1, \
["bar", "i", "ii"])<br> i3 = QTreeWidgetItem(i2, \
["baz", "a", "b"])<br><br> def \
callback(point):<br> menu = QMenu()<br> \
menu.addAction("Foo")<br> menu.addSeparator()<br> \
menu.addAction("Bar")<br> \
menu.exec_(x.mapToGlobal(point))<br><br> \
x.customContextMenuRequested.connect(callback)<br> x.show()<br> \
app.exec_()<br></div><div><br></div><div>I've tested this on windows7 / \
python3.6.2.</div><div><br></div><div>Could you please confirm/advice? I would really \
like to upgrade my apps to >5.14 :/</div></div> </blockquote></div>
[Attachment #6 (text/plain)]
_______________________________________________
PyQt mailing list PyQt@riverbankcomputing.com
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic