From: <ha...@us...> - 2011-04-21 12:25:44
|
Revision: 15391 http://jmol.svn.sourceforge.net/jmol/?rev=15391&view=rev Author: hansonr Date: 2011-04-21 12:25:37 +0000 (Thu, 21 Apr 2011) Log Message: ----------- 12.1.43 VERSION # new feature: isosurfaces can be remapped. # isosurface molecular map property temperature # isosurface map property partialcharge # isosurface vdw # isosurface map mep # new feature: set echo ID "xxxx" # new feature: show drawing (2D line drawing, from NIH) # bug fix: echo myecho ... after echo ALL still does ALL # bug fix: cube file reader (load command) does not convert z coordinates to Angstroms. # bug fix: isosurface CAVITY cannot be mapped # bug fix: isosurface CAVITY broken # bug fix: application load menu unnecessarily creates new frame and loses current script processing # code: setEcho rewrite Modified Paths: -------------- trunk/Jmol/src/org/jmol/script/ScriptEvaluator.java trunk/Jmol/src/org/jmol/script/Token.java trunk/Jmol/src/org/jmol/shape/Echo.java trunk/Jmol/src/org/jmol/viewer/Jmol.properties Modified: trunk/Jmol/src/org/jmol/script/ScriptEvaluator.java =================================================================== --- trunk/Jmol/src/org/jmol/script/ScriptEvaluator.java 2011-04-21 11:48:19 UTC (rev 15390) +++ trunk/Jmol/src/org/jmol/script/ScriptEvaluator.java 2011-04-21 12:25:37 UTC (rev 15391) @@ -12277,26 +12277,26 @@ switch (getToken(2).tok) { case Token.off: id = propertyName = "allOff"; - // fall through + checkLength(++pt); + break; case Token.none: echoShapeActive = false; // fall through case Token.all: // all and none get NO additional parameters; - if (id == null) - id = parameterAsString(2); + id = parameterAsString(2); checkLength(++pt); break; case Token.left: + case Token.center: case Token.right: case Token.top: + case Token.middle: case Token.bottom: - case Token.center: case Token.identifier: - id = parameterAsString(pt++); - break; case Token.id: - pt++; + if (theTok == Token.id) + pt++; id = parameterAsString(pt++); break; } @@ -12313,53 +12313,11 @@ // set echo name xxx // pt is usually 3, but could be 4 if ID used switch (getToken(pt++).tok) { - case Token.image: - case Token.string: - if (theTok == Token.image) - pt++; - checkLength(pt); - echo(pt - 1, theTok == Token.image); - return; - default: - if (isCenterParameter(pt - 1)) { - propertyName = "xyz"; - propertyValue = centerParameter(pt - 1); - pt = iToken + 1; - break; - } - error(ERROR_invalidArgument); - case Token.off: - propertyName = "off"; - break; - case Token.hide: - case Token.hidden: - propertyName = "hidden"; - propertyValue = Boolean.TRUE; - break; - case Token.display: - case Token.displayed: - case Token.on: - propertyName = "hidden"; - propertyValue = Boolean.FALSE; - break; - case Token.model: - int modelIndex = (isSyntaxCheck ? 0 : modelNumberParameter(pt++)); - if (modelIndex >= viewer.getModelCount()) - error(ERROR_invalidArgument); - propertyName = "model"; - propertyValue = Integer.valueOf(modelIndex); - break; - case Token.script: - propertyName = "script"; - propertyValue = parameterAsString(pt++); - break; case Token.align: propertyName = "align"; switch (getToken(pt).tok) { case Token.left: case Token.right: - case Token.top: - case Token.bottom: case Token.center: propertyValue = parameterAsString(pt++); break; @@ -12367,11 +12325,9 @@ error(ERROR_invalidArgument); } break; + case Token.center: case Token.left: case Token.right: - case Token.top: - case Token.bottom: - case Token.center: propertyName = "align"; propertyValue = parameterAsString(pt - 1); break; @@ -12379,6 +12335,24 @@ propertyName = "%zpos"; propertyValue = Integer.valueOf((int) floatParameter(pt++)); break; + case Token.display: + case Token.displayed: + case Token.on: + propertyName = "hidden"; + propertyValue = Boolean.FALSE; + break; + case Token.hide: + case Token.hidden: + propertyName = "hidden"; + propertyValue = Boolean.TRUE; + break; + case Token.model: + int modelIndex = (isSyntaxCheck ? 0 : modelNumberParameter(pt++)); + if (modelIndex >= viewer.getModelCount()) + error(ERROR_invalidArgument); + propertyName = "model"; + propertyValue = Integer.valueOf(modelIndex); + break; case Token.leftsquare: case Token.spacebeforesquare: // [ x y ] with or without % @@ -12406,6 +12380,29 @@ } checkLength(pt); setShapeProperty(JmolConstants.SHAPE_ECHO, namex, Integer.valueOf(posx)); + break; + case Token.off: + propertyName = "off"; + break; + case Token.script: + propertyName = "script"; + propertyValue = parameterAsString(pt++); + break; + case Token.string: + case Token.image: + if (theTok == Token.image) + pt++; + checkLength(pt); + echo(pt - 1, theTok == Token.image); + return; + default: + if (isCenterParameter(pt - 1)) { + propertyName = "xyz"; + propertyValue = centerParameter(pt - 1); + pt = iToken + 1; + break; + } + error(ERROR_invalidArgument); } } checkLength(pt); Modified: trunk/Jmol/src/org/jmol/script/Token.java =================================================================== --- trunk/Jmol/src/org/jmol/script/Token.java 2011-04-21 11:48:19 UTC (rev 15390) +++ trunk/Jmol/src/org/jmol/script/Token.java 2011-04-21 12:25:37 UTC (rev 15391) @@ -1123,6 +1123,7 @@ final static int maxset = misc | 190;// new final static int mep = misc | 192; public final static int mesh = misc | 194; + final static int middle = misc | 195; final static int minset = misc | 196;// new final static int mlp = misc | 197; final static int mode = misc | 198; @@ -1766,6 +1767,7 @@ "max", new Token(max), "mep", new Token(mep), "mesh", new Token(mesh), + "middle", new Token(middle), "min", new Token(min), "mlp", new Token(mlp), "mode", new Token(mode), Modified: trunk/Jmol/src/org/jmol/shape/Echo.java =================================================================== --- trunk/Jmol/src/org/jmol/shape/Echo.java 2011-04-21 11:48:19 UTC (rev 15390) +++ trunk/Jmol/src/org/jmol/shape/Echo.java 2011-04-21 12:25:37 UTC (rev 15391) @@ -122,6 +122,7 @@ if (target == "none" || target == "all") { // process in Object2dShape } else { + isAll = false; Text text = objects.get(target); if (text == null) { int valign = Object2d.VALIGN_XY; Modified: trunk/Jmol/src/org/jmol/viewer/Jmol.properties =================================================================== --- trunk/Jmol/src/org/jmol/viewer/Jmol.properties 2011-04-21 11:48:19 UTC (rev 15390) +++ trunk/Jmol/src/org/jmol/viewer/Jmol.properties 2011-04-21 12:25:37 UTC (rev 15391) @@ -1,8 +1,9 @@ # Developers: to add a description of changes you have made, # add it on a line starting with # below the "version=..." line -version=12.1.43_dev +version=12.1.43 +# bug fix: echo myecho ... after echo ALL still does ALL # bug fix: cube file reader (load command) does not convert z coordinates to Angstroms. # new feature: isosurfaces can be remapped. # isosurface molecular map property temperature This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |