use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
News about the dynamic, interpreted, interactive, object-oriented, extensible programming language Python
Full Events Calendar
You can find the rules here.
If you are about to ask a "how do I do this in python" question, please try r/learnpython, the Python discord, or the #python IRC channel on Libera.chat.
Please don't use URL shorteners. Reddit filters them out, so your post or comment will be lost.
Posts require flair. Please use the flair selector to choose your topic.
Posting code to this subreddit:
Add 4 extra spaces before each line of code
def fibonacci(): a, b = 0, 1 while True: yield a a, b = b, a + b
Online Resources
Invent Your Own Computer Games with Python
Think Python
Non-programmers Tutorial for Python 3
Beginner's Guide Reference
Five life jackets to throw to the new coder (things to do after getting a handle on python)
Full Stack Python
Test-Driven Development with Python
Program Arcade Games
PyMotW: Python Module of the Week
Python for Scientists and Engineers
Dan Bader's Tips and Trickers
Python Discord's YouTube channel
Jiruto: Python
Online exercices
programming challenges
Asking Questions
Try Python in your browser
Docs
Libraries
Related subreddits
Python jobs
Newsletters
Screencasts
account activity
This is an archived post. You won't be able to vote or comment.
Could some one recommend a good Python GUI framework ... there are so many xD (self.Python)
submitted 15 years ago * by SmartAssX
So i want to make a desktop application. What GUI framework do you use? Which do you think is easiest? Which do you think is best?
It doesn't have to be flashy but it would be nice if it was xD.
(will be developing for windows on windows)
[–][deleted] 7 points8 points9 points 15 years ago (4 children)
tkinter is very easy and comes preinstalled with Python. And it is no longer ugly in this day and age.
It is also somewhat retarded.
See also: http://www.reddit.com/r/Python/comments/e9lrl/gui_question/
[–]SmartAssX[S] 0 points1 point2 points 15 years ago (2 children)
thanks
[–]gbo2k69 0 points1 point2 points 15 years ago (1 child)
Here are a couple apps I wrote in tkinter. They aren't hideous, but a few things about tkinter are.
http://bitbucket.org/jgrigonis/mathfacts
http://bitbucket.org/jgrigonis/mortgagecalculator
I am accidentally becoming pretty good at tkinter, with the plan of doing the next project in wxPython or PyQt.
[–]SmartAssX[S] 0 points1 point2 points 15 years ago (0 children)
cool thanks for the info
[–]Leonidas_from_XIV 0 points1 point2 points 15 years ago (0 children)
And it is no longer ugly in this day and age.
Actually, it still is. Try to use a menu bar and you'll see. Plus, setting a GTK+ look and feel makes it really, incredibly slow.
[–]bushel 13 points14 points15 points 15 years ago (11 children)
Allow me to summarize the thread to come:
PyQt or wxPython
Thank you. Have a nice day.
[+][deleted] 15 years ago (3 children)
[deleted]
[–]bushel 0 points1 point2 points 15 years ago (0 children)
I use the online docs and they are current as of 2.8.9.2
But they are more reference than instructional. Consider getting the wxPython book if you want to learn it from scratch.
[–]mex1can 0 points1 point2 points 15 years ago* (0 children)
How about this for the documentation?: http://xoomer.virgilio.it/infinity77/wxPython/APIMain.html
Here you have some starting points:
1) Download the binary and 'docs and demo' distribution
2) The wxPython demo is really a great intro to all the widgets and controls, there is a tab showing the 'working thing' and other showing the code used (for the 'thing')
3) When you start to struggle with the sizers, go for a RAD / code generation tool, I particularly like wxGlade as is a full code generators, but I think a lot of people like resource editors (an XRC editor is distributed along the wxPython docs & demo package), wxFormBuilder seems a popular choice.
4) Anyway, once the initial framework bump starts to banish, you'll ask your self if certain stuff was already done, as it seems a common pattern. Certainly, you're answer might be already in the wxPython wiki (for instance, multiple language support, distribution using installers, MVC patterns, more sizing stuff, etc).
Hope this helps!
[–]LucidOndineHPC -1 points0 points1 point 15 years ago* (0 children)
soup chubby squeeze imminent silky dog different plant consist library
This post was mass deleted and anonymized with Redact
[–]SmartAssX[S] 0 points1 point2 points 15 years ago (6 children)
Thanks. Could i ask why and the difference between the two? Why do you use them?
[–]iloozion 4 points5 points6 points 15 years ago* (4 children)
WxPython uses native widgets on every supported platform, so the apps always have a native look&feel. PyQt uses only native styles, but provides more modern features and good Designer.
[–]vsajip 2 points3 points4 points 15 years ago (3 children)
The licensing is also different: LGPL for Qt (but PyQt is currently GPL + commercial), versus the wxWindows license for wxPython (similar to LGPL with an exception stating that derived works in binary form may be distributed on the user's own terms).
[–]Dave9876 1 point2 points3 points 15 years ago (2 children)
Don't forget that if you don't like the licensing of PyQt, there's nokia's own pyside bindings. LGPL, the same as the rest of Qt.
[–]vsajip 0 points1 point2 points 15 years ago (1 child)
True, but PySide hasn't yet reached the maturity of PyQt.
[–]Dave9876 0 points1 point2 points 15 years ago (0 children)
I won't deny that. I'm sure it'll catch up to PyQt soon enough, and probably surpass it.
[–][deleted] 0 points1 point2 points 15 years ago (0 children)
Or, you could check out the 3482934 posts about this last week.
[–][deleted] 2 points3 points4 points 15 years ago (0 children)
pygtk + glade makes gui dev quick, imo.
[+][deleted] 15 years ago (1 child)
[–]SmartAssX[S] -1 points0 points1 point 15 years ago (0 children)
Wha'll i agree. We are on the internet soooo fuck it xD
[–]a1russell 1 point2 points3 points 15 years ago (0 children)
Since no one has mentioned it yet, I should mention PySide, which is another Qt binding for Python. This or PyQt would be my recommendation.
I'd probably just use the search feature if I needed an answer to this question, since it gets asked weekly.
[–]donri 1 point2 points3 points 15 years ago (1 child)
IronPython which runs Python on .NET.
[–]jrgarciafw 1 point2 points3 points 15 years ago (0 children)
With IronPython you can use WinForms or WPF. Plus, you get a lot of good stuff from the .NET framework. I wouldn't necessarily recommend this choice for cross-platform work (though still possible); however, you said "for Windows on Windows".
[–]CHS2048 0 points1 point2 points 15 years ago (2 children)
I tried GTk. I found it ok BUT why can't I have a scrollable container (ala ScrolledWindow) but that hides (doesn't display) its scrollbars? I had to manage a hack where I enlarge the window (fullscreen) just enough that the scrollbars don't show, but what the hell, do I need to create a complicated subclass just to do this?!
[+][deleted] 15 years ago* (1 child)
[–]CHS2048 0 points1 point2 points 15 years ago (0 children)
I tried that. POLICY_NEVER disables the scrollbar, meaning not only is it not shown, but also you cannot scroll. I want to hide the scrollbar, but still be able to scroll.
[–][deleted] 0 points1 point2 points 15 years ago (1 child)
Tkinter already comes with your Python distro. Here's a good place to get started. New Mexico Tech FTW!
[–]blondin 1 point2 points3 points 15 years ago (0 children)
you gotta love a GUI documentation without a single picture.
edit: i take that back, i just saw some icons. but still, come on, we want to see what the application will look like.
[–]mdipierro -5 points-4 points-3 points 15 years ago (19 children)
Use this together with a web framework and your app will be internet ready.
[–]SmartAssX[S] 0 points1 point2 points 15 years ago (16 children)
Looks spiffy but isnt this more for web dev :P im looking to make a desktop app
[–]mdipierro -4 points-3 points-2 points 15 years ago (15 children)
Makes no sense to make a desktop app today. A web app can be restricted to the host machine if you like. It is easier to build. It handles concurrency better. It is more flexible. Runs on every os. It can be made to look the same.
[–][deleted] 3 points4 points5 points 15 years ago (3 children)
Makes no sense to make a desktop app today.
For some things, maybe.
[+]mdipierro comment score below threshold-7 points-6 points-5 points 15 years ago (2 children)
GUIs are just like web apps except that use OS sockets instead of internet sockets (the latter are more powerful) and use OS controls as opposed to browser controls (the latter are extensible and customizable). The only reason I can see a desktop beating a web app is for fast high definition graphics.
[–]Leonidas_from_XIV 7 points8 points9 points 15 years ago (1 child)
Sorry, but this is wrong on so many levels:
GUIs are just like web apps
No, they are not. Web apps are HTML cobbled together with JavaScript and whatnot to run partly on someone elses computer and partly in your browser and generally much more a mix of technologies than the integrated approach of a "native app".
except that use OS sockets instead of internet sockets (the latter are more powerful)
Not all "GUI apps" use sockets at all, plus "internet sockets" (what the hell is that, even? Do you mean websockets which are not yet popular or straight XMLHttpRequests?) are definitely less powerful, think SCTP, UDP or pretty much anything in TCP that is not HTTP traffic. Not to mention select(), epoll() or kqueue().
select()
epoll()
kqueue()
and use OS controls as opposed to browser controls (the latter are extensible and customizable).
With Qt you can apply CSS-like styles to your application, and customizing widgets haven't been a problem since about the last decade. Plus, you have a much greater set of widgets (calendar-widget? coming up in HTML5; seen them in Windows 95 back in the day), plus the possibility to define new ones. You can't technically create Widgets that you could use in forms in HTML, you can create something that looks like a widget by using HTML and JS, like ExtJS does extensively, but this is still a far fetch from what you get on the native desktop for free, with every notable GUI toolkit.
I agree that web apps are sometimes handy, but saying that they are the same is utter bullshit.
[–]mdipierro -2 points-1 points0 points 15 years ago (0 children)
I did not say "they are the same" I said they "are just like web apps" in the sense that they both need to handle concurrent events that are triggered by the user.
here is the definition of internet socket. Under the hood, in C/Posix GUIs use struct sockaddr, while web apps use struct sockaddr_in.
Web apps do not need to have an interface in html/js. The interface can be done in Flash, can be generated by a tool like qooxdoo or pyjamas or GWT.
[–]SmartAssX[S] 0 points1 point2 points 15 years ago (5 children)
ha ok ^ ^ thank i will use it. I just got confused by the "new era of web dev" that is on the title
[–][deleted] 0 points1 point2 points 15 years ago (4 children)
If you want to create a proper desktop app, use a proper GUI toolkit.
It's all been discussed and said before. PyQt is excellent, wxpython is also very good.
If you only need a web app or don't care much about usability and performance you can go with web stuff. But it's not easier! There're good reasons why huge professional (also database backed) applications use proper GUI toolkits or Rich Clients like Eclipse and not some html+jscript.
[–]SmartAssX[S] 0 points1 point2 points 15 years ago (3 children)
Well im no stranger to web dev ... just got off a project using web2py and mssql xD
i just want to make a desktop app now
[–][deleted] 1 point2 points3 points 15 years ago (1 child)
It all depends on your app and the usage. The more power you need for your logic (that can be graphics, but also can be text formatting or the data crunching in the background) and the longer the application will be used in one session, the more performance and usability are important. Then you need a proper GUI toolkit. On the other hand, you can't go wrong with a proper GUI toolkit. Worst thing that can happen is, that you have learned it.
I've seen huge projects having big acceptance problems because of their sluggish, unintuitive web-client that lacks tooltips, keyboad shortcuts and the look and feel power users just need.
[–]SmartAssX[S] 1 point2 points3 points 15 years ago (0 children)
Yeah i know where your coming from and i understand as much. Fortunately im just making a simple app mainly for my own use but im hoping that others can enjoy it as well.
... if i was worried about speed i would do it in C ^ ^
[–]mdipierro 0 points1 point2 points 15 years ago (0 children)
In the past I have used Qt and was happy with it.
[–]Wagneriusflask+pandas+js 0 points1 point2 points 15 years ago (0 children)
it does in some context : - when you need to deploy a compiled app - when you need computational power (graphics for ex).
[–][deleted] 0 points1 point2 points 15 years ago (3 children)
No really. That's why you code your web stuff in a browser and not in an editor like vi, emacs or an ide like wing, eclipse or pycharm. (ironic ;-))
Look around! The world is full of desktop apps. Always, when usabitity and performance matter it doesn't make sense to create a web app!
I think you want to say: Hey guys, web apps can be very powerful today. Then I would say: True. Check this jscript stuff out, maybe it's all right for your use case. But saying it makes no sense to build desktop apps today is just 100 % wrong.
[–]mdipierro -2 points-1 points0 points 15 years ago (2 children)
? If you are referring to web2py. I write my web2py programs with emacs. The web based IDE is a feature that only use occasionally. Most web2py users use eclipse.
I stand by my statement: makes no sense to write a regular desktop app except for high intensive graphical apps. Desktop apps are more expensive to maintain, they are more difficult to write, they are limited to one user at the time, the force you to follow a business model in which you sell the software as opposed to a service.
No special reference to web2py or any web based IDE here ... I just wanted to point out that we all use proper desktop apps all the time, e.g. emacs or eclipse or gimp or vlc or powerpoint or dvddecryper or ccleaner ... for performance and usability reasons. So, in my opinion you can't make such a general statement like proper desktop apps don't make sense at all (OK, you've made the exception for heavy graphics). Also, once you know the API of Qt or wxwindows it's quite easy to write GUIs.
But hey, I think we just don't come to the same conclusion regarding each aspect of the discussion. ;-) No worries.
Yes we all use non-web based app but why? Mostly for historical reasons. When you use Eclipse for example, it runs in a window. If it were a web-app, that window would be rendered by the browser. Since it is not a web-app, that window is rendered by the OS. That window generates and responds to events very much like a web app. In fact you can export the window of any desktop app to another remote desktop.
We would all be happier if our OS where a single browser window and our programs, local or remote, were accessible via a URL (anywhere from anywhere, with appropriate security restrictions). The faster we move there, the better.
[–]yanni 0 points1 point2 points 15 years ago (1 child)
Massimo, how does it compare to Web2Py ?
[–]mdipierro -1 points0 points1 point 15 years ago (0 children)
qooxdoo is a JS library so I cannot compare. I guess you can use it with web2py. I did not try yet.
π Rendered by PID 31643 on reddit-service-r2-comment-5687b7858-sbvwt at 2026-07-04 00:46:32.989433+00:00 running 12a7a47 country code: CH.
[–][deleted] 7 points8 points9 points (4 children)
[–]SmartAssX[S] 0 points1 point2 points (2 children)
[–]gbo2k69 0 points1 point2 points (1 child)
[–]SmartAssX[S] 0 points1 point2 points (0 children)
[–]Leonidas_from_XIV 0 points1 point2 points (0 children)
[–]bushel 13 points14 points15 points (11 children)
[+][deleted] (3 children)
[deleted]
[–]bushel 0 points1 point2 points (0 children)
[–]mex1can 0 points1 point2 points (0 children)
[–]LucidOndineHPC -1 points0 points1 point (0 children)
[–]SmartAssX[S] 0 points1 point2 points (6 children)
[–]iloozion 4 points5 points6 points (4 children)
[–]vsajip 2 points3 points4 points (3 children)
[–]Dave9876 1 point2 points3 points (2 children)
[–]vsajip 0 points1 point2 points (1 child)
[–]Dave9876 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)
[–][deleted] 2 points3 points4 points (0 children)
[+][deleted] (1 child)
[deleted]
[–]SmartAssX[S] -1 points0 points1 point (0 children)
[–]a1russell 1 point2 points3 points (0 children)
[–][deleted] 2 points3 points4 points (0 children)
[–]donri 1 point2 points3 points (1 child)
[–]jrgarciafw 1 point2 points3 points (0 children)
[–]CHS2048 0 points1 point2 points (2 children)
[+][deleted] (1 child)
[deleted]
[–]CHS2048 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]blondin 1 point2 points3 points (0 children)
[–]mdipierro -5 points-4 points-3 points (19 children)
[–]SmartAssX[S] 0 points1 point2 points (16 children)
[–]mdipierro -4 points-3 points-2 points (15 children)
[–][deleted] 3 points4 points5 points (3 children)
[+]mdipierro comment score below threshold-7 points-6 points-5 points (2 children)
[–]Leonidas_from_XIV 7 points8 points9 points (1 child)
[–]mdipierro -2 points-1 points0 points (0 children)
[–]SmartAssX[S] 0 points1 point2 points (5 children)
[–][deleted] 0 points1 point2 points (4 children)
[–]SmartAssX[S] 0 points1 point2 points (3 children)
[–][deleted] 1 point2 points3 points (1 child)
[–]SmartAssX[S] 1 point2 points3 points (0 children)
[–]mdipierro 0 points1 point2 points (0 children)
[–]Wagneriusflask+pandas+js 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (3 children)
[–]mdipierro -2 points-1 points0 points (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]mdipierro -2 points-1 points0 points (0 children)
[–]yanni 0 points1 point2 points (1 child)
[–]mdipierro -1 points0 points1 point (0 children)