PyMOLWiki:Community Portal: Difference between revisions
Line 11: | Line 11: | ||
== Features == | == Features == | ||
=== New! GeShi: Syntax Highlighting for Python & More === | === New! GeShi: Syntax Highlighting for Python & More === | ||
Use Geshi for syntax highlighting your | Use Geshi for syntax highlighting your source code. Check out the huge list of supported [http://www.mediawiki.org/wiki/Extension:SyntaxHighlight_GeSHi#Supported_languages languages]. | ||
< | ==== No line numbers ==== | ||
< | <nowiki> | ||
</ | <source lang="python"> | ||
Non line-numbered code here | |||
</source> | |||
</nowiki> | |||
==== With Line Numbers ==== | |||
<nowiki> | |||
<source line="1" lang="python"> | |||
line-numbered code here | |||
</source> | |||
</nowiki> | |||
< | === Example === | ||
Line numbered code. | |||
<source lang="python" line="1"> | |||
# axes.py | # axes.py | ||
from pymol.cgo import * | from pymol.cgo import * | ||
Line 47: | Line 54: | ||
# then we load it into PyMOL | # then we load it into PyMOL | ||
cmd.load_cgo(obj,'axes') | cmd.load_cgo(obj,'axes') | ||
</ | </source> | ||
== See Also == | |||
See [http://qbnz.com/highlighter/index.php The Geshi Home Page] | See [http://qbnz.com/highlighter/index.php The Geshi Home Page] | ||
==Paid Documentation?== | ==Paid Documentation?== |
Revision as of 17:02, 6 March 2008
How to Get Involved
- First, go sign up, if you don't already have an account. New accounts can be created from any page; see the upper right hand side of any given page.
What to Do
- If you have a powerful little script you wrote and enjoy using, upload it and let the world know about it. Go to the script_library.
- Each command and setting needs nice example usage. Feel free to expound (and comment on) the commands.
- More internal linking (from page to page) is needed.
- We also need a way to make things easier to find on the wiki.
- More categories and organization within categories would be nice.
Features
New! GeShi: Syntax Highlighting for Python & More
Use Geshi for syntax highlighting your source code. Check out the huge list of supported languages.
No line numbers
<source lang="python"> Non line-numbered code here </source>
With Line Numbers
<source line="1" lang="python"> line-numbered code here </source>
Example
Line numbered code.
# axes.py
from pymol.cgo import *
from pymol import cmd
from pymol.vfont import plain
# create the axes object, draw axes with cylinders coloured red, green,
#blue for X, Y and Z
obj = [
CYLINDER, 0., 0., 0., 50., 0., 0., 0.2, 1.0, 1.0, 1.0, 1.0, 0.0, 0.,
CYLINDER, 0., 0., 0., 0., 50., 0., 0.2, 1.0, 1.0, 1.0, 0., 1.0, 0.,
CYLINDER, 0., 0., 0., 0., 0., 50., 0.2, 1.0, 1.0, 1.0, 0., 0.0, 1.0,
]
# add labels to axes object (requires pymol version 0.8 or greater, I
# believe
cyl_text(obj,plain,[-5.,-5.,-1],'Origin',0.20,axes=[[3,0,0],[0,3,0],[0,0,3]])
cyl_text(obj,plain,[50.,0.,0.],'X',0.20,axes=[[3,0,0],[0,3,0],[0,0,3]])
cyl_text(obj,plain,[0.,50.,0.],'Y',0.20,axes=[[3,0,0],[0,3,0],[0,0,3]])
cyl_text(obj,plain,[0.,0.,50.],'Z',0.20,axes=[[3,0,0],[0,3,0],[0,0,3]])
# then we load it into PyMOL
cmd.load_cgo(obj,'axes')
See Also
Paid Documentation?
I might be interested in using PyMOL, but I don't like the fact that I have to pay for documentation. I don't even know what I'm missing out on, and I don't know if it's worth trying out PyMOL, or becoming actively involved in its development (or simply the creation of content on this wiki). Guaka 07:28, 5 September 2007 (CDT)
Huh? You don't have to pay for documentation. PyMOLWiki is freely accessible, and it contains far more useful content than the "official" docs. You can also easily try out PyMOL without compiling the current open-source code by downloading older free builds or the current evaluation build. Nobody has to pay for PyMOL -- it's open source! Warren 20:51, 12 November 2007 (CST)