Ed Pozharski wrote:
> On Wed, 2010-06-09 at 16:44 +0100, Judit Debreczeni wrote:
>
>> Not sure what you'd like to achieve, but perhaps the
>> map_molecule_chooser_gui is what you are looking for
>
> Thanks - exactly what I was looking for (and molecule_chooser_gui too!).
>
> Is there some to invoke an atom-picking event from python script?
> Something that would ask for user to click on some atom and then either
> return the atom id or call a function. Or just wait until atom is
> clicked and then proceed, since one can always get the current selection
> via active_residue(). There is residue_range_gui, but it's (probably)
> just to show a range selector dialog.
>
You want user_defined_click(n_clicked, func)
which runs func after the user has made n_clicked atom picks. func is
called with a list of atom specifiers (just print them out, you'll see
how they are formatted).
Hmm, this is not documented either - sorry about that.
(Note that the python version of this function may be a bid dodgy - I
have not kept up with the bug fixes here.)
Oh, and while I'm here... why invoke coot from a python script (which is
what I thought that you were doing), why not just run the script in coot?
Paul.
|