-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi all,

one the list of features requests has been for some time RFE #737576: "a user
 customizable Macro menu". I've just implemented this.

Just put a file like zap.macro into $HOME/.jmol/macros, and it will show up
 in the application GUI:

$HOME/.jmol/macros/zap.macro
- - ------------ file starts below this line ---------------------------
Title=Zap
Script=zap
- - ------------ file ends below this line ----------------------------

A bit more complex example (ripped from 
 http://www.imb-jena.de/cgi-bin/rascript.exe?CODE=2fdn&TYPE=Jmol):

$HOME/.jmol/macros/2fdn.macro
- - ------------ file starts below this line ---------------------------
Title=Download 2FDN from IMB Jena and show in nice colors
Script=load pdb
 http://www.imb-jena.de/cgi-bin/rascript.exe?CODE=2fdn&TYPE=pdb; \ define
 proteinogenic (protein or helix or turn or sheet) and not nucleic; \
 wireframe off; \
hbonds off; \
cpk off; \
select carbon; \
color green; \
select phosphorus; \
color magenta; \
select chlorine; \
color GreenTint; \
select not hetero and not nucleic and not protein and not water and not
 ligand; \ wireframe 50; \
select all; \
background White; \
set hydrogen off; \
restrict not water; \
rotate z 180; \
select proteinogenic or nucleic or helix; \
backbone on; \
backbone off; \
color backbone Gray; \
define prev selected; \
select prev and not nucleic; \
cartoon; \
color cartoon Gray; \
select prev and nucleic and not (helix or sheet); \
trace 100; \
select turn; \
color cartoon Yellow; \
color backbone Yellow; \
select helix; \
color cartoon Red; \
color backbone Red; \
select sheet; \
color cartoon Blue; \
color backbone Blue; \
select hetero and not water and not ligand; \
dots 300; \
select ligand; \
cpk; \
select (a,t,g,c,u,i); \
trace on; \
wireframe on; \
select purine and a and not backbone; \
color red; \
select purine and g and not backbone; \
color green; \
select not protein and i and not backbone; \
color cyan; \
select pyrimidine and t and not backbone; \
color yellow; \
select not protein and u and not backbone; \
color magenta; \
select pyrimidine and c and not backbone; \
color blue; \
select (a,t,g,c,u,i) and *:a and backbone; \
color trace SeaGreen; \
select (a,t,g,c,u,i) and *:b and backbone; \
color trace Magenta; \
select (a,t,g,c,u,i) and *:c and backbone; \
color trace GreenBlue; \
select (a,t,g,c,u,i) and *:d and backbone; \
color trace HotPink;
- - ------------ file ends below this line ----------------------------

So, the macro file format is simple:
- - - a Title= field and a Script= field
- - - field values can be continued on the next line by ending the previous
 with \ - - mind that the script file name has to end with '.macro'

Have fun!

Egon

- -- 
[EMAIL PROTECTED]
- ---------------------------------------
CDK: http://cdk.sf.net/
JChemPaint: http://jchempaint.sf.net/
Jmol: http://www.jmol.org/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (SunOS)

iD8DBQFBLI2Pd9R8I9Yza6YRAgwUAJ47VvMJvdIftTICIQn29o1dT+gZ5gCdEMCL
gBI7zQqay0BeLbkhu/BrZaU=
=4ZFX
-----END PGP SIGNATURE-----


-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
Jmol-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to