Re: [Tutor] Tkinter Q's

2005-07-13 Thread jfouhy
Quoting Joseph Quigley <[EMAIL PROTECTED]>: > Hi, > what's the **kw stand for, used for? What does it mean? Sorry about that. A couple of people have already answered; I'll just give you a couple of examples which might help you understand: >>> def showArgs(**kw): ... print kw ... >>> s

Re: [Tutor] Tkinter Q's

2005-07-13 Thread Michael Lange
On Wed, 13 Jul 2005 08:13:42 + Joseph Quigley <[EMAIL PROTECTED]> wrote: > Hi, > what's the **kw stand for, used for? What does it mean? > **kw means that there is an optional list of keyword arguments that you can pass to __init__ (for example: main = Main(background="black") ). Key

Re: [Tutor] Tkinter Q's

2005-07-13 Thread Sandip Bhattacharya
Joseph Quigley wrote: > Hi, > what's the **kw stand for, used for? What does it mean? > > [...] >> >>class Main(Frame): >> def __init__(self, master=None, **kw): >> Frame.__init__(self, master, **kw) >> It is the python way to pass along all keyword arguments (xxx=yyy). So in t

Re: [Tutor] Tkinter Q's

2005-07-13 Thread Joseph Quigley
Hi, what's the **kw stand for, used for? What does it mean? > Some comments --- > > You create a Frame, but you never use it. > > You've put a whole lot of code in a class, but it's not in a class method. > This > is kinda missing the point of using classes in the first place (and it j

Re: [Tutor] Tkinter Q's

2005-07-12 Thread jfouhy
Quoting Joseph Quigley <[EMAIL PROTECTED]>: > Hi first off, here's my code: > > # -*- coding: utf-8 -*- > from Tkinter import * > import random > import time > import about > import quotes > > > def closeprog(): > raise SystemExit > > class main: > root = Tk() > frame = Frame() > root.titl

Re: [Tutor] Tkinter Q's

2005-07-12 Thread Michael Lange
On Mon, 11 Jul 2005 17:22:57 + Joseph Quigley <[EMAIL PROTECTED]> wrote: Hi, Joseph, > Hi first off, here's my code: > > # -*- coding: utf-8 -*- > from Tkinter import * > import random > import time > import about > import quotes > > > def closeprog(): > raise SystemExit > > class ma

[Tutor] Tkinter Q's

2005-07-12 Thread Joseph Quigley
Hi first off, here's my code: # -*- coding: utf-8 -*- from Tkinter import * import random import time import about import quotes def closeprog():     raise SystemExit class main:     root = Tk()     frame = Frame()     root.title("Quoter %s" % (about.ver))     root.minsize(300, 50)     sho