PEATDB/Ekin/Meta.py
def createDialog(self, dataset=None, showglob=True, parent=None):
        """Create a dialog for inputing fields, include all current global
           fields and ones local to the supplied dataset"""
        d=self.data
        
        self.currdataset = dataset
        self.metawin=Toplevel(parent)
        metawin = self.metawin
        metawin.title('Edit/View meta data')
        metawin.geometry('+200+200')
        self.datasetlabel=StringVar()
        self.datasetlabel.set(dataset)
        Label(metawin, font='Arial 16', fg='blue',
                    textvariable=self.datasetlabel).grid(row=0,column=0)

        if not d.has_key('glob'):
            d['glob'] = {}
            self.glob = d['glob']

        self.updateFields(dataset)
        bf = Frame(metawin); bf.grid(row=0,column=2,rowspan=3)
        addfieldbtn=Button(bf,text='Add field',command=self.addFieldDialog)
        addfieldbtn.pack(fill=BOTH,expand=1)
        removefieldbtn=Button(bf,text='Remove field',command=self.removeFieldDialog)
        removefieldbtn.pack(fill=BOTH,expand=1)
        editattribbtn=Button(bf,text='Edit attrib',command=self.editAttribDialog)
        editattribbtn.pack(fill=BOTH,expand=1)
        okbtn=Button(bf,text='Apply',command=self.applyCurrent)
        okbtn.pack(fill=BOTH,expand=1)
        Closebtn=Button(bf,text='Close',command=self.close)
        Closebtn.pack(fill=BOTH,expand=1)
        metawin.rowconfigure(0,weight=1)
        metawin.columnconfigure(0,weight=1)
        return metawin
Create a dialog for inputing fields, include all current global
           fields and ones local to the supplied dataset
Create a dialog for inputing fields, include all current global
fields and ones local to the supplied dataset
Create a dialog for inputing fields include all current global fields and ones local to the supplied dataset
def createDialog(self, dataset=None, showglob=True, parent=None):
        d=self.data
        self.currdataset = dataset
        self.metawin=Toplevel(parent)
        metawin = self.metawin
        metawin.title('Edit/View meta data')
        metawin.geometry('+200+200')
        self.datasetlabel=StringVar()
        self.datasetlabel.set(dataset)
        Label(metawin, font='Arial 16', fg='blue',
                    textvariable=self.datasetlabel).grid(row=0,column=0)
        if not d.has_key('glob'):
            d['glob'] = {}
            self.glob = d['glob']
        self.updateFields(dataset)
        bf = Frame(metawin); bf.grid(row=0,column=2,rowspan=3)
        addfieldbtn=Button(bf,text='Add field',command=self.addFieldDialog)
        addfieldbtn.pack(fill=BOTH,expand=1)
        removefieldbtn=Button(bf,text='Remove field',command=self.removeFieldDialog)
        removefieldbtn.pack(fill=BOTH,expand=1)
        editattribbtn=Button(bf,text='Edit attrib',command=self.editAttribDialog)
        editattribbtn.pack(fill=BOTH,expand=1)
        okbtn=Button(bf,text='Apply',command=self.applyCurrent)
        okbtn.pack(fill=BOTH,expand=1)
        Closebtn=Button(bf,text='Close',command=self.close)
        Closebtn.pack(fill=BOTH,expand=1)
        metawin.rowconfigure(0,weight=1)
        metawin.columnconfigure(0,weight=1)
        return metawin
def createDialog ( self , dataset = None , showglob = True , parent = None ) : d = self . data self . currdataset = dataset self . metawin = Toplevel ( parent ) metawin = self . metawin metawin . title ( 'Edit/View meta data' ) metawin . geometry ( '+200+200' ) self . datasetlabel = StringVar ( ) self . datasetlabel . set ( dataset ) Label ( metawin , font = 'Arial 16' , fg = 'blue' , textvariable = self . datasetlabel ) . grid ( row = 0 , column = 0 ) if not d . has_key ( 'glob' ) : d [ 'glob' ] = { } self . glob = d [ 'glob' ] self . updateFields ( dataset ) bf = Frame ( metawin ) ; bf . grid ( row = 0 , column = 2 , rowspan = 3 ) addfieldbtn = Button ( bf , text = 'Add field' , command = self . addFieldDialog ) addfieldbtn . pack ( fill = BOTH , expand = 1 ) removefieldbtn = Button ( bf , text = 'Remove field' , command = self . removeFieldDialog ) removefieldbtn . pack ( fill = BOTH , expand = 1 ) editattribbtn = Button ( bf , text = 'Edit attrib' , command = self . editAttribDialog ) editattribbtn . pack ( fill = BOTH , expand = 1 ) okbtn = Button ( bf , text = 'Apply' , command = self . applyCurrent ) okbtn . pack ( fill = BOTH , expand = 1 ) Closebtn = Button ( bf , text = 'Close' , command = self . close ) Closebtn . pack ( fill = BOTH , expand = 1 ) metawin . rowconfigure ( 0 , weight = 1 ) metawin . columnconfigure ( 0 , weight = 1 ) return metawin
Create a dialog for inputing fields, include all current global
fields and ones local to the supplied dataset
Create a dialog for inputing fields include all current global fields and ones local to the supplied dataset
"""Create a dialog for inputing fields, include all current global
           fields and ones local to the supplied dataset"""
self
dataset
showglob
parent