This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes Jython/Python and the fly likes Think Python: GUI programming with Python? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Languages » Jython/Python
Bookmark "Think Python: GUI programming with Python?" Watch "Think Python: GUI programming with Python?" New topic
Author

Think Python: GUI programming with Python?

Qunfeng Wang
Ranch Hand

Joined: Jan 28, 2005
Posts: 433
I see there is a chapter about GUI programming in your book. What's the capability of python in GUI programming? It's about different platforms, OS, and screens. Does Python work well in this area?


To be or not to be. It's a question.
Pedro Neves
Ranch Hand

Joined: Mar 07, 2012
Posts: 64
qunfeng wang wrote:I see there is a chapter about GUI programming in your book. What's the capability of python in GUI programming? It's about different platforms, OS, and screens. Does Python work well in this area?


As far as i know python works like Java. It is transformed to bytecode and then interpreted.
Python runs on different platforms and OS (i think you just have to ajust your python VM). To know some more visit: http://tech.blog.aknin.name/2010/04/02/pythons-innards-introduction/

All i told you about python is what i heard and could not be accurate..
Allen Downey
Author
Greenhorn

Joined: Sep 07, 2012
Posts: 25

There are several GUI libraries for Python. I primarily use tkinter, but wxPython is big, too. With Jython you can use all the Java GUI libraries, too.

As Pedro said, Python compiles into bytecode which runs on an interpreter, and the interpreter runs pretty much everywhere. So, portability++

Allen

All of my books are available from http://greenteapress.com
Pedro Neves
Ranch Hand

Joined: Mar 07, 2012
Posts: 64
If you want a book to learn about tkinter i think you can use "an-introduction-to-tkinter". I'm not a python expert.. But as far as i know it seems to be a good book for beginners (including me of course ;))

Kind regards
Red Smith
Ranch Hand

Joined: Aug 05, 2007
Posts: 136
    
    1
qunfeng wang wrote:I see there is a chapter about GUI programming in your book. What's the capability of python in GUI programming? It's about different platforms, OS, and screens. Does Python work well in this area?


There are a couple of popular cross-platform C++ GUI libraries - QT and wxWidgets - and one that is for C (GTK+). Python has interfaces to all three. But none of those interfaces (nor the GUI library) comes with the standard Python distribution. However, there is a cross-platform GUI library called TK which was originally developed for the scripting language Tcl. Both Perl and Python have created interfaces to this library. In the case of Python the interface is called Tkinter. And, both TK and Tkinter come with the standard Python distribution. The book Think Python does have a chapter on Tkinter.
 
GeeCON Prague 2014
 
subject: Think Python: GUI programming with Python?