[PyCrust-cvs] wx/examples/basic frame.py,NONE,1.1 app.py,NONE,1.1 __init__.py,NONE,1.1 .cvsignore,NO
Brought to you by:
pobrien
From: <po...@us...> - 2003-03-21 16:55:34
|
Update of /cvsroot/pycrust/wx/examples/basic In directory sc8-pr-cvs1:/tmp/cvs-serv3501/examples/basic Added Files: frame.py app.py __init__.py .cvsignore Log Message: New examples. --- NEW FILE: frame.py --- #!/usr/bin/env python """Basic frame class, with App for testing.""" __author__ = "Patrick K. O'Brien <po...@or...>" __cvsid__ = "$Id: frame.py,v 1.1 2003/03/21 16:21:16 pobrien Exp $" __revision__ = "$Revision: 1.1 $"[11:-2] import wx class Frame(wx.Frame): """Frame class.""" def __init__(self, parent=None, id=-1, title='Title', pos=wx.DefaultPosition, size=(400, 200)): """Create a Frame instance.""" wx.Frame.__init__(self, parent, id, title, pos, size) class App(wx.App): """Application class.""" def OnInit(self): self.frame = Frame() self.frame.Show() self.SetTopWindow(self.frame) return True def main(): app = App() app.MainLoop() if __name__ == '__main__': main() --- NEW FILE: app.py --- #!/usr/bin/env python """Basic application class.""" __author__ = "Patrick K. O'Brien <po...@or...>" __cvsid__ = "$Id: app.py,v 1.1 2003/03/21 16:21:17 pobrien Exp $" __revision__ = "$Revision: 1.1 $"[11:-2] import wx from frame import Frame class App(wx.App): """Application class.""" def OnInit(self): self.frame = Frame() self.frame.Show() self.SetTopWindow(self.frame) return True def main(): app = App() app.MainLoop() if __name__ == '__main__': main() --- NEW FILE: __init__.py --- # Python package. --- NEW FILE: .cvsignore --- *.pyc |