2 toolbars not allowed ?

hello,

I need 2 toolbars, but apparently this is not allowed.
Is that correct ?

thanks,
Stef Mientki

I've got 2 toolbars in my application. Did you remember to call
Realize() ?

toolbar1 = wx.Toolbar(self, -1, style=wx.TB_HORIZONTAL|wx.TB_FLAT)
toolbar1.Add(some_widget)
toolbar1.Realize()

toolbar2 = wx.Toolbar(self, -1, style=wx.TB_HORIZONTAL|wx.TB_FLAT)
toolbar2.Add(some_widget)
toolbar2.Realize()

sizer = wx.BoxSizer(wx.VERTICAL)
sizer.Add(toolbar1)
sizer.Add(toolbar2)
self.SetSizer(sizer)

-Kyle Rickey

···

-----Original Message-----
From: Stef Mientki [mailto:s.mientki@ru.nl]
Sent: Thursday, January 03, 2008 1:20 PM
To: wxPython-users@lists.wxwidgets.org
Subject: [wxPython-users] 2 toolbars not allowed ?

hello,

I need 2 toolbars, but apparently this is not allowed.
Is that correct ?

thanks,
Stef Mientki

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org

thanks Kyle Ricky and Christopher,

I was using CreateToolBar,
and indeed managing the ToolBar yourself,
allows for 2 toolbar.
As a pleasant side-effect,
the bug in the extra space in the bottom toolbar even reduces to a few pixels !

cheers,
Stef

Christopher Barker wrote:

···

I need 2 toolbars, but apparently this is not allowed.
Is that correct ?

You can do it if you mange their positioning themselves:

WorkingWithToolBars - wxPyWiki

-Chris