Re: Tkinter help - Why this behavior ? (py3)

2010-06-09 Thread Terry Reedy
On 6/9/2010 1:13 PM, Dodo wrote: import Tkinter as tk from Tkconstants import * import tkSimpleDialog class MyDialog(tkSimpleDialog.Dialog): def body(self, master): prompt = "Hello from my custom dialog!\nAlthough with something this simple i should have used tkMessageBox." tk.Label(self, text=

Re: Tkinter help - Why this behavior ? (py3)

2010-06-09 Thread Dodo
Le 09/06/2010 19:13, Dodo a écrit : Le 09/06/2010 18:49, rantingrick a écrit : On Jun 5, 8:46 am, Dodo wrote: Hi, let's consider this exemple : from tkinter import * from tkinter.ttk import * class First: def __init__(self): self.root = Tk() B = Button(self.root, command=self.op) B.pack() s

Re: Tkinter help - Why this behavior ? (py3)

2010-06-09 Thread Dodo
Le 09/06/2010 18:49, rantingrick a écrit : On Jun 5, 8:46 am, Dodo wrote: Hi, let's consider this exemple : from tkinter import * from tkinter.ttk import * class First: def __init__(self): self.root = Tk() B = Button(self.root, command=self.op)

Re: Tkinter help - Why this behavior ? (py3)

2010-06-09 Thread rantingrick
On Jun 5, 8:46 am, Dodo wrote: > Hi, > > let's consider this exemple : > > from tkinter import * > from tkinter.ttk import * > > class First: >         def __init__(self): >                 self.root = Tk() >                 B = Button(self.root, command=self.op) >                 B.pack() > >    

Re: Tkinter help - Why this behavior ? (py3)

2010-06-09 Thread Dodo
Le 07/06/2010 15:26, Alf P. Steinbach a écrit : * Dodo, on 07.06.2010 12:38: Le 05/06/2010 19:07, Alf P. Steinbach a écrit : * Dodo, on 05.06.2010 15:46: Hi, let's consider this exemple : from tkinter import * from tkinter.ttk import * class First: def __init__(self): self.root = Tk() B = B

Re: Tkinter help - Why this behavior ? (py3)

2010-06-07 Thread Alf P. Steinbach
* Dodo, on 07.06.2010 12:38: Le 05/06/2010 19:07, Alf P. Steinbach a écrit : * Dodo, on 05.06.2010 15:46: Hi, let's consider this exemple : from tkinter import * from tkinter.ttk import * class First: def __init__(self): self.root = Tk() B = Button(self.root, command=self.op) B.pack() self.

Re: Tkinter help - Why this behavior ? (py3)

2010-06-07 Thread Dodo
Le 05/06/2010 19:07, Alf P. Steinbach a écrit : * Dodo, on 05.06.2010 15:46: Hi, let's consider this exemple : from tkinter import * from tkinter.ttk import * class First: def __init__(self): self.root = Tk() B = Button(self.root, command=self.op) B.pack() self.root.mainloop() def op(self):

Re: Tkinter help - Why this behavior ? (py3)

2010-06-05 Thread Alf P. Steinbach
* Dodo, on 05.06.2010 15:46: Hi, let's consider this exemple : from tkinter import * from tkinter.ttk import * class First: def __init__(self): self.root = Tk() B = Button(self.root, command=self.op) B.pack() self.root.mainloop() def op(self): Second(self) print("print") class Second: def

Re: Tkinter help, please...

2007-05-24 Thread Medi Ochre
John McMonagle wrote: > I've made a couple of minor changes to your code from the Cribbage class > down: > > class Cribbage: > def __init__(self, win): > ... > score = run.play() > if score >= best: best = score > time.sleep(1) <--- short sleep to see what's

Re: Tkinter help, please...

2007-05-24 Thread John McMonagle
I've made a couple of minor changes to your code from the Cribbage class down: class Cribbage: def __init__(self, win): self.parent = win# < make the toplevel Tk window an # < attribute of the class #Draw the interface

Re: tkinter help

2006-07-18 Thread Harold Fellermann
hi, groves wrote: > Now let me tell you that i was able to create a simple listbox which > had 6 options which one can select, but Now what I want is that from > the available menu, if I select an option it should give me another > menu associated with that option. Its like digging up that option

Re: tkinter help

2006-07-18 Thread John McMonagle
On Tue, 2006-07-18 at 08:37 -0700, groves wrote: > hi eveyrbody , i have started working on python tkinter, > While I was working on one of the tkinter classes..named listbox > widget. I had a slight problem. > > Now let me tell you that i was able to create a simple listbox which > had 6 options

Re: tkinter help

2006-07-18 Thread faulkner
add a xscrollcommand and/or yscrollcommand keyword argument to the construction of your listbox. def func(*a): print "i'm a callback!" L = Tkinter.Listbox(root, yscrollcommand=func)# note no parens after func groves wrote: > hi eveyrbody , i have started working on python tkinter, > Whi