As I've learned more about basic console Python script writing, I've had a look at both Tkinter and GTK+...and, at first glance, I like GTK+ better. Which do you guys prefer, and why?

Recommended Answers

All 5 Replies

I've used both and I make my decision as follows: I use Tkinter on Windows since Python installs with it and I use GTK on Linux (Ubuntu) since that's what comes with that.

GTK has always been tempramental to install on Windows machines. I like to use Tkinter for quick stuff and PySide (PyQT) for more fancy coding problems.

I wonder if GTK has made it easier to create and use a listbox?

The Pidgin installer auto-downloads and auto-installs Gtk libraries, and Pidgin has always run flawlessly for me on Windows. What aspect of Gtk is temperamental to install on Windows machines?

On my Linux distro, I can import gtk in Python 2.7 but can't in Python 3.x without enabling 2.x support. I can, however, import Tkinter in both. I should ask my distro's maintainers why that is so, unless would be more likely to know.

With GTK I had always problems with missmatching version numbers in its submodules (cairo and a few others).

Portable Python comes with a boatload of preinstalled third party modules, including GTK. That one works well on Windows, but I do work a lot with listboxes, seemingly a pain in GTK.

Over the years I got used to PyQT. PySide (the official LGPL-licensed version of PyQT) installs readily on Python33.

Meh I had a look at LGPL and it looks like just a way to permit a client or employer to make your work proprietary so the GPL no longer affects it. Might as well make your own code proprietary to you and sell a license to use it, if you're going to do that--although I strongly doubt that commercial software companies will permit you to retain control over rights to the code you write for them.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.