[Tutor] Tkinter problems

Thomi Richards thomi@thomi.imail.net.nz
Fri Nov 15 04:18:02 2002


Hey all,

I'm hoping someone could help me with Tkinter. I've never done any sort
of GUI programming before, but I've written a program which needs a
simple GUI interface. nothing special, just a few "open file" dialog
boxes, somewhere for me to print output, and a "save as" dialog box.
I've been reading the documentation at
http://www.pythonware.com/library/tkinter/introduction/
and I have a few questions:

firstly, how do i get the users response back into a variable, from say
a yes/no box? I need it to return a string saying "yes" or "no" or
something similar. same with open file and close file dialog boxes,
except then I'll need a filename.

also, with the open file and save file dialog boxes, are there are
pre-made ones i can use? it looks like a lot of work to code in all the
information about browsing around the hard drive, the buttons, blah blah
blah. surely someone else has made a pre-defined version?

lastly, what widget do i want to use, if i want to display text on a
screen, and have it scrolling down, as more text appears? I originally
thought i could just use the label thingie, but what happens when it
hits the end of the window? from the documentation, it would seem like
the window would just expand, instead of scrolling the text.

finally, how the hell are you meant to do anything, if the mainloop
function hangs? how can i get my program to run, after i run that
command? 

I get the idea I'm waaaaay off target here, and any help would be most
appreciated.

yours in frustration,

-- 
Thomi Richards
thomi@imail.net.nz
http://ddmodd.sourceforge.net/
Thomi Richards,
thomi@imail.net.nz