我有3个水平面板,我需要6个面板和6个面板中的3个子面板,如这张图片:
我不知道该怎么做,这是我的代码:
import wx
class MainFrame(wx.Frame):
def __init__(self,parent):
wx.Frame.__init__(self,parent,title="myapp",size = (800,500))
self.left = wx.Panel(self ,style = wx.SUNKEN_BORDER,size=(200,-1))
self.center = wx.Panel(self ,style = wx.SUNKEN_BORDER,size=(250,400))
self.right = wx.Panel(self ,style = wx.SUNKEN_BORDER,size=(250,400))
self.right.SetBackgroundColour('white')
sizer1 = wx.BoxSizer(wx.HORIZONTAL)
sizer1.Add(self.left,0,wx.EXPAND)
sizer1.Add(self.center,1,wx.EXPAND)
sizer1.Add(self.right,1,wx.EXPAND)
self.SetSizer(sizer1)
self.Show()
app = wx.App()
frame=MainFrame(None).Show()
app.MainLoop()
感谢您的帮助