[Tkinter-discuss] updated article: a controller class for Tkinter

2006-10-24 Thread Fredrik Lundh
in case someone on this list is interested in an easier way to implement interactive tools for Tkinter applications, here's a short article about pluggable controllers in Tkinter: http://effbot.org/zone/tkcontroller.htm the code can also be downloaded from a subversion repository: ht

Re: [Tkinter-discuss] question on tab window

2006-10-24 Thread Cameron Laird
On Tue, Oct 24, 2006 at 02:40:38PM +, V H wrote: . . . > Does Tkinter offer some simple solution for creating tab windows? Some > examples? . . . "tab

[Tkinter-discuss] Tkinter question

2006-10-24 Thread Sorin Schwimmer
Thanks for everybody's advice, on both forums (tkinter-discuss & python-list).I end up using Fredrik's Lundh solution, since, in my project, multiple buttons are using the same callback, and their creation is controlled by the interaction with the user.Thanks again,Sorin

Re: [Tkinter-discuss] question on tab window

2006-10-24 Thread Cameron Laird
On Tue, Oct 24, 2006 at 02:40:38PM +, V H wrote: . . . > Does Tkinter offer some simple solution for creating tab windows? Some > examples? . . . When

Re: [Tkinter-discuss] OptionMenu, change the list of choices

2006-10-24 Thread Cameron Laird
On Tue, Oct 24, 2006 at 05:30:28PM +0200, Vasilis Vlachoudis wrote: . . . > changed (see below). Is it really necessary all the lambda... function I > am doing or there is a smarter way of doing the job?

Re: [Tkinter-discuss] OptionMenu, change the list of choices

2006-10-24 Thread Vasilis Vlachoudis
Thank you very much. It seems it works. How ever, if I don't use a command=lambda... in the add_command I cannot get the OptionMenu value changed (see below). Is it really necessary all the lambda... function I am doing or there is a smarter way of doing the job? Regards Vasillis fro

Re: [Tkinter-discuss] question on tab window

2006-10-24 Thread Bencsik Roland
Hi, Altough it is a quite old package (August 4, 2003) you may try Python megawidgets: http://pmw.sourceforge.net/ There is a good demo included showing its widgets in action. Roland V H wrote: > Hi, > > Does Tkinter offer some simple solution for creating tab windows? Some > examples? > > b

Re: [Tkinter-discuss] Tkinter question

2006-10-24 Thread Hendrik van Rooyen
Sorin Schwimmer wrote: Hi All, Is it possible to have a widget id while it is created? Something like this: Button(root, text='...', command= lambda v=: fn(v)).grid() and then the function: def fn(v): v['bg']='BLUE' # or maybe nametowidget(v)['bg']='BLUE' Thanks, Sorin - just give the t

Re: [Tkinter-discuss] question on tab window

2006-10-24 Thread Asrarahmed Kadri
ARe you referring to toplevel windows...??   If yes, then you can create them as below:   win1 = Toplevel()   win2 = Toplevel()   HTH.   Asrarahmed  On 10/24/06, V H <[EMAIL PROTECTED]> wrote: Hi,Does Tkinter offer some simple solution for creating tab windows? Someexamples?best regards, Weining___

[Tkinter-discuss] question on tab window

2006-10-24 Thread V H
Hi, Does Tkinter offer some simple solution for creating tab windows? Some examples? best regards, Weining _ Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm0020047

Re: [Tkinter-discuss] OptionMenu, change the list of choices

2006-10-24 Thread mkieverpy
Vasilis Vlachoudis wrote: > > values=["One","Two","Three"] # Initial list > o = OptionMenu(frame, *values) > #... > #then later in the code read new values from a file > newvalues = f.readline().split() > o.config(???=newvalues) > With m = o.children ['menu'] you can access the menu which imp

[Tkinter-discuss] OptionMenu, change the list of choices

2006-10-24 Thread Vasilis Vlachoudis
Dear All, I want to use the OptionMenu, in which I want to dynamically change the list of choices. Something like values=["One","Two","Three"] # Initial list o = OptionMenu(frame, *values) #... #then later in the code read new values from a file newvalues = f.readline().split() o.config(???=