pKaTool/pKa_system_micro.py
def copy_to_Ekin_micro(self):
        """Copy a population curve to the Ekin facility of EAT_DB"""
        import os,sys
        import EAT_DB.Ekin
        #
        # Pick a group
        #
        self.pick_group_micro=Toplevel()
        self.pick_group_micro.title('Pick a protonation state')
        self.pick_group_micro.geometry('+200+200')
        self.state_picked=IntVar()
        count=0
        for state in self.states:
            #
            # Get colour
            #
            colour=self.colour_order[count%len(self.colour_order)]
            fg_col='black'
            if colour=='black' or colour=='blue':
                fg_col='white'
            if colour=='green':
                colour='cyan'
            #
            # Put the radiobutton in the window
            #
            Radiobutton(self.pick_group_micro,text="state %d, def: %s" %(state,self.X.all_states[self.lastpH][state]['def']),
                        variable=self.state_picked,
                        value=count).grid(row=count,column=0)
            count=count+1
        self.state_picked.set(0)
        Button(self.pick_group_micro,text='Copy population',command=self.copy_group_micro).grid(row=count,column=0)
        Button(self.pick_group_micro,text='Cancel',command=self.cancel_copy_group_micro).grid(row=count,column=1)
        return
Copy a population curve to the Ekin facility of EAT_DB
Copy a population curve to the Ekin facility of EAT_DB
Copy a population curve to the Ekin facility of EAT_DB
def copy_to_Ekin_micro(self):
        import os,sys
        import EAT_DB.Ekin
         Pick a group
        self.pick_group_micro=Toplevel()
        self.pick_group_micro.title('Pick a protonation state')
        self.pick_group_micro.geometry('+200+200')
        self.state_picked=IntVar()
        count=0
        for state in self.states:
             Get colour
            colour=self.colour_order[count%len(self.colour_order)]
            fg_col='black'
            if colour=='black' or colour=='blue':
                fg_col='white'
            if colour=='green':
                colour='cyan'
             Put the radiobutton in the window
            Radiobutton(self.pick_group_micro,text="state %d, def: %s" %(state,self.X.all_states[self.lastpH][state]['def']),
                        variable=self.state_picked,
                        value=count).grid(row=count,column=0)
            count=count+1
        self.state_picked.set(0)
        Button(self.pick_group_micro,text='Copy population',command=self.copy_group_micro).grid(row=count,column=0)
        Button(self.pick_group_micro,text='Cancel',command=self.cancel_copy_group_micro).grid(row=count,column=1)
        return
def copy_to_Ekin_micro ( self ) : import os , sys import EAT_DB . Ekin self . pick_group_micro = Toplevel ( ) self . pick_group_micro . title ( 'Pick a protonation state' ) self . pick_group_micro . geometry ( '+200+200' ) self . state_picked = IntVar ( ) count = 0 for state in self . states : colour = self . colour_order [ count % len ( self . colour_order ) ] fg_col = 'black' if colour == 'black' or colour == 'blue' : fg_col = 'white' if colour == 'green' : colour = 'cyan' Radiobutton ( self . pick_group_micro , text = "state %d, def: %s" % ( state , self . X . all_states [ self . lastpH ] [ state ] [ 'def' ] ) , variable = self . state_picked , value = count ) . grid ( row = count , column = 0 ) count = count + 1 self . state_picked . set ( 0 ) Button ( self . pick_group_micro , text = 'Copy population' , command = self . copy_group_micro ) . grid ( row = count , column = 0 ) Button ( self . pick_group_micro , text = 'Cancel' , command = self . cancel_copy_group_micro ) . grid ( row = count , column = 1 ) return
Copy a population curve to the Ekin facility of EAT_DB
Copy a population curve to the Ekin facility of EAT_DB
"""Copy a population curve to the Ekin facility of EAT_DB""" # # Pick a group # # # Get colour # # # Put the radiobutton in the window #
self