Please help - Tkinter not doing anything

s0suk3 at gmail.com s0suk3 at gmail.com
Sun May 4 22:54:09 EDT 2008


On May 4, 6:59 am, Protected <myshel... at gmail.com> wrote:
> On May 4, 12:18 pm, s0s... at gmail.com wrote:
>
>
>
> > On May 4, 5:22 am, Protected <myshel... at gmail.com> wrote:
>
> > > I had previously ran the import line. I prepended it to the example
> > > code I'm trying to run every time but it did not help, still nothing
> > > happens. With or without var before 'root'. I'm pasting the code in
> > > IDLE and using Windows XP as written in the first post.
>
> > Tkinter doesn't work if you type the statements in IDLE. I don't
> > remember the specifics of it, but essentially it doesn't work because
> > IDLE is itself a Tkinter app. You have to type it at the Python
> > command line or save it in a file. BTW, if you're on Windows, you
> > should definitely check wxPython. I used to work with Tkinter,
> > struggling with it all the time only to get a lame result most of the
> > time. Then I switched to wxPython, and in the same week I was learning
> > it I did a better GUI than I ever did in Tkinter (with months of
> > work!). I feel it makes it easier to make your program have a better
> > structure and design, and thus lets you focus on the actual task of
> > the program, rather than in the GUI itself. Plus, on Windows, you'll
> > get the widgets to look more natively, like any good quality
> > application there is on Windows.
>
> Ah, but is it cross platform?
>
> (Thanks for letting me know about IDLE.)

Of course. I forgot to say about that. It is cross platform, like most
things in Python. I'd say it's actually more cross platform than
Tkinter, because of the looks of both in different platforms. In
Tkinter, you can get all the widgets to work in all the platforms it
supports, but the widgets look so different on different platforms,
that at the end you end up modifying the code anyway so that the
controls look better on the platform that you port the program to.
With what I've done with wxPython, the controls look great on any of
the platforms I've tried my programs in. Another thing: wxPython is a
port of the wxWidgets toolkit which is for C++. It has also been
ported to a bunch of other languages like Ruby, Perl, C#, etc; so if
you learn any of the languages which wxWidgets has been ported to, you
can use the toolkit in the same way that you've been doing with
Python, except that with the syntax of the other language.



More information about the Python-list mailing list