473,756 Members | 7,817 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Tkinter--does anyone use it for sophisticated GUI development?

I'm a Tcl/Tk developer who has been working, slowly, at learning Python,
in part because Python has better support for certain kinds of
applications that I want to develop than Tcl/Tk does. Naturally, I
thought that I would use Tkinter as the GUI for these programs. However,
in doing research into GUI development techniques, sample code, and
showcase applications, what has struck me is how little sophisticated
GUI development seems to be done in Tkinter as compared to, say,
wxPython. I've found plenty of tutorials on how to do basic GUI stuff
with Tkinter, but that stuff pretty much ends with the core Tk widgets
(buttons, entry fields, scrollbars, and menu items).

Coming from Tcl/Tk, where there are a huge number of extension packages
to enhance the Tk widgets and which allow you to make really polished
GUI's, I'm struck mainly by how little of this stuff has made it over
into Tkinter/Python. For instance, I've developed several Tcl
applications that use the core Tk widgets, the Tile theming package, the
Bwidget set (great tree widget and listbox, which allows you to embed
images), and tablelist (an extremely flexible muti-column listbox
display). I've found Python wrappers for some of this stuff, but almost
no documentation on how to use them, and very little in the way of
actual applications making use of them--which is itself a red flag. And
most of the pure-Python extension stuff that I've found, such as Python
megawidgets, is pretty dated/ugly and lags far behind the comparable
stuff on the Tcl side.

Am I better off biting the bullet and learning wxPython--a different GUI
paradigm to go with the new language I'm trying to learn? I had hoped to
reduce my learning curve, but I'm very concerned that I simply can't do
what I want to do with Tkinter. What do other Tkinter developers think?
Oct 19 '06
32 7490

Kevin Walzer wrote:
I'm a Tcl/Tk developer who has been working, slowly, at learning Python,
in part because Python has better support for certain kinds of
applications that I want to develop than Tcl/Tk does. Naturally, I
thought that I would use Tkinter as the GUI for these programs. However,
in doing research into GUI development techniques, sample code, and
showcase applications, what has struck me is how little sophisticated
GUI development seems to be done in Tkinter as compared to, say,
wxPython. I've found plenty of tutorials on how to do basic GUI stuff
with Tkinter, but that stuff pretty much ends with the core Tk widgets
(buttons, entry fields, scrollbars, and menu items).

Coming from Tcl/Tk, where there are a huge number of extension packages
to enhance the Tk widgets and which allow you to make really polished
GUI's, I'm struck mainly by how little of this stuff has made it over
into Tkinter/Python. For instance, I've developed several Tcl
applications that use the core Tk widgets, the Tile theming package, the
Bwidget set (great tree widget and listbox, which allows you to embed
images), and tablelist (an extremely flexible muti-column listbox
display). I've found Python wrappers for some of this stuff, but almost
no documentation on how to use them, and very little in the way of
actual applications making use of them--which is itself a red flag. And
most of the pure-Python extension stuff that I've found, such as Python
megawidgets, is pretty dated/ugly and lags far behind the comparable
stuff on the Tcl side.

Am I better off biting the bullet and learning wxPython--a different GUI
paradigm to go with the new language I'm trying to learn? I had hoped to
reduce my learning curve, but I'm very concerned that I simply can't do
what I want to do with Tkinter. What do other Tkinter developers think?
Tkinter is certainly dated (?), worst than PMW which is built upon it.

But what do you what/need?
I use , and am making my students use Tkinter for a web multiu-user
client-server XXXX game. The Canvas is a great object, but you have to
write the code yourself, if you want a special look.
Eye-candy, Tkinter ain't, and it doesn't have a lot of sophisticated
widgets (again ?) . I wanted a tabbed pane last year and made myself
one (not the exact look of others, but functional if what you want is
multiple frames of widgets for each tab; the table widget took quite a
bit of doing, also and it's not an Excel spreadsheet)

I do know that people are impressed by glitz and glamour (And I don't
have a nice tree (with picture) widget)

But all of this does forget that Tkinter is still in the standard
library, while all others are third-party add-ons... so there is a
extra hassle with them...

So, what do You want? (widgets, criterias etc)

Jean-Marc

Oct 20 '06 #11
Paul Rubin wrote:
I have yet to see a gui toolkit which doesn't suck. I'm not sure why
that is.
Have you seen PyGUI? It's my attempt at creating
a GUI toolkit for Python that doesn't suck. I'd
be interested to know if you think I've come
anywhere near to succeeding.

http://www.cosc.canterbury.ac.nz/greg.ewing/python_gui/

--
Greg
Oct 21 '06 #12
Paul Rubin wrote:
I have yet to see a gui toolkit which doesn't suck. I'm not sure why
that is.
Have you seen PyGUI? It's my attempt at creating
a GUI toolkit for Python that doesn't suck. I'd
be interested to know if you think I've come
anywhere near to succeeding.

http://www.cosc.canterbury.ac.nz/greg.ewing/python_gui/

--
Greg
Oct 21 '06 #13
greg <gr**@cosc.cant erbury.ac.nzwri tes:
Have you seen PyGUI? It's my attempt at creating a GUI toolkit for
Python that doesn't suck. I'd be interested to know if you think
I've come anywhere near to succeeding.

http://www.cosc.canterbury.ac.nz/greg.ewing/python_gui/
I hadn't seen it. I just spent a couple minutes looking at the docs.
I didn't really get that much sense of what it's like. I may look at
it some more later. However, like tkinter, it seems pretty low level.
I do like that it doesn't rely on the user knowing anything about a
completely separate language, in order to program the gui from Python.
Oct 21 '06 #14

Christophe wrote:
Nobody mentionned it, but I think you should try PyQT and PyGTK before
wxPython. Myself, I do not like wx : it looks too much like the MFC.

PyGTK is good, but GTK doesn't work that well on windows.
GTK and PyGTK works well on Windows now. GTK used to be unstable on
Windows, but that has been taken care of. I would not use anything else
but PyGTK for GUI development in Python. Go here to get the Windows
port:

http://www.mapr.ucl.ac.be/~gustin/win32_ports/

With PyGTK and GLADE, the GUI can be designed in GLADE and imported as
an XML-resource (using libglade). It saves us of all the tedious
GUI-programming. All that is needed is the event handlers, which we
obviously have to code. When they are done, we simply put references to
them in a dictionary, and tell libglade to dispacth on it. All the GUI
programming crap is hidden away. Since there is no actual GUI code in
Python, it also makes maintenance and upgrading much easier: The GUI
can be redesigned in GLADE without affecting the Python code. Have you
ever tried to change anything in an MFC project with Visual C++? It's a
nightmare.

Oct 21 '06 #15
sturlamolden wrote:
Christophe wrote:
>Nobody mentionned it, but I think you should try PyQT and PyGTK before
wxPython. Myself, I do not like wx : it looks too much like the MFC.

PyGTK is good, but GTK doesn't work that well on windows.

GTK and PyGTK works well on Windows now. GTK used to be unstable on
Windows, but that has been taken care of. I would not use anything else
but PyGTK for GUI development in Python. Go here to get the Windows
port:

http://www.mapr.ucl.ac.be/~gustin/win32_ports/

With PyGTK and GLADE, the GUI can be designed in GLADE and imported as
an XML-resource (using libglade). It saves us of all the tedious
GUI-programming. All that is needed is the event handlers, which we
obviously have to code. When they are done, we simply put references to
them in a dictionary, and tell libglade to dispacth on it. All the GUI
programming crap is hidden away. Since there is no actual GUI code in
Python, it also makes maintenance and upgrading much easier: The GUI
can be redesigned in GLADE without affecting the Python code. Have you
ever tried to change anything in an MFC project with Visual C++? It's a
nightmare.
I'm a Mac developer--Gtk does not run natively on the Mac (i.e. as an
Aqua framework), only under X11. So that's a non-starter for me.
Oct 21 '06 #16
I'm a Mac developer--Gtk does not run natively on the Mac (i.e. as an
Aqua framework), only under X11. So that's a non-starter for me.

Besides the excellent PyObjc-bridge that of course only works for
Mac-only-development, you might consider PyQt. Biggest drawback: the
GPL-license. But feature-wise, it beats IMHO all other toolkits.

It looks pretty well under OSX. Not absolutely perfect, but certainly
better that the alternatives. Google earth for example is created with
it, at least in the Mac-incarnation.

Diez
Oct 21 '06 #17

Kevin Walzer wrote:
sturlamolden wrote:
Christophe wrote:
Nobody mentionned it, but I think you should try PyQT and PyGTK before
wxPython. Myself, I do not like wx : it looks too much like the MFC.

PyGTK is good, but GTK doesn't work that well on windows.
GTK and PyGTK works well on Windows now. GTK used to be unstable on
Windows, but that has been taken care of. I would not use anything else
but PyGTK for GUI development in Python. Go here to get the Windows
port:

http://www.mapr.ucl.ac.be/~gustin/win32_ports/

With PyGTK and GLADE, the GUI can be designed in GLADE and imported as
an XML-resource (using libglade). It saves us of all the tedious
GUI-programming. All that is needed is the event handlers, which we
obviously have to code. When they are done, we simply put references to
them in a dictionary, and tell libglade to dispacth on it. All the GUI
programming crap is hidden away. Since there is no actual GUI code in
Python, it also makes maintenance and upgrading much easier: The GUI
can be redesigned in GLADE without affecting the Python code. Have you
ever tried to change anything in an MFC project with Visual C++? It's a
nightmare.
I'm a Mac developer--Gtk does not run natively on the Mac (i.e. as an
Aqua framework), only under X11. So that's a non-starter for me.
You have 2 choices then wxWidgets or Qt.
wx has also graphical editors like Glade (there is a wxGlade project)
giving a xml description of a window and its cross platform.
I know there are graphical for Qt but i dont know if theyre giving xml
or are just code-generators.
You could also do gui in Java or .Net and use python with their native
interpreter (jython is a bit outdated but IronPython is "online")
You can also use a local web app with one of cool Python'ish web
frameworks -- id suggest TurboGears, but you can choose from many ill
mention Django (which is i think the biggest rival for TG)

On the other hand its a pity that there isnt much choice in cross
platform (win mac lin) GUI platforms until now i was a great fan of GTK
but there isnt a proper port for Mac.
Its also a pity that no one didnt do something based on OpenGL with
python (or maybe im wrong) it could be cool and really cross-platform.

Oct 21 '06 #18

Kevin Walzer wrote:
I'm a Mac developer--Gtk does not run natively on the Mac (i.e. as an
Aqua framework), only under X11. So that's a non-starter for me.
GTK is skinnable and can look a lot like Aqua. Qt is also just
pretending to be a native Aqua toolkit (or used to), but it is very
good at it.

That leaves you with wxPython (utterly ugly API, remninds me of MFC and
Motif), PyQt (very expensive unless GPL is not a show stopper) or
PyObjC.

http://pyobjc.sourceforge.net/
http://pyobjc.sourceforge.net/doc/tutorial.php

If you are willing to use Jython, you can get a native Aqua GUI from
Java.

Does at GUI really have to be "native"? I never hear anyone complain
about the looks of Microsoft Office or Mozilla Firefox on Windows,
although neither have a "native" GUI.

Oct 21 '06 #19

Wektor wrote:
wx has also graphical editors like Glade (there is a wxGlade project)
giving a xml description of a window and its cross platform.
If you are thinking about XRC, then beware that this XML don't solve
any problems, it just creates another. XRC and libglade do not compare.
libglade makes the GUI development easy and the program code clean and
easy to read. XRC makes the GUI development difficult and the program
code convoluted and difficult to read.

Also wxGlade is not GLADE. In particular, wxGlade is unstable and tend
to crash or do stupid things. But if your oalternative is to hand-code
the wxPython GUI, then wxGLADE is nevertheless the better option.
On the other hand its a pity that there isnt much choice in cross
platform (win mac lin) GUI platforms until now i was a great fan of GTK
but there isnt a proper port for Mac.
GTK is being ported to Aqua, but the port it is in its early stages.
Its also a pity that no one didnt do something based on OpenGL with
python (or maybe im wrong) it could be cool and really cross-platform.
You are wrong. There are PyOpenGL and there is cross-platform GUI and
game development platforms that use it (PyGTK, wxPython, PyGame). There
are also PyOgre, which are more pythonic than using OpenGL directly.

Oct 21 '06 #20

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

72
6982
by: Wim Vanhoof | last post by:
Dear all, I would like to announce that the department of computer science of the University of Namur, Belgium, is seeking a post-doctoral researcher for a one-year fellowship in the area of (logic-based) program development, analysis and transformation.
4
1816
by: Rob Meade | last post by:
....little function for count lines of code? I was going to do this a little while ago, hoping to count each line in each file in each folder etc etc, and then determine whether it was say ASP, HTML or comments....and give totals... Anyone got anything like this they dont mind sharing? Just curious...
37
2898
by: seberino | last post by:
I've been reading the beloved Paul Graham's "Hackers and Painters". He claims he developed a web app at light speed using Lisp and lots of macros. It got me curious if Lisp is inherently faster to develop complex apps in. It would seem if you could create your own language in Lisp using macros that that would be quite an advantage.... I realize that Python has operator overloading and OOP so I'm not sure.
0
2048
by: M.sajjad | last post by:
Five Steps to Rapid Development with TierDeveloper 3.0 Unlock the power of rapid development when you use TierDeveloper from AlachiSoft in your N-Tier application development. Follow the steps below to quickly design, generate, and deploy a great portion of your real-life N- Tier application. For free evaluation download please visit http://www.alachisoft.com/download.htm
6
1411
by: strvariant | last post by:
I'd like to get some feedback on what I call 'Analysis Bleed'. In past jobs I have noticed a trend that starts to develop after about 6 months. Once an employer sees that the apps I develop are doing what they wanted I always get asked to provide reports. Okay --- that's a primary function that the app provides, I'll write the reports like you want. But this seems to always lead to the employer requesting more and more reports and putting...
169
9165
by: JohnQ | last post by:
(The "C++ Grammer" thread in comp.lang.c++.moderated prompted this post). It would be more than a little bit nice if C++ was much "cleaner" (less complex) so that it wasn't a major world wide untaking to create a toolchain for it. Way back when, there used to be something called "Small C". I wonder if the creator(s) of that would want to embark on creating a nice little Small C++ compiler devoid of C++ language features that make...
2
201
by: dp_pearce | last post by:
I have some code that takes data from an Access database and processes it into text files for another application. At the moment, I am using a number of loops that are pretty slow. I am not a hugely experienced python user so I would like to know if I am doing anything particularly wrong or that can be hugely improved through the use of another method. Currently, all of the values that are to be written to file are pulled from the...
0
2839
by: texsum | last post by:
this article intends to share the experience of running projects using development software interfaces in the organization of Agile. And to have the opportunity to join the team used this method to see the different perspectives. From reading or hearing from others I think that would be useful for readers to be studied and applied. Or supplement the existing development process. The important thing to remember is always Agile methods no fixed...
0
9456
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9275
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10040
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9873
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9713
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7248
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5304
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3359
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2666
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.