Backward compatibility

From Jmol
Revision as of 16:43, 13 December 2010 by AngelHerraez (talk | contribs) (new result of "hbonds calculate" in 12.0)
Jump to navigation Jump to search

Jmol intentionally keeps a strong backward-compatibility, that is, new versions try to maintain operative all things that could be done in older versions, with the same command syntax, and to also keep defaults.

However, on a few occasions there are stronger reasons to decide upon a change in the default behaviour; this can break existing scripts if you update the Jmol version.

This is a place to try and collect such discrepancies, for the benefit of the community of users and webpage/script programmers.

Changes in behavior

Please, add here any issues you have found when updating Jmol versions:

  • Script commands that get broken when moved to a new version of Jmol.
  • Changes in default behavior.

Make sure to specify the old and new version numbers across which the behaviour was changed.

Hydrogen bonds: calculation and display

Changed between v. 11.8 and 12.0

Description:

hBonds calculate fails to calculate hydrogen bonds on files that contain any H atoms.

Seems to affect pdb-format files only. The new command calculate hBonds is also affected.

Effects:

Old scripts using hBonds calculate will no longer display any hydrogen bonds in some cases.

Advice:

Where you had the hBonds calculate command for a molecule, replace it with select !_H; hBonds calculate; select all;. Alternatively, use calculate hBonds (!_H) (!_H);

Changed between v. 10.0 and 10.2

Description:

hBonds on does not calculate hydrogen bonds anymore. Instead, the first time you want hydrogen bonds displayed you must use hBonds calculate. This enables the separation of H-bond data present in the pdb file (e.g. specified by the authors as calculated by a separate algorithm) and H-bond information as calculated by the Jmol algorithm.

Effects:

Old scripts using hBonds on will no longer display any hydrogen bonds in most cases, or will display just a few of them (few pdb files include H-bonds specification).

Advice:

Where you had the first hBonds on command for a molecule, replace it with hBonds calculate. Where hBonds on was only to restore display (e.g. after a hBonds off), you can leave it as it was.

Testing different applet versions

(This is an advanced feature)

You can force the use of a certain version of Jmol applet in any web page (even if that page is not yours). The way to do so is:

On the URL line of the browser, add

?JMOLJAR=

followed by the url of the File icon.gifJmolApplet.jar or File icon.gifJmolAppletSigned.jar file your intend to use. If there is already a ? in the URL, then use &JMOLJAR=, to preserve the logic of a url.

There will be a couple of warnings that you will have to accept, due to the potential security risk of replacing an applet with another coming from a totaly unrelated server. There may also be Java security issues still preventing the applet from loading files, unless you specify the signed applet.

For example:

http://www.rcsb.org/pdb/explore/jmol.do?structureId=1CRN&bionumber=1&JMOLJAR=http://chemapps.stolaf.edu/jmol/docs/examples-11/JmolAppletSigned.jar

lets you use Bob's latest version of Jmol at the RCSB site (which is currently using 11.8.4). Try it.

Contributors

AngelHerraez