Macro
Jump to navigation
Jump to search
Jmol / JSmol Tutorials
- A list of Jmol / JSmol Tutorials written by users.
- Using the mouse (English · Español · Français · Japanese).
- Scripting quickstart: rendering options · selecting atoms.
- How to create surfaces and isosurfaces, including cavities, pockets and tunnels.
- Displaying shapes, polyhedra, orbitals, dipoles, distances, forces and vibrations.
- Creating movies.
- Customizing Jmol: macros · menus.
- Web pages without writing code by using the Jmol "Export to Web" function.
Jmol Macro's
A Jmol macro is a small script that provides some reusable functionality for the Jmol Application. It is saved as a simple text file, like any other script, in the $HOME/.jmol/macros subdirectory. It will show up in the Macro menu of the Jmol application.
Windows: the $HOME folder's location is stored in the environment variable
%USERPROFILE%
or in the environment variables%HOMEDRIVE%
and%HOMEPATH%
; it will usually be atc:\Documents and Settings\(yourUserName)\
If you don't find it, try
- My PC > right-click > Properties > Advanced Options (tab) > Environment Variables (button)
- or open a command line and type
set
The macro file must be a text file with the extension macro
, and its
contents must be two lines, starting with "Title=" and "Script=" (only one macro per file).
Example macro 1
To show everything as balls-and-sticks, CPK color, create a text file, write this:
Title=Ball