Odd middle split in my pane?

Hello all, I hope this is the right place for my questions… I’m working on a POC that contains what I need to do and I’m having trouble with my pane being split in half.

I definitely need to be able to save a complex layout of AuiNotebook items so that my users can restore their views later on, so if this code isn’t going to work for that I’d like to know that too.

If you look at “PanelOneNest” and “PanelTwoNest” in “PanelOne” you can see that they are divided in half. I’m not sure what I did to cause this! Please help, thank you!

import wx

import wx.lib.agw.aui as aui

class TabPanelOne(wx.Panel):

def init(self, parent):

wx.Panel.init(self, parent=parent, id=wx.ID_ANY)

sizer = wx.BoxSizer(wx.VERTICAL)

txtOne = wx.TextCtrl(self, wx.ID_ANY, “”)

txtTwo = wx.TextCtrl(self, wx.ID_ANY, “”)

sizer = wx.BoxSizer(wx.VERTICAL)

sizer.Add(txtOne, 0, wx.ALL, 5)

sizer.Add(txtTwo, 0, wx.ALL, 5)

self.SetSizer(sizer)

class PanelCaseDetails(wx.Panel):

def init(self, parent, _mgr):

wx.Panel.init(self, parent=parent, id=wx.ID_ANY)

sizer = wx.BoxSizer(wx.VERTICAL)

notebook = aui.AuiNotebook(self)

panelOneNest = TabPanelOne(notebook)

panelTwoNest = TabPanelOne(notebook)

notebook.AddPage(panelOneNest, “PanelOneNest”, False)

notebook.AddPage(panelTwoNest, “PanelTwoNest”, False)

_mgr.AddPane(notebook,

                aui.AuiPaneInfo().Name("notebook_content_child").

                CenterPane().PaneBorder(False))

self.SetSizer(sizer)

class MainFrame(wx.Frame):

def init(self):

wx.Frame.init(self, None, wx.ID_ANY,

                      "AGW AUI Notebook Tutorial",

                      size=(600,400))

self._mgr = aui.AuiManager()

self._mgr.SetManagedWindow(self)

notebook = aui.AuiNotebook(self)

panelOne = PanelCaseDetails(notebook, self._mgr)

panelTwo = TabPanelOne(notebook)

notebook.AddPage(panelOne, “PanelOne”, False)

notebook.AddPage(panelTwo, “PanelTwo”, False)

self._mgr.AddPane(notebook,

                      aui.AuiPaneInfo().Name("notebook_content").

                      CenterPane().PaneBorder(True))

self._mgr.Update()

print(self._mgr.SavePerspective())

#notebook.EnableTab(0, False) #this doesn’t go here but may be useful later

if name == “main”:

app = wx.PySimpleApp()

frame = MainFrame()

frame.Show()

app.MainLoop()