Thanks for the suggestion, and the solution.
In Versions >= 0.95, cmd.extend will will adds new commands into the
help dictionary.
In the meantime
cmd.help_sc.append('func_name')
will work...
Cheers,
Warren
--
mailto:[email protected]
Warren L. DeLano, Ph.D.
Principal Scientist
DeLano Scientific LLC
Voice (650)-346-1154
Fax (650)-593-4020
> -----Original Message-----
> From: [email protected] [mailto:pymol-users-
> [email protected]] On Behalf Of Michael George Lerner
> Sent: Thursday, January 22, 2004 1:51 PM
> To: Gareth Stockwell
> Cc: pymol-users
> Subject: Re: [PyMOL] Help for user-defined functions
>
>
> Hi,
>
> I haven't seen this documented anywhere, so I have no idea if it's the
> Right Way to do things, but I think all you need to do is add
>
> cmd.help_sc.append('some_func')
>
> after the cmd.extend('some_func',some_func) call. should this be
built in
> to cmd.extend()?
>
> -michael
>
> --
> This isn't a democracy;| _ |Michael Lerner
> it's a cheer-ocracy. | ASCII ribbon campaign ( ) | Michigan
> -Torrence, Bring It On| - against HTML email X | Biophysics
> | / \ | mler...@umich
>
> On Thu, 22 Jan 2004, Gareth Stockwell wrote:
>
> > Does anyone know if it is possible to add 'help' documentation to my
own
> > user-defined functions? What I want is to be able to define a new
PyMOL
> > command by executing the following script:
> >
> >
> > #------------------
> >
> > def some_func:
> >
> > '''
> > Some help docs here...
> >
> > '''
> >
> > # Python code here...
> >
> > cmd.extend("some_func", some_func)
> >
> > #------------------
> >
> > ... and then type 'help some_func'.
> >
> > Gareth
> >
> > --
> > Gareth Stockwell <[email protected]>
> > European Bioinformatics Institute
> >
> >
> >
> > -------------------------------------------------------
> > The SF.Net email is sponsored by EclipseCon 2004
> > Premiere Conference on Open Tools Development and Integration
> > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
> > http://www.eclipsecon.org/osdn
> > _______________________________________________
> > PyMOL-users mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/pymol-users
> >
>
>
> -------------------------------------------------------
> The SF.Net email is sponsored by EclipseCon 2004
> Premiere Conference on Open Tools Development and Integration
> See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
> http://www.eclipsecon.org/osdn
> _______________________________________________
> PyMOL-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/pymol-users