Tkinter GUI tutorial
Learning Python (mentioned earlier) has a rather nice tutorial up called Creating a GUI in Python using Tkinter:
There are a lot of python GUI toolkits out there, but for our first application we are going to use Tkinter, which is considered somewhat of a standard right now and is installed when pyhon is installed. Another nice thing about the Tkinter GUI is that it is cross platform and offers a native look and feel on *nix, Windows, and OS X.
The only GUI programming I’ve done with Python up to this point has been with PyGame. Other applications I’ve run on Windows all seem to use wxWindows, but perhaps I should look into Tkinter.
February 16th, 2006 at 6:21 pm
That is kewel. The SWT lib for java claims to do the same thing…at least I think it does if I am reading this right. Namely abstract the various GUI toolkits into one. So you write your app and on windows it looks like windows and gnome it looks like gnome. This is the toolkit used to build eclipse, and frankly it’s a damn cool idea.
February 16th, 2006 at 6:46 pm
TkInter is just Python binding for Tk, so it does whatever Tk does. But yeah, on Windows it looks like a Window app and on Gnome it looks like Gnome. Quite nice.
Tk is still going strong, even if Tcl doesn’t have the buzz of Ruby/Python these days. I did a little Tcl/Tk scripting in college… it was kind of cool if I recall.
February 17th, 2006 at 10:03 am
Hey Thanks for comment. I looked at using wxWidgets, and have used them in the past, however I heard that it was difficult to install wxWidgets on OS X? So I went with Tkinter because it seemed to work well and because it’s installed if you have python installed.
What I’d actually like to find is a nice cross platform GUI toolkit that looks normal on most operating systems, and has a resource editor…
February 18th, 2006 at 3:11 pm
I’ve never used either (Tkinter/wxWindows), so I can’t really say. I do know that I had a heck of time getting all the versions right when I tried to install OpenRPG. So I’m not convinced it’s any easier to distribute wxWindows apps than Tkinter.
Also, I don’t have any OS X experience, so I can’t speak to that.