Python has been the most trending programming language used for object oriented progamming. With python you can run simple statement over and over again without having to compile a whole program of which it's output functionality is superb.
Of course, Python is an interactive programming which has a diverse range of options for GUI (Graphical User Interface) framework (help developers create GUI applications in an easy and secure manner). This article discusses the Best Python framework for building a desktop application and GUI.
NB: It is essential that you have a basic knowledge of Python programming language before you can use these python frameworks.
Let's delve it to the discus
PyQT
PyQt is a Graphical User Interface widget toolkit. It is one of the most powerful and popular Python interfaces. It is a combination of the Qt (owned by Nokia) library and Python programming language which leaves a developer to decide whether to create a program by coding or create visual dialogs using Qt Designer.
PyQt is a free Python bindings software open-source widget-toolkit Qt, implemented for cross-platform application development framework. In the free version, certain features may not be available but if your application is open source then you can use it under a free license.
PyQt is available on Windows, MacOSX, Linux, Android iOS and Raspberry Pi and different python versions ranging from v2 to Qt v5.
Tkinter
Tkinter is the most popular programming package for graphical user interface or desktop apps. It is so named because of its simplicity. Tkinter is the combination of Tk and Python's standard GUI framework.
TKinter comes with an abundance of resources of codes and reference books which is the major merit of choosing it as a package. It provides diverse widgets, such as labels, buttons, and text boxes used in a graphical user interface application. The Button control also called widgets are used to display buttons in developed application while the Canvas widget is used to draw shapes (lines, ovals, polygon...) in your application.
It is easy to get help when you come across a hurdle in the course of developing your application since Tkinter has thousands of users because it has been in use for a very long time. Tkinter is an open source and it is available under the Python License.
Kivy
Kivy as an OpenGL ES 2 accelerated framework for the creation of new user interfaces empowers you with the ease to write your code once and have it run on different platforms or Operating Systems (Windows, MacOSX, Linux, Android iOS and Raspberry Pi).
Kivy apps creation is fun, easy and rewarding because it is free and is an open source Python library for creating application software with an enabled natural user interface . Kivy comes twenty widgets in its toolkit.
WxPython
WxPython is a python extension module. It is also an open source wrapper for cross-platform graphical user interface library Widget.
As a developer, you can develop traditional applications for Windows, Unix and Mac OS.
PyGUI
PyGUI is the simplest and most lightweight of all GUIs because it is purely in sync with Python programming language. It is a cross-platform graphical application framework for Windows, Mac OS, and Unix.
A PyGUI developer inserts very less code between the GUI platform and Python application which in turn displays the natural GUI of the platform.
Summary
The above listed are the most widely used and best Python graphical user interface frameworks available. It's up to the developer to choose the Python GUI framework that best suits him/her.
Top comments (33)
Qt officially adopted PySide2 as their own formally maintained Qt5 bindings for Python, so it is advisable to use that over the third-party PyQt5 now. They're feature-identical at this point. (Bonus, PySide2 is LGPL, while PyQt5 is GPL!)
Also, just FYI, packaging a Kivy app for distribution is a living nightmare, due to a significant and complex bug in
setup.py
related to the Cython dependency. Tried to package my own project for six months, even getting Alan Pope ("popey" of Snapcraft), Gabriel Pettier ("tshirtman" of Kivy), "TheAssassin" of AppImage), and a Debian packaging expert (whose name is lost in my IRC backlogs) involved in trying to manage a workaround. No dice.Is PySide2 actually ready from primetime use? The list of known issues on the wiki doesn't fill me with confidence and there are a large number of bugs on the tracker.
I'm in agreement that Qt for Python (PySide2) is likely the best option in the long term due to the first party maintenance by Qt, but I'm concerned it's not as stable as PyQt5 yet.
I haven't noticed anything major as of yet, and anyway, you know how it goes: adoption usually speeds up bugfixes.
I'd recommend to start building with PySide2; by time your project is finished, it will be stable. Or else, worse case, you just change your import statements and leave the rest the same. ;)
I already have a large project that was ported from PySide1 to PyQt and it was non-trivial to do (sure most of it was the same but that couple of percent difference was a pain to find and update), so I'm not keen to repeat that experience until it's worth it. Sounds like maybe I should wait a bit longer or look into using qtpy as an abstraction layer.
I think that was a newer thing about Qt5...that PySide2 and PyQt5 had identical APIs. But I could be wrong. The abstraction layer sounds wise in any case.
Pyside2 is still not very much maintained like PyQt5
Define "very much maintained". PySide2 regularly releases updates at roughly the same frequency as PyQt5. In fact, if you look at the dates, PySide2 usually releases a few days before PyQt5!
ok my bad
Do you normally just go around posting negative reviews and saying "ok my bad" when you've been called out? Enough already.
That was uncalled for.
It's been edited, but clearly the guy was accusing the product of not doing something, and only recanted when you corrected him.
People make mistakes. He learned something and recanted. That's praiseworthy, not something to condemn for. Or have you never misspoken in your entire life?
Please don't attack someone for recanting ever again. That sort of hateful reaction is why people are afraid to admit mistakes. Respond to others the same way you'd want them to respond to you.
Point well taken. Without the necessary information, my response was unwarranted. That leads me into my question for you: do you think he made a mistake, though? You did seem to ask him for clarification on the matter, but then you immediately countered his claim. Puzzling.
I read again, and I don't see where I asked for clarification. I was countering amohgyebi at the end there, not the earlier person/people in the thread, in any case.
Did you not write "define not very much maintained", and then in the same post counter the very statement you quoted? Both of us are in the wrong. Peace.
Uhm, no. I countered the common meaning of "not very much maintained" to save time, but left room for him to correct his meaning if I missed it. It wasn't aggressive. So no, we're not "both in the wrong." You attacked someone, unbidden, for apologizing for a mistake he made months ago, which none of the people originally party to felt the need to continue.
But whether you choose to learn from this is up to you.
LMAO, if you think that my asking if he normally goes around posting negative reviews. Stop playing the victim card. I have no idea as to how old you are, but in the real world you DON'T get to run around dismissing this or that, and NOT get called out for it. You have NO IDEA what an "attack" is. Grow up, and good day.
I was excited to see couple of new frameworks and immediately was excited by
kivy
. Glad I read your comment, looks like I shouldn't touch that yet !I've found PySimpleGUI to be a great platform for quickly building a desktop app. Everything I've built with it is small (I.e. not an enterprise application,) so take my evaluation with a grain of salt- but my experiences have all been fantastic. My only real gripe is their readthedocs page is a bit of a mess.
The last time I tried PySimpleGUI, I felt it was effective for teaching a child how to program a gui, but that was in 2017. I was pretty underwhelmed, to say the least.
Huh... musta been something different. PySimpleGUI wasn't released until July 2018.
I've seen PySimpleGUI confused with SimpleGUI or something similar by a couple of people. Many of the earlier attempts at a simple Python GUI package have been abandoned, so perhaps this is why you've not seen any changes since 2017?
No, it was PySimpleGui. I had the year wrong. I just went through it's documentation two days ago, I couldn't figure out how to disable a text input based on some condition. It really hasn't changed much, but hey there a gozillion themes now.
This, to all points. Small application, simple GUI development, but the docs are a mess.
Be sure and use the version of the docs that are on ReadTheDocs ( PySimpleGUI.org ). There is a table of contents that spans the entire left portion of the window. There are also 3 tabs. One of the tabs is the call reference. It has every Element, every element's methods, all functions, and parameters and return codes for each of them. Another is a Cookbook with a number of small projects detailed for you to follow and run.
Yes, having hundreds of pages of information in the lengthy format it's in does make it challenging at times, but it also makes searching really easy, and, most importantly..... it exists and is thorough. Most individual efforts like PySimpleGUI is don't have any documentation to speak of.
In addition, be sure and look through the couple hundred demo programs that show you how to apply each of the elements as well as how to integrate with a number of other important packages like 'matplotlib and OpenCV.
The documentation isn't just one thing in PySimpleGUI. It's meant to be an entire "system" of documentation that works together.
Oh, one final bit of the documentation is the doc strings. There's a YouTube tutorial about how to install PyCharm for use with PySimpleGUI because of the docstrings. They are a HUGE part of the PySimpleGUI documentation. They are the reason you should rarely need to open the main documentation. Press Control+Q and you're shown everything about a particular element's method's parameters. These docstrings are what is used to build the call reference portion of the printed docs.
Fantastic. Just the summary I was looking for. I want to create a small, simple desktop app for sharing without a ton of unneeded baggage. (I once shared a small app for graphing which required only 25k bytes because it relied on dlls already in Windows.) Thanks.
I tried finding documentation in PySimpleGui on how to disable a text input control, no dice. That's a pretty basic feature in a GUI. I should be able to disable text inputs based on conditions. When I tried out PySimpleGui in 2017 I found it very limited, and in my opinion not much has changed. I'm trying out wxPython now.
How would you create a standalone installation file for Windows with Python?
Suprised you didn't include beeware.org in your list. Toga is well designed and easy to create a cross platform app.
I did not know pygui but now inwill surely try it out.
Have you used PyCharm ? There is a free edition
Pycharm is Python IDE. It is not Python GUI framework.
Some comments may only be visible to logged-in visitors. Sign in to view all comments.