Esempio n. 1
0
    def __init__(self, parent, id, title):
    #---------------------------------------------------------------------------
        width, height = wx.DisplaySize()
        wx.Frame.__init__(self, parent, id, title, wx.DefaultPosition, \
                          wx.Size(min([800,width]),min([800,height])))

        self.classifier = None
        self.settingsFilename = None

        # Status Bar
        statusBar = self.CreateStatusBar()

        # Menu    
        menuBar = wx.MenuBar()
        menuBar.Append(self.CreateFileMenu(), "&File")
        menuBar.Append(self.CreateClassifierMenu(), "&Classifier")
        self.SetMenuBar(menuBar)

        # Notebook with tabs
        self.notebook = wx.Notebook(self, -1)
        self.settingsPanel = SettingsPanel(self.notebook, -1, self)
        self.statusPanel = StatusPanel(self.notebook, -1, self)
        self.resultPanel = ResultPanel(self.notebook, -1, self)
        self.notebook.AddPage(self.settingsPanel, "Settings")
        self.notebook.AddPage(self.statusPanel, "Status")
        self.notebook.AddPage(self.resultPanel, "Results")

        # timer for status updates
        self.timer = wx.Timer(self, -1)
        self.Bind(wx.EVT_TIMER, self.OnTimerUpdate, self.timer)