Hi Boris,
this will give you the list of active selections, which has by default only one
entry (or zero, if no selection is enabled).
active_selections = cmd.get_names('selections', 1)
Hope that helps.
Cheers,
Thomas
On Jan 22, 2013, at 2:08 PM, Boris Kheyfets <[email protected]> wrote:
> I want to save current selection as a uniquetly-named pdb file. So I need
> tempfile of python.
>
> So I write def, and I want it have current selection as default one (not the
> '(all)'). How do I do that?
>
> I think it will be somewhere under
> cmd.get_session()
>
> I read the sources, but couldn't find a single instance where current
> selection would be a default one.
--
Thomas Holder
PyMOL Developer
Schrödinger Contractor
------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnnow-d2d
_______________________________________________
PyMOL-users mailing list ([email protected])
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/[email protected]