What happened to PyQt? Also, the API does not seem Pythonic at all.
I think PyQt is owned by a different company, so Nothing happened to it, I guess. PySide is waaaay more Pythonic than PyQt ever was. Types are actually translated to Python native types and APIs are way more Pythonic and not just translated 1:1 like PyQt.
Hello Qt for Python
81–90 of 176 posts
Re: Hello Qt for Python
#82Very happy to hear this as the author of a PyQt-based file manager [1] and an open source library for solving the many headaches that come with developing desktop apps [2]. Once Qt for Python is stable enough, I'll be happy to switch to it from PyQt. [1]: https://fman.io [2]: https://github.com/mherrmann/fbs
What would you recommend to someone who wants to write Python desktop applications today? I've used wxWindows way back when, and I'd hate to use Electron. Would you go with Qt for Python, or PyQT? Also, what's PySide/PySide2?
Re: Hello Qt for Python
#83Is is possible to use QML in a PyQt/PySide2 app? Using QML for interface and Python for logic would make perfect sense. But every PyQt article and tutorial I see is about QtWidgets.
Re: Hello Qt for Python
#84Earlier quoted context omitted.
Sorry, I thought it was generally accepted that Python's relationship with the GUI was troubled? Put in plain English it is like this. I write quite a lot of code that integrates various enterprise systems together. Things like EDI management, and 'brokers' between incompatible API's. It is usually a mixture of Python/Bash/SQL. It is not my full-time job to code, but I get things done. As complexity increased I learn…
> My Python head says this should look like this No, that's not "your python head", sorry, that's your "VB head" at best. That's lack of knowledge of how desktop GUI paradigms actually work and what an event loop is and how it interacts with threads. I do not disagree that VB (and Delphi) did a better job at hiding these concepts from the "just getting it done" crowd, but don't blame it on Python if you don't have a…
I'm not blaming it on Python, honestly. I'm just really surprised that there isn't a framework that will hide that stuff from me like VB did. You are a 100% correct in that I don't know anything about desktop GUI paradigms, or C++ GUI toolkits. I really don't have the bandwidth to find out either! I'm also surprised that I need to. I don't think that is even my VB head, I am a business systems person who has successful modeled a physical process in software. In a recent case I did all of the work negotiating with vendors/management/users, I found the bugs in the vendors API, and I did this to an absurd deadline (with almost zero budget) created by a a vendor withdrawing a product with no notice. That's the kind of absurd thing us plebs in the "just getting it done" crowd have to do all of the time. But I am finding that simple GUI launchers for my software are really complicated in Python with the frameworks I have found. I am shocked that this is the piece that is defeating me! As I said before, I could write a web front-end for this kind of thing relatively easily (in the above case it was a hardware requirement that lead me to try again at the desktop GUI). Perhaps this is why we see so many people looking at the web-app-on-the-desktop that is so derided on these pages?
Re: Hello Qt for Python
#85Earlier quoted context omitted.
The Python standard library itself also breaks the PEP8 naming convention in all the ways PyQt does so their decision really makes sense. If Python itself were consistent the trade-off would be different... I find PyQt to be Pythonic in all the ways that count, e.g. replacing `self.setFoo(bar)` with `self.foo = bar`, decorators for signals/slots, etc.
It does? Which library?
Re: Hello Qt for Python
#86I would love to hear more about this from the sages of HN. I really don't enjoy GUI development in Python. I am not a good enough CS to have the language to describe what is wrong, but I find it really hard to get Python GUI stuff to do what I want.
Retained-mode GUIs like Qt , wxWidgets, gtk, etc aren't intuitive. Try an immediate mode GUI, like my python bindings to nuklear https://github.com/billsix/pyNuklear
Re: Hello Qt for Python
#87I have been waiting for this my entire adult life. That's all I have to say about it.
What about pygobject? What does Qt have to offer over GTK?
Re: Hello Qt for Python
#88Is is possible to use QML in a PyQt/PySide2 app? Using QML for interface and Python for logic would make perfect sense. But every PyQt article and tutorial I see is about QtWidgets.
I'm also working on a similar solution for .NET Core: https://github.com/pauldotknopf/net-core-qml
Re: Hello Qt for Python
#89Very happy to hear this as the author of a PyQt-based file manager [1] and an open source library for solving the many headaches that come with developing desktop apps [2]. Once Qt for Python is stable enough, I'll be happy to switch to it from PyQt. [1]: https://fman.io [2]: https://github.com/mherrmann/fbs
What would you recommend to someone who wants to write Python desktop applications today? I've used wxWindows way back when, and I'd hate to use Electron. Would you go with Qt for Python, or PyQT? Also, what's PySide/PySide2?
PyQt5 and Qt for Python is a 1-to-1 binding to the original Qt and their APIs are almost identical, so you should be able to switch to Qt for Python quite easily when it is stable.
By the way, Qt for Python is re-branded from PySide2. They are the same.
Re: Hello Qt for Python
#90Earlier quoted context omitted.
What would you recommend to someone who wants to write Python desktop applications today? I've used wxWindows way back when, and I'd hate to use Electron. Would you go with Qt for Python, or PyQT? Also, what's PySide/PySide2?
As you can see, Qt for Python is not yet stable release. So you will want to use PyQt5 first. I remcommand PyQt5 because there are more resouces available on the internet now. PyQt5 and Qt for Python is a 1-to-1 binding to the original Qt and their APIs are almost identical, so you should be able to switch to Qt for Python quite easily when it is stable. By the way, Qt for Python is re-branded from PySide2. They are…