]> git.saurik.com Git - wxWidgets.git/blame - wxPython/samples/embedded/embedded_sample.py
Implemented Enable for wxMenuBar to avoid assert
[wxWidgets.git] / wxPython / samples / embedded / embedded_sample.py
CommitLineData
2620b36e
RD
1import wx
2from wx.py import shell, version
a2426843 3
2620b36e 4class MyPanel(wx.Panel):
a2426843 5 def __init__(self, parent):
2620b36e 6 wx.Panel.__init__(self, parent, -1)
a2426843
RD
7 print parent
8
2620b36e 9 text = wx.StaticText(self, -1,
a2426843 10 "Everything on this side of the splitter comes from Python.")
2620b36e 11 text.SetFont(wx.Font(12, wx.SWISS, wx.NORMAL, wx.BOLD))
a2426843
RD
12
13 intro = 'Welcome To PyCrust %s - The Flakiest Python Shell' % version.VERSION
14 pycrust = shell.Shell(self, -1, introText=intro)
15 #pycrust = wxTextCtrl(self, -1, intro)
16
2620b36e
RD
17 sizer = wx.BoxSizer(wx.VERTICAL)
18 sizer.Add(text, 0, wx.EXPAND|wx.ALL, 10)
19 sizer.Add(pycrust, 1, wx.EXPAND|wx.BOTTOM|wx.LEFT|wx.RIGHT, 10)
a2426843
RD
20
21 self.SetSizer(sizer)
a2426843 22