2

I'm interested in getting started w/ developing Python based applications for a desktop environment and have a few (seemingly simple) questions:

  1. What is the best method for developing GUI applications? I've seen several frameworks but the indexes I've found are a bit convoluted and mix (what seem to be) legacy packages. In your opinion, what is the best approach in this regard?
  2. I've been reading a few books I recently picked up, but have been having trouble finding (rather, recognizing) a decent 'getting started' tutorial that focuses on Python apps for the desktop. Do you have any recommendations?

Thanks very much in advance! :)

Benny
  • 1,248
  • 2
  • 12
  • 21
mO_odRing
  • 1,935
  • 3
  • 15
  • 19
  • 2
    Duplicate of all of these: http://stackoverflow.com/search?q=%5Bpython%5D+desktop+gui. For example: http://stackoverflow.com/questions/842075/practical-gui-toolkit – S.Lott Jan 07 '10 at 19:19
  • 1
    Are you looking to develop for/on Windows or a Unix, like Linux? –  Jan 07 '10 at 19:20
  • @Amit - At the moment I'm open to any desktop environment.. However, eventually I'd prefer to develop cross-platform. Secondary preference would be to develop for Windows and / or OSX environments. – mO_odRing Jan 07 '10 at 19:29
  • @S.Lott - I'm sorry if I'm being ignorant but while similar in nature, I fail to see how any of the posts you've linked answer my question directly. I did search before posting, if that's what you're implying. – mO_odRing Jan 07 '10 at 19:31
  • @Lorren Biffin: I can't tell from your question that you looked at anything. If doesn't reference any of the hundreds of existing questions on SO that seem to be *exactly* the same. If you could pick a few questions and show how yours is different, it would be helpful. – S.Lott Jan 07 '10 at 19:50
  • How is your question any different from http://stackoverflow.com/questions/280380/python-gui-programming? – S.Lott Jan 07 '10 at 19:53
  • No thank you. It seems we have a difference in perspective and I'm not sure I can solve that for you. Take care! :) – mO_odRing Jan 07 '10 at 19:56
  • If using web technologies like HTML5/JS/CSS for UI is fine for you then you may embed a Chrome browser control in your app using [CEF Python](http://code.google.com/p/cefpython/). – Czarek Tomczak Oct 27 '12 at 08:57

4 Answers4

4
  1. wxPython is the best GUI framework.
  2. The official docs are the best resource. They helped me quite a bit.
Nathan Osman
  • 71,149
  • 71
  • 256
  • 361
  • The docs have been amazing for syntax reference, but have still been a bit confusing w/ regard to the process of implementing and working w/ an environment dedicated to desktop development and deployment. Seeking additional resources. Thank you for the recommendation of wxPtyon. :) – mO_odRing Jan 07 '10 at 19:58
  • There are a lot of good tutorials hidden amongst the docs too :) – Nathan Osman Jan 07 '10 at 20:05
1

Have you considered Iron Python as an option? It's basically the Python language on top of the .NET Framework. Having been fortunate enough to work with the .NET Framework in the past on desktop-applications, I can attest to its depth of excellent.

Sampson
  • 265,109
  • 74
  • 539
  • 565
  • Interesting idea. Do you have any links to a good "getting started" tutorial? – Craig McQueen Jan 07 '10 at 23:40
  • @Craig: Perhaps "A First Look at IronPython: Where Python meets .NET" will be of some interest: http://www.devsource.com/c/a/Languages/A-First-Look-at-IronPython-Where-Python-meets-NET/ – Sampson Jan 08 '10 at 02:55
1

wxPython is a phenomenal GUI toolkit for developing native applications. I highly recommend it. Also, if you combine it with py2exe you can create .exe files for running on Windows.

calvinlough
  • 362
  • 3
  • 13
  • If you ever need to write an app that must also by cross-ported to Linux, you may prefer PyQt to wxPython. I found that when I wanted to try wxPython in my corporate Linux environment, wxPython has dependencies on the latest and greatest of all its dependencies. Whereas PyQt seems to be reasonably compatible to less than the latest and greatest for its dependencies. – Ross Rogers Jan 07 '10 at 19:35
  • What are these so-called latest and greatest? – Nathan Osman Jan 07 '10 at 19:50
  • The version of python, gcc, glib, gtk+, opengl. I've installed a lot of code from tar-balls and I had a lot of trouble with wxPython. I may be an idiot, but this idiot was turned off to wxPython :-) Using wxPython could be a deployment risk/hassle. This is just my experience. If you have root permissions on all the machines you're going to run on and you're allowed to update them to the latest with something like a `sudo apt-get dist-upgrade`, then this is a non-issue. – Ross Rogers Jan 07 '10 at 20:04
  • True. There are a lot of dependencies, but that's not necessarily a bad thing. – Nathan Osman Jan 07 '10 at 20:19
  • @Ross Perhaps in that case you could install whatever old version of wxPython was around at the time the dependencies *were* the latest and greatest. – Craig McQueen Jan 07 '10 at 23:38
  • Or, as most smart admins do, keep everything up to date anyway. – Nathan Osman Jan 08 '10 at 04:37
1

easyGUI and Tkinter are VERY easy libraries that can be used with Python to make GUIs. Further, as stealthdragon has suggested, you can use py2exe to compile your GUIs into EXEs for your PC. There are also other compilers such as pyc.

As Jonathan Sampson suggests, you might consider using IronPython and use it to wield the full power of the .NET framework. The IronPython Cookbook, which among other things shows you how to make a basic Twitter Client.

inspectorG4dget
  • 110,290
  • 27
  • 149
  • 241