QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Marko Luther
Mac OS X 10.13.3 , Python 3.5.4, Qt 5.10.1 / PyQt 5.10.1 installed via PIP "PyQt5"
With the attached script resizing works for Windows, but not for any other of the options incl. QDialog.

I downgraded to PyQt 5.10.0 and with the same code the QDialog resizes again as expected.

Any idea? Is this a Qt problem?

Thanks,
Marko


_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt

test.py (11K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Barry Scott


> On 6 Mar 2018, at 10:09, Marko Luther <[hidden email]> wrote:
>
> Mac OS X 10.13.3 , Python 3.5.4, Qt 5.10.1 / PyQt 5.10.1 installed via PIP "PyQt5"
> With the attached script resizing works for Windows, but not for any other of the options incl. QDialog.
>
> I downgraded to PyQt 5.10.0 and with the same code the QDialog resizes again as expected.
>
> Any idea? Is this a Qt problem?

I read the code, did not run it.

Why do you need to check pos and move the window? Seems odd.

You have platform specific flags that you reference. I would conditionalise the platform specific code to avoid surprises. E.g. windows flags on mac os x, etc.

Also why don’t your or the flags together if more the one check box is set?

Barry
>
> Thanks,
> Marko
>
> <test.py>
> _______________________________________________
> PyQt mailing list    [hidden email]
> https://www.riverbankcomputing.com/mailman/listinfo/pyqt

_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Hans-Peter Jansen-2
In reply to this post by Marko Luther
On Dienstag, 6. März 2018 11:09:35 Marko Luther wrote:
> Mac OS X 10.13.3 , Python 3.5.4, Qt 5.10.1 / PyQt 5.10.1 installed via PIP
> "PyQt5" With the attached script resizing works for Windows, but not for
> any other of the options incl. QDialog.
>
> I downgraded to PyQt 5.10.0 and with the same code the QDialog resizes again
> as expected.
>
> Any idea? Is this a Qt problem?

Do I understand this correctly, you downgraded PyQt, but kept the Qt version?

And you're not using any hints, just switch the type?

Fiddling with these hints _is_ awful, since they're handled in different os
levels, some by Qt itself, some below, and they're highly system dependent.

On Linux (KDM), all types are resizable, but Popup, Tooltip and Splash.

Python: 3.4.5
Sip: 4.19.7
Qt5: 5.10.0
PyQt5: 5.10

Cheers,
Pete
_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Marko Luther
Dear Hans,

> On 7. Mar 2018, at 20:35, Hans-Peter Jansen <[hidden email]> wrote:
>
> On Dienstag, 6. März 2018 11:09:35 Marko Luther wrote:
>> Mac OS X 10.13.3 , Python 3.5.4, Qt 5.10.1 / PyQt 5.10.1 installed via PIP
>> "PyQt5" With the attached script resizing works for Windows, but not for
>> any other of the options incl. QDialog.
>>
>> I downgraded to PyQt 5.10.0 and with the same code the QDialog resizes again
>> as expected.
>>
>> Any idea? Is this a Qt problem?
>
> Do I understand this correctly, you downgraded PyQt, but kept the Qt version?

No, I actually uninstalled the PIP PyQt package with the included Qt and am running now PyQt/Qt 5.10.0 that works.

>
> And you're not using any hints, just switch the type?

Yes.

>
> Fiddling with these hints _is_ awful, since they're handled in different os
> levels, some by Qt itself, some below, and they're highly system dependent.

I did not wanted to fiddle with the. Just hope they would somehow make my dialogs resizable again. But they didn't.

>
> On Linux (KDM), all types are resizable, but Popup, Tooltip and Splash.
>
> Python: 3.4.5
> Sip: 4.19.7
> Qt5: 5.10.0
> PyQt5: 5.10

On Qt 5.10.0 PyQt 5.10 all my dialogs are resizable too. However, with the upgrade to 5.10.1 Qt/PyQt installed from PIP, they stopped to do so. Thanks for testing anyhow. Wonder why no one else is having this issue. Strange.

M

>
> Cheers,
> Pete
> _______________________________________________
> PyQt mailing list    [hidden email]
> https://www.riverbankcomputing.com/mailman/listinfo/pyqt

_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Hans-Peter Jansen-2
Hi Marko,

On Dienstag, 20. März 2018 10:30:10 Marko Luther wrote:
> Hm. Still wondering on this. Nobody else seeing this issue with PyQt 5.10.1
> on Mac OS X?
>
> Here is a simplified (trivial) scriopt that just opens a QDialog which is
> resizable under PyQt 5.10.0, but not under PyQt 5.10.1, running from a pip
> install on Python 3.5 as well as Python 3.6 on Mac OS X.
>
> Seems to be an issue only on Mac OS X.

With all these facts on hand, you should start discriminating the problem
domain ;-)

It is a Qt problem of course, but might be related to the PyQt Qt builds and
even macOS version dependent, given the latest macOS hiccups (to be polite..).

Hence, let us know about your macOS version.

I would build a similar C++ version of your test app and check with the PyQt
versions, e.g. install a Qt developer version, build the examples/test app,
check, if they work, reinstall the PyQt versions, and check again.

Good luck,
Pete

_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Hans-Peter Jansen-2
On Dienstag, 20. März 2018 13:40:07 Marko Luther wrote:
> Thanks Pete for your quick response, always running the latest macOS,
> Version 10.13.3 at the moment. I also thought this might be either a Qt bug
> or a change in behaviour, but couldn't really find any trace of this using
> my Googles.
>
> Wonder if  nobody else is using resizing QDialogs on Mac OS X with PyQt
> 5.10.1 and discovered that issue!?

Since there are a couple of ways to install PyQt5, mind sharing yours? (exact
steps)

> I'll try to  build a C++ variant (a language new to me),

No big deal as long as you have the development package installed.

$ cd whatever-example
$ qmake
$ make

run the result...

Cheers,
Pete

_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: QDialog (and others) not resizing on PyQt 5.10.1 PIP install

Hans-Peter Jansen-2
In reply to this post by Marko Luther
On Dienstag, 20. März 2018 10:30:10 Marko Luther wrote:
> Hm. Still wondering on this. Nobody else seeing this issue with PyQt 5.10.1
> on Mac OS X?
>
> Here is a simplified (trivial) scriopt that just opens a QDialog which is
> resizable under PyQt 5.10.0, but not under PyQt 5.10.1, running from a pip
> install on Python 3.5 as well as Python 3.6 on Mac OS X.
>
> Seems to be an issue only on Mac OS X.

I can confirm this behaviour on macOS 10.12. pip3 install PyQt5 shows this
issue, while pip3 install PyQt5==5.10 doesn't (Python 3.6.4).

The Qt tests are still relevant.

Cheers,
Pete

> Thanks for every hint on this,
> Marko
>
> --
> from PyQt5 import QtCore, QtGui, QtWidgets
>
> class PreviewWindow(QtWidgets.QDialog):
>     def __init__(self, parent=None):
>         super(PreviewWindow, self).__init__(parent)
>         self.textEdit = QtWidgets.QTextEdit()
>         self.textEdit.setReadOnly(True)
>         self.textEdit.setLineWrapMode(QtWidgets.QTextEdit.NoWrap)
>         closeButton = QtWidgets.QPushButton("&Close")
>         closeButton.clicked.connect(self.close)
>         layout = QtWidgets.QVBoxLayout()
>         layout.addWidget(self.textEdit)
>         layout.addWidget(closeButton)
>         self.setLayout(layout)
>         self.setWindowTitle("Preview")
>
> if __name__ == '__main__':
>     import sys
>     app = QtWidgets.QApplication(sys.argv)
>     preview = PreviewWindow()
>     preview.show()
>     sys.exit(app.exec_())
> --
>
> > On 7. Mar 2018, at 20:49, Marko Luther <[hidden email]> wrote:
> >
> > Dear Hans,
> >
> >> On 7. Mar 2018, at 20:35, Hans-Peter Jansen <[hidden email]> wrote:
> >>
> >> On Dienstag, 6. März 2018 11:09:35 Marko Luther wrote:
> >>> Mac OS X 10.13.3 , Python 3.5.4, Qt 5.10.1 / PyQt 5.10.1 installed via
> >>> PIP
> >>> "PyQt5" With the attached script resizing works for Windows, but not for
> >>> any other of the options incl. QDialog.
> >>>
> >>> I downgraded to PyQt 5.10.0 and with the same code the QDialog resizes
> >>> again as expected.
> >>>
> >>> Any idea? Is this a Qt problem?
> >>
> >> Do I understand this correctly, you downgraded PyQt, but kept the Qt
> >> version?>
> > No, I actually uninstalled the PIP PyQt package with the included Qt and
> > am running now PyQt/Qt 5.10.0 that works.>
> >> And you're not using any hints, just switch the type?
> >
> > Yes.
> >
> >> Fiddling with these hints _is_ awful, since they're handled in different
> >> os
> >> levels, some by Qt itself, some below, and they're highly system
> >> dependent.
> >
> > I did not wanted to fiddle with the. Just hope they would somehow make my
> > dialogs resizable again. But they didn't.>
> >> On Linux (KDM), all types are resizable, but Popup, Tooltip and Splash.
> >>
> >> Python: 3.4.5
> >> Sip: 4.19.7
> >> Qt5: 5.10.0
> >> PyQt5: 5.10
> >
> > On Qt 5.10.0 PyQt 5.10 all my dialogs are resizable too. However, with the
> > upgrade to 5.10.1 Qt/PyQt installed from PIP, they stopped to do so.
> > Thanks for testing anyhow. Wonder why no one else is having this issue.
> > Strange.
> >
> > M
> >
> >> Cheers,
> >> Pete
> >> _______________________________________________
> >> PyQt mailing list    [hidden email]
> >> https://www.riverbankcomputing.com/mailman/listinfo/pyqt
> >
> > _______________________________________________
> > PyQt mailing list    [hidden email]
> > https://www.riverbankcomputing.com/mailman/listinfo/pyqt
a
_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt