(self,parent=None,data=None,datafile=None)
return
Initialize the application.
Initialize the application.
Initialize the application .
def __init__(self,parent=None,data=None,datafile=None):
        "Initialize the application."
        self.parent=parent

        #If there is data to be loaded, show the dialog first
        if not self.parent:
            Frame.__init__(self)
            self.tablesapp_win=self.master

        else:
            self.tablesapp_win=Toplevel()

        # Get platform into a variable
        import platform
        self.currplatform=platform.system()
        if not hasattr(self,'defaultsavedir'):
            self.defaultsavedir = os.getcwd()

        self.preferences=Preferences('TablesApp',{'check_for_update':1})
        self.loadprefs()
        self.tablesapp_win.title('Tables Application')
        self.tablesapp_win.geometry('+200+200')
        self.x_size=800
        self.y_size=600
        self.createMenuBar()
        self.apptoolBar = ToolBar(self.tablesapp_win, self)
        self.apptoolBar.pack(fill=BOTH, expand=NO)
        #add find bar
        #self.createSearchBar()

        if data != None:
            self.data = data
            self.new_project(data)
        elif datafile != None:
            self.open_project(datafile)
        else:
            self.new_project()

        self.tablesapp_win.protocol('WM_DELETE_WINDOW',self.quit)
        return
def __init__ ( self , parent = None , data = None , datafile = None ) : self . parent = parent #If there is data to be loaded, show the dialog first if not self . parent : Frame . __init__ ( self ) self . tablesapp_win = self . master else : self . tablesapp_win = Toplevel ( ) # Get platform into a variable import platform self . currplatform = platform . system ( ) if not hasattr ( self , 'defaultsavedir' ) : self . defaultsavedir = os . getcwd ( ) self . preferences = Preferences ( 'TablesApp' , { 'check_for_update' : 1 } ) self . loadprefs ( ) self . tablesapp_win . title ( 'Tables Application' ) self . tablesapp_win . geometry ( '+200+200' ) self . x_size = 800 self . y_size = 600 self . createMenuBar ( ) self . apptoolBar = ToolBar ( self . tablesapp_win , self ) self . apptoolBar . pack ( fill = BOTH , expand = NO ) #add find bar #self.createSearchBar() if data != None : self . data = data self . new_project ( data ) elif datafile != None : self . open_project ( datafile ) else : self . new_project ( ) self . tablesapp_win . protocol ( 'WM_DELETE_WINDOW' , self . quit ) return