wxpython: how do i write this without the id parameter?

Scott David Daniels scott.daniels at acm.org
Wed Jun 14 13:09:25 EDT 2006


John Salerno wrote:
> Scott David Daniels wrote:
> 
>> class InputForm(wx.Frame):
>>     def __init__(self, parent=None, id=-1, title=__file__):
> 
> Also, is there a way to define parent and id with defaults, but not 
> title? Is it good to change the order around to do this?
No, too many things know the first couple of args are parent and id.
If __file__ doesn't work for you, just stick in something for title
and remember to replace it.

     class InputForm(wx.Frame):
         def __init__(self, parent=None, id=-1, title='Input Form"):

--Scott David Daniels
scott.daniels at acm.org



More information about the Python-list mailing list