toaster boxes...

Hi all,
Thanks to Steven, I am looking into using a toasterbox. I want a way
to pop up some text for a few seconds, like a balloon in the lower
right of the screen. However, in the line

box=tb.__init__(tbstyle='TB_SIMPLE', closingstyle='TB_ONCLICK',
windowstyle='DEFAULT_TB_STYLE')

I imported wx.lib.agw.toasterbox as tb, by the way, and copied the
above line almost exactly from the toasterbox tutorial wiki. I get the
error:

module.__init__ takes at most two arguments (three given).

I am not sure why this error is showing up. I thought all the
arguments I am passing were allowed? If I remove one, then it says it
is missing a 'pos' argument. Do I need to do all this inside a class
or something? Keep in mind that I have only been really getting into
Python for a couple months (but I know Java and a couple other
languages pretty well). Thanks.

···

--
Have a great day,
Alex (msg sent from GMail website)
mehgcap@gmail.com; http://www.facebook.com/mehgcap

Hi,

Hi all,
Thanks to Steven, I am looking into using a toasterbox. I want a way
to pop up some text for a few seconds, like a balloon in the lower
right of the screen. However, in the line

box=tb.__init__(tbstyle='TB_SIMPLE', closingstyle='TB_ONCLICK',
windowstyle='DEFAULT_TB_STYLE')

I imported wx.lib.agw.toasterbox as tb, by the way, and copied the
above line almost exactly from the toasterbox tutorial wiki. I get the
error:

module.__init__ takes at most two arguments (three given).

I am not sure why this error is showing up. I thought all the
arguments I am passing were allowed? If I remove one, then it says it
is missing a 'pos' argument. Do I need to do all this inside a class
or something? Keep in mind that I have only been really getting into
Python for a couple months (but I know Java and a couple other
languages pretty well). Thanks.

Please see the ToasterBox demo in the wxPython main demo. An example
for the constructor may be:

tb = TB.ToasterBox(self, tbstyle, windowstyle, closingstyle)

Where "self" is the ToasterBox parent. In any case, unless you are
subclassing ToasterBox, you don't want to call its __init__ method as
you are doing. The __init__ method is automatically called by Python
when you instantiate ToasterBox as I did above.

Andrea.

"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.alice.it/infinity77/

==> Never *EVER* use RemovalGroup for your house removal. You'll
regret it forever. <==

···

On 15 March 2010 13:52, Alex Hall wrote: