[PyMOL] Label on top of molecules?

2012-10-17 Thread Boris Kheyfets
Hello PyMOL users,

When I print atom names with

label all, name

the labels are often behind the spheres (I use balls and sticks
representation).

I tried moving labels around, but my system is very dence -- and labels
generally get under one or another sphere.

Is there a way I can print labels on top of everything?

With great respect,
Boris.
--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct___
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net

Re: [PyMOL] Label on top of molecules?

2012-10-17 Thread Takanori Nakane
Hi Boris,

set float_labels, on

will do the job.
But it doesn't seem to affect ray-traced images.

Then you might want to manually adjust
label_position.
See http://www.pymolwiki.org/index.php/Label_position

For example,
 set label_position, (0, 0, 20)

will bring labels 20 angstroms in front of its original position.

Best regards,

Takanori Nakane

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net


Re: [PyMOL] Label on top of molecules?

2012-10-17 Thread Jason Vertrees
Hi Boris,

Takanori had some good ideas to try. I just wanted to let you know
that you uncovered some bugs that we've taken note of and will fix in
both on-screen rendering and in ray traced mode.

Cheers,

-- Jason

On Wed, Oct 17, 2012 at 7:47 AM, Boris Kheyfets kheyfbo...@gmail.com wrote:
 Hello PyMOL users,

 When I print atom names with

 label all, name

 the labels are often behind the spheres (I use balls and sticks
 representation).

 I tried moving labels around, but my system is very dence -- and labels
 generally get under one or another sphere.

 Is there a way I can print labels on top of everything?

 With great respect,
 Boris.

 --
 Everyone hates slow websites. So do we.
 Make your web apps faster with AppDynamics
 Download AppDynamics Lite for free today:
 http://p.sf.net/sfu/appdyn_sfd2d_oct
 ___
 PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
 Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
 Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net



-- 
Jason Vertrees, PhD
PyMOL Product Manager
Schrödinger, Inc.

(e) jason.vertr...@schrodinger.com
(o) +1 (603) 374-7120

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net


[PyMOL] Tab completion using object names, not filesystem files?

2012-10-17 Thread Ron Jacak
PyMOL-users,

I'm wondering if there's a way to make the tab completion engine use
the currently loaded (or visible) object names rather than (or in
addition to) the files in the filesystem?  I usually have sessions
with very long object names that I want to include in custom selection
expressions and the tab completion doesn't work because oftentimes the
PDB files are not in the same directory as the session.  I found the
function complete() in modules/pymol/parsing.py that seems to be what
figures out how to complete the command that's been entered.  I think
if I just added a list of the currently loaded objects to the list
obtained by globbing the filesystem, it would do what I'm looking for.
 Any ideas on the best way to do that?

Best,
-Ron

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net


Re: [PyMOL] Tab completion using object names, not filesystem files?

2012-10-17 Thread Thomas Holder
Hi Ron,

tab completion is controlled by the cmd.auto_arg variable, which is a 
list of dictionaries.

http://pymolwiki.org/index.php/auto_arg

For all arguments which do not have an entry in auto_arg, the default is 
to auto-complete file names. For your purpose you need to define 
something like this:

python
import glob
cmd.auto_arg[0]['save'] = [
   lambda: cmd.Shortcut(cmd.get_names() + glob.glob('*')),
   'filename or object name', '']
python end

Cheers,
   Thomas

Ron Jacak wrote, On 10/17/12 22:25:
 PyMOL-users,
 
 I'm wondering if there's a way to make the tab completion engine use
 the currently loaded (or visible) object names rather than (or in
 addition to) the files in the filesystem?  I usually have sessions
 with very long object names that I want to include in custom selection
 expressions and the tab completion doesn't work because oftentimes the
 PDB files are not in the same directory as the session.  I found the
 function complete() in modules/pymol/parsing.py that seems to be what
 figures out how to complete the command that's been entered.  I think
 if I just added a list of the currently loaded objects to the list
 obtained by globbing the filesystem, it would do what I'm looking for.
  Any ideas on the best way to do that?
 
 Best,
 -Ron

-- 
Thomas Holder
MPI for Developmental Biology
Spemannstr. 35
D-72076 Tübingen

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net


Re: [PyMOL] Tab completion using object names, not filesystem files?

2012-10-17 Thread Ron Jacak
Hi Thomas,

Thanks for the quick reply.  That worked exactly the way I wanted!  I
had read the auto_arg Wiki page, but it didn't click that I had to
define a new list specifically for the command I wanted the tab
completion to work for (i.e. select).  I thought it applied to all
commands.

So, for anyone else who is trying to do this, the command to have tab
completion use only loaded and visible object names *during select
statements* is as follows:
cmd.auto_arg[0]['select'] = [ lambda:
cmd.Shortcut(cmd.get_names(objects, enabled_only=1)), 'visible
object name(s)', '']

If you want tab completion to pull up loaded objects (visible or not)
as well as PDB files in the current working directory, it would be:
cmd.auto_arg[0]['select'] = [ lambda: cmd.Shortcut(cmd.get_names() +
glob.glob('*.pdb')), 'PDB file and object name(s)', '']

Best,
-Ron


On Wed, Oct 17, 2012 at 2:31 PM, Thomas Holder
spel...@users.sourceforge.net wrote:
 Hi Ron,

 tab completion is controlled by the cmd.auto_arg variable, which is a list
 of dictionaries.

 http://pymolwiki.org/index.php/auto_arg

 For all arguments which do not have an entry in auto_arg, the default is to
 auto-complete file names. For your purpose you need to define something like
 this:

 python
 import glob
 cmd.auto_arg[0]['save'] = [
   lambda: cmd.Shortcut(cmd.get_names() + glob.glob('*')),
   'filename or object name', '']
 python end

 Cheers,
   Thomas

 Ron Jacak wrote, On 10/17/12 22:25:

 PyMOL-users,

 I'm wondering if there's a way to make the tab completion engine use
 the currently loaded (or visible) object names rather than (or in
 addition to) the files in the filesystem?  I usually have sessions
 with very long object names that I want to include in custom selection
 expressions and the tab completion doesn't work because oftentimes the
 PDB files are not in the same directory as the session.  I found the
 function complete() in modules/pymol/parsing.py that seems to be what
 figures out how to complete the command that's been entered.  I think
 if I just added a list of the currently loaded objects to the list
 obtained by globbing the filesystem, it would do what I'm looking for.
  Any ideas on the best way to do that?

 Best,
 -Ron


 --
 Thomas Holder
 MPI for Developmental Biology
 Spemannstr. 35
 D-72076 Tübingen

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net