(self)
return
Create the menu bar for the application.
Create the menu bar for the application.
Create the menu bar for the application .
def createMenuBar(self):
        """Create the menu bar for the application. """

        self.menu=Menu(self.tablesapp_win)
        self.proj_menu={'01New':{'cmd':self.new_project},
                        '02Open':{'cmd':self.open_project},
                        '03Close':{'cmd':self.close_project},
                        '04Save':{'cmd':self.save_project},
                        '05Save As':{'cmd':self.save_as_project},
                        '06Preferences..':{'cmd':self.showPrefsDialog},
                        '08Quit':{'cmd':self.quit}}
        if self.parent:
            self.proj_menu['08Return to Database']={'cmd':self.return_data}
        self.proj_menu=self.create_pulldown(self.menu,self.proj_menu)
        self.menu.add_cascade(label='Project',menu=self.proj_menu['var'])

        self.records_menu={'01Add Row':{'cmd':self.add_Row},
                         '02Delete Row':{'cmd':self.delete_Row},
                         '03Add Column':{'cmd':self.add_Column},
                         '04Delete Column':{'cmd':self.delete_Column},
                         '05Auto Add Rows':{'cmd':self.autoAdd_Rows},
                         '06Auto Add Columns':{'cmd':self.autoAdd_Columns},
                         '07Find':{'cmd':self.createSearchBar},
                         }
        self.records_menu=self.create_pulldown(self.menu,self.records_menu)
        self.menu.add_cascade(label='Records',menu=self.records_menu['var'])

        self.sheet_menu={'01Add Sheet':{'cmd':self.add_Sheet},
                         '02Remove Sheet':{'cmd':self.delete_Sheet},
                         '03Copy Sheet':{'cmd':self.copy_Sheet},
                         '04Rename Sheet':{'cmd':self.rename_Sheet},
                         }
        self.sheet_menu=self.create_pulldown(self.menu,self.sheet_menu)
        self.menu.add_cascade(label='Sheet',menu=self.sheet_menu['var'])

        self.IO_menu={'01Import from csv file':{'cmd':self.import_csv},
                      '02Export to csv file':{'cmd':self.export_csv},
                      }

        self.IO_menu=self.create_pulldown(self.menu,self.IO_menu)
        self.menu.add_cascade(label='Import/Export',menu=self.IO_menu['var'])

        # Help menu
        self.help_menu={'01Online Help':{'cmd':self.online_documentation},
                        '02About':{'cmd':self.about_Tables}}
        self.help_menu=self.create_pulldown(self.menu,self.help_menu)
        self.menu.add_cascade(label='Help',menu=self.help_menu['var'])

        self.tablesapp_win.config(menu=self.menu)

        return
def createMenuBar ( self ) : self . menu = Menu ( self . tablesapp_win ) self . proj_menu = { '01New' : { 'cmd' : self . new_project } , '02Open' : { 'cmd' : self . open_project } , '03Close' : { 'cmd' : self . close_project } , '04Save' : { 'cmd' : self . save_project } , '05Save As' : { 'cmd' : self . save_as_project } , '06Preferences..' : { 'cmd' : self . showPrefsDialog } , '08Quit' : { 'cmd' : self . quit } } if self . parent : self . proj_menu [ '08Return to Database' ] = { 'cmd' : self . return_data } self . proj_menu = self . create_pulldown ( self . menu , self . proj_menu ) self . menu . add_cascade ( label = 'Project' , menu = self . proj_menu [ 'var' ] ) self . records_menu = { '01Add Row' : { 'cmd' : self . add_Row } , '02Delete Row' : { 'cmd' : self . delete_Row } , '03Add Column' : { 'cmd' : self . add_Column } , '04Delete Column' : { 'cmd' : self . delete_Column } , '05Auto Add Rows' : { 'cmd' : self . autoAdd_Rows } , '06Auto Add Columns' : { 'cmd' : self . autoAdd_Columns } , '07Find' : { 'cmd' : self . createSearchBar } , } self . records_menu = self . create_pulldown ( self . menu , self . records_menu ) self . menu . add_cascade ( label = 'Records' , menu = self . records_menu [ 'var' ] ) self . sheet_menu = { '01Add Sheet' : { 'cmd' : self . add_Sheet } , '02Remove Sheet' : { 'cmd' : self . delete_Sheet } , '03Copy Sheet' : { 'cmd' : self . copy_Sheet } , '04Rename Sheet' : { 'cmd' : self . rename_Sheet } , } self . sheet_menu = self . create_pulldown ( self . menu , self . sheet_menu ) self . menu . add_cascade ( label = 'Sheet' , menu = self . sheet_menu [ 'var' ] ) self . IO_menu = { '01Import from csv file' : { 'cmd' : self . import_csv } , '02Export to csv file' : { 'cmd' : self . export_csv } , } self . IO_menu = self . create_pulldown ( self . menu , self . IO_menu ) self . menu . add_cascade ( label = 'Import/Export' , menu = self . IO_menu [ 'var' ] ) # Help menu self . help_menu = { '01Online Help' : { 'cmd' : self . online_documentation } , '02About' : { 'cmd' : self . about_Tables } } self . help_menu = self . create_pulldown ( self . menu , self . help_menu ) self . menu . add_cascade ( label = 'Help' , menu = self . help_menu [ 'var' ] ) self . tablesapp_win . config ( menu = self . menu ) return