How to add wxStaticBox into wxSplitterWindow?

Hello,

I have a problem with wxSplitterWindow and wxStaticBox by getting wrong
control positioning. My code looks in this way:

   [...]
   
   splitter = wxSplitterWindow(self, -1)

   sb = wxStaticBox(splitter, -1, "List")
   sbSizer = wxStaticBoxSizer(sb, wxVERTICAL)

   list = wxListBox(splitter, id, wxDefaultSize, wxDefaultPosition,
                    [], wxLB_SINGLE)
   sbSiser.AddWindow(list, 1, wxALL, 3)

   html = HtmlWindow(splitter, -1)

   splitter.SplitVertically(list, html)

   [...]

The static box with the title is in its place, but the list itself is
floating somewhere at the left top and don't fill the left part of the
splitter.

I have no problems with wxStaticBox when adding it somewhere else, not in the
splitter. I have read the http://wiki.wxwindows.org/wiki.pl?WxSizer but I
still have this problem using wxSplitterWindow. Could anybody explain and
give an example how to use them?

Martynas

···

--
There is more vision than meets the eye.
http://mjoc.sig.lt

I've tried to use wxPanel for the main container and now everything is ok. I
add wxStaticBoxSizer into wxPanel object with SetSizer() method, wxPanel is
a child of the splitter, and other controls are the childs of wxPanel
object. Now ir works.

Martynas

···

On Sat, Dec 20, 2003 at 07:47:24AM +0200, Martynas Jocius wrote:

I have a problem with wxSplitterWindow and wxStaticBox by getting wrong
control positioning.

--
There is more vision than meets the eye.
http://mjoc.sig.lt