Beispiel #1
0
 def do_pick(self, bondFlag):
     if self.mode == 0:
         self.cmd.select(active_sele, "bymol pk1")
         editor.attach_fragment("pk1", self.fragment, self.position, self.geometry, _self=self.cmd)
     elif self.mode == 1:
         self.cmd.select(active_sele, "bymol pk1")
         editor.combine_fragment("pk1", self.fragment, self.position,
                                 self.geometry, _self=self.cmd)
         self.mode = 0
         self.cmd.refresh_wizard()
     self.cmd.unpick()
     if not self.getRepeating():
         self.actionWizardDone()
Beispiel #2
0
 def do_pick(self, bondFlag):
     if self.mode == 0:
         self.cmd.select(active_sele, "bymol pk1")
         editor.attach_fragment("pk1", self.fragment, self.position, self.geometry, _self=self.cmd)
     elif self.mode == 1:
         self.cmd.select(active_sele, "bymol pk1")
         editor.combine_fragment("pk1", self.fragment, self.position,
                                 self.geometry, _self=self.cmd)
         self.mode = 0
         self.cmd.refresh_wizard()
     self.cmd.unpick()
     if not self.getRepeating():
         self.actionWizardDone()
Beispiel #3
0
    def do_pick(self, bondFlag):
        # since this function can change any position of atoms in a related
        # molecule, bymol is used
        if self.mode == 0:
            self.cmd.select(active_sele, "bymol pk1")
            try:
                with undocontext(self.cmd, "bymol ?pk1"):
                    editor.attach_amino_acid("pk1", self.aminoAcid, _self=self.cmd)
            except QuietException:
                fin = -1
        elif self.mode == 1:
            self.cmd.select(active_sele, "bymol pk1")
            editor.combine_fragment("pk1", self.aminoAcid, 0, 1, _self=self.cmd)
            self.mode = 0
            self.cmd.refresh_wizard()

        self.cmd.unpick()
        if not self.getRepeating():
            self.actionWizardDone()
Beispiel #4
0
    def do_pick(self, bondFlag):
        # since this function can change any position of atoms in a related
        # molecule, bymol is used
        if self.mode == 0:
            self.cmd.select(active_sele, "bymol pk1")
            try:
                with undocontext(self.cmd, "bymol ?pk1"):
                    self.attach_monomer(self.aminoAcid)
            except QuietException:
                fin = -1
        elif self.mode == 1:
            self.cmd.select(active_sele, "bymol pk1")
            editor.combine_fragment("pk1", self.aminoAcid, 0, 1, _self=self.cmd)
            self.mode = 0
            self.cmd.refresh_wizard()

        self.cmd.unpick()
        if not self.getRepeating():
            self.actionWizardDone()