Revision: 21033 http://sourceforge.net/p/jmol/code/21033 Author: hansonr Date: 2016-03-30 00:39:48 +0000 (Wed, 30 Mar 2016) Log Message: ----------- Jmol.___JmolVersion="14.4.4_2016.03.29"
new feature: Polyhedra command allows for min and max radius -- polyhedra 2.8 3.0 @3 bug fix: unitcell PRIMITIVE for rhombohedral groups not implemented bug fix: unitcell("primitive","R") not implemented bug fix: WRITE IMAGE with negative width or height should throw a Jmol ScriptException bug fix: draw ... [x y] does not position properly with antialias true bug fix: allow AXES TYPE "" or non-recognized to be same as "abc" bug fix: AXES TYPE "ab" should also be allowed when offset or center is set bug fix: labels should not change size when creating images of different size than screen when angstromsPerInch != 0. bug fix: if...BREAK|CONTINUE in unbracketed context does not properly place implicit END IF when TRUE clause is on next line AND next statement after that is another IF command: if (xxxx) break; if (yyyy) zzzz; becomes if (xxxx) { break; if (yyyy) { zzzz; } } instead of if (xxxx) { break; } if (yyyy) { zzzz; } Modified Paths: -------------- branches/v14_4/Jmol/src/org/jmol/modelset/Text.java branches/v14_4/Jmol/src/org/jmol/render/TextRenderer.java branches/v14_4/Jmol/src/org/jmol/renderspecial/DrawRenderer.java branches/v14_4/Jmol/src/org/jmol/scriptext/CmdExt.java branches/v14_4/Jmol/src/org/jmol/scriptext/IsoExt.java branches/v14_4/Jmol/src/org/jmol/shapespecial/Polyhedra.java branches/v14_4/Jmol/src/org/jmol/symmetry/SpaceGroup.java branches/v14_4/Jmol/src/org/jmol/symmetry/UnitCell.java branches/v14_4/Jmol/src/org/jmol/util/ColorEncoder.java branches/v14_4/Jmol/src/org/jmol/viewer/Jmol.properties branches/v14_4/Jmol/src/org/jmol/viewer/Viewer.java trunk/Jmol/src/org/jmol/modelset/Text.java trunk/Jmol/src/org/jmol/render/TextRenderer.java trunk/Jmol/src/org/jmol/renderspecial/DrawRenderer.java trunk/Jmol/src/org/jmol/scriptext/CmdExt.java trunk/Jmol/src/org/jmol/scriptext/IsoExt.java trunk/Jmol/src/org/jmol/shapespecial/Polyhedra.java trunk/Jmol/src/org/jmol/symmetry/SpaceGroup.java trunk/Jmol/src/org/jmol/symmetry/UnitCell.java trunk/Jmol/src/org/jmol/util/ColorEncoder.java trunk/Jmol/src/org/jmol/viewer/Jmol.properties trunk/Jmol/src/org/jmol/viewer/Viewer.java Modified: branches/v14_4/Jmol/src/org/jmol/modelset/Text.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/modelset/Text.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/modelset/Text.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -349,7 +349,7 @@ float y = (movableYPercent != Integer.MAX_VALUE ? movableYPercent * windowHeight / 100 : is3dEcho ? movableY : movableY * scale); boxXY[1] = (is3dEcho ? y : (windowHeight - y)) + offsetY * scale; - } + } if (align == JC.TEXT_ALIGN_CENTER) boxXY[1] -= (image != null ? boxHeight : xyz != null ? boxHeight Modified: branches/v14_4/Jmol/src/org/jmol/render/TextRenderer.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/render/TextRenderer.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/render/TextRenderer.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -59,7 +59,7 @@ // now write properly aligned text for (int i = 0; i < text.lines.length; i++) { text.setXYA(temp, i); - + System.out.println("textrend x y " + temp[0] + " " + temp[1] + " " + text.lines[i]); g3d.drawString(text.lines[i], text.font, (int) temp[0], (int) temp[1], text.z, text.zSlab, text.bgcolix); } Modified: branches/v14_4/Jmol/src/org/jmol/renderspecial/DrawRenderer.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/renderspecial/DrawRenderer.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/renderspecial/DrawRenderer.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -359,6 +359,7 @@ private void renderXyPoint() { // new in Jmol 14.5 + int f = (g3d.isAntialiased() ? 2 : 1); pt0.setT(vertices[0]); if (diameter == 0) diameter = (int) width; @@ -367,11 +368,8 @@ pt0.y *= vwr.tm.height / 100f; diameter = (int) (diameter * vwr.getScreenDim() / 100f); } - if (g3d.isAntialiased()) - diameter *= 2; - pt0.y = vwr.tm.height - pt0.y; - pt0.z = vwr.tm.cameraDistance; - pt1i.set((int) pt0.x, (int) pt0.y, (int) pt0.z); + diameter *= f; + pt1i.set((int) (pt0.x * f), (int) (vwr.tm.height - pt0.y * f), (int) vwr.tm.cameraDistance); g3d.fillSphereI(diameter, pt1i); } Modified: branches/v14_4/Jmol/src/org/jmol/scriptext/CmdExt.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/scriptext/CmdExt.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/scriptext/CmdExt.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -3202,6 +3202,7 @@ eval.sm.loadShape(JC.SHAPE_POLYHEDRA); setShapeProperty(JC.SHAPE_POLYHEDRA, "init", Boolean.TRUE); float translucentLevel = Float.MAX_VALUE; + float radius = -1; int[] colorArgb = new int[] { Integer.MIN_VALUE }; P3 offset = null; String id = null; @@ -3273,8 +3274,8 @@ invArg(); if (nAtomSets > 0) invPO(); - propertyName = "radius"; - propertyValue = Float.valueOf(floatParameter(i)); + propertyName = (radius != 0 ? "radius1" : "radius"); + propertyValue = Float.valueOf(radius = floatParameter(i)); needsGenerating = true; break; case T.offset: @@ -3650,7 +3651,11 @@ } if (tokAtArray(pt, args) == T.integer) { width = SV.iValue(tokenAt(pt++, args)); + if (width <= 0) + invArg(); height = SV.iValue(tokenAt(pt++, args)); + if (height <= 0) + invArg(); } break; } @@ -3669,7 +3674,11 @@ if (tokAtArray(pt + 1, args) == T.integer && tokAtArray(pt + 2, args) == T.integer) { width = SV.iValue(tokenAt(++pt, args)); + if (width <= 0) + invArg(); height = SV.iValue(tokenAt(++pt, args)); + if (height <= 0) + invArg(); } if (tokAtArray(pt + 1, args) == T.integer) quality = SV.iValue(tokenAt(++pt, args)); Modified: branches/v14_4/Jmol/src/org/jmol/scriptext/IsoExt.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/scriptext/IsoExt.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/scriptext/IsoExt.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -393,8 +393,8 @@ points = new P3[nVertices]; for (int j = 0; j < nVertices; j++) points[j] = centerParameter(++eval.iToken); - i = eval.iToken; } + i = eval.iToken; int[][] polygons = null; switch (tokAt(i + 1)) { case T.matrix3f: Modified: branches/v14_4/Jmol/src/org/jmol/shapespecial/Polyhedra.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/shapespecial/Polyhedra.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/shapespecial/Polyhedra.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -84,7 +84,7 @@ public Polyhedron[] polyhedrons = new Polyhedron[32]; public int drawEdges; - private float radius, pointScale; + private float radius, radiusMin, pointScale; private int nVertices; float faceCenterOffset; @@ -118,7 +118,7 @@ faceCenterOffset = DEFAULT_FACECENTEROFFSET; //distanceFactor = planarParam = Float.NaN; - radius = pointScale = 0.0f; + radius = radiusMin = pointScale = 0.0f; nVertices = 0; nPoints = 0; modelIndex = -1; @@ -357,6 +357,12 @@ return; } + if ("radius1" == propertyName) { + radiusMin = radius; + radius = ((Float) value).floatValue(); + return; + } + if ("points" == propertyName) { pointScale = ((Float) value).floatValue(); pointsPolyhedra(bs, pointScale); @@ -652,13 +658,15 @@ if (bonds == null) return null; float r2 = radius * radius; + float r1 = radiusMin * radiusMin; + float r; for (int i = bonds.length; --i >= 0;) { Bond bond = bonds[i]; if (!bond.isCovalent()) continue; Atom other = bond.getOtherAtom(atom); if (bsVertices != null && !bsVertices.get(other.i) || radius > 0 - && other.distanceSquared(atom) > r2) + && ((r = other.distanceSquared(atom)) > r2 || r < r1)) continue; otherAtoms[otherAtomCount++] = other; if (otherAtomCount >= MAX_VERTICES) @@ -688,7 +696,7 @@ if (myBondingRadius == 0) return null; float bondTolerance = vwr.getFloat(T.bondtolerance); - float minBondDistance = vwr.getFloat(T.minbonddistance); + float minBondDistance = (radiusMin == 0 ? vwr.getFloat(T.minbonddistance) : radiusMin); float minBondDistance2 = minBondDistance * minBondDistance; int otherAtomCount = 0; outer: while (iter.hasNext()) { @@ -725,21 +733,23 @@ int otherAtomCount = 0; distanceRef = radius; float r2 = radius * radius; + float r2min = radiusMin * radiusMin; outer: while (iter.hasNext()) { Atom other = atoms[iter.next()]; P3 pt = iter.getPosition(); if (pt == null) { // this will happen with standard radius atom iterator pt = other; - if (bsVertices != null && !bsVertices.get(other.i) - || atom.distanceSquared(pt) > r2) + if (bsVertices != null && !bsVertices.get(other.i)) continue; } - if (other.altloc != atom.altloc && other.altloc != 0 && atom.altloc != 0) + float r = atom.distanceSquared(pt); + if (other.altloc != atom.altloc && other.altloc != 0 && atom.altloc != 0 + || r > r2 || r < r2min) continue; if (otherAtomCount == MAX_VERTICES) break; - for (int i = 0; i < otherAtomCount; i++) + for (int i = 0; i < otherAtomCount; i++) if (otherAtoms[i].distanceSquared(pt) < 0.01f) continue outer; Modified: branches/v14_4/Jmol/src/org/jmol/symmetry/SpaceGroup.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/symmetry/SpaceGroup.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/symmetry/SpaceGroup.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -555,7 +555,6 @@ } switch (h.latticeCode) { case '\0': - case 'R': case 'S': case 'T': case 'P': Modified: branches/v14_4/Jmol/src/org/jmol/symmetry/UnitCell.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/symmetry/UnitCell.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/symmetry/UnitCell.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -684,7 +684,7 @@ /** * * @param toPrimitive or assumed conventional - * @param type P, A, B, C, I(BCC), or F(FCC) + * @param type P, R, A, B, C, I(BCC), or F(FCC) * @param uc either [origin, va, vb, vc] or just [va, vb, vc] * @return true if successful */ @@ -703,24 +703,37 @@ toPrimitive = true; break; case 'A': - mf = M3.newA9(new float[] { 1, 0, 0, 0, 0.5f, -0.5f, 0, 0.5f, 0.5f}); + mf = M3.newA9(new float[] { 1, 0, 0, + 0, 0.5f, -0.5f, + 0, 0.5f, 0.5f}); break; case 'B': - mf = M3.newA9(new float[] { 0.5f, 0, -0.5f, 0, 1, 0, 0.5f, 0, 0.5f}); + mf = M3.newA9(new float[] { 0.5f, 0, -0.5f, + 0, 1, 0, + 0.5f, 0, 0.5f}); break; case 'C': - mf = M3.newA9(new float[] { 0.5f, -0.5f, 0, 0.5f, 0.5f, 0, 0, 0, 1}); + mf = M3.newA9(new float[] { 0.5f, -0.5f, 0, + 0.5f, 0.5f, 0, + 0, 0, 1}); break; + case 'R': + mf = M3.newA9(new float[] { 1/3f, 1/3f, -2/3f, + -1/3f, 2/3f, -1/3f, + 1/3f, 1/3f, 1/3f}); + break; case 'I': // f = new float[] { .5f, .5f, -.5f, -.5f, .5f, .5f, .5f, -.5f, .5f }; mf = M3.newA9(new float[] { -.5f, .5f, .5f, // was y - .5f, -.5f, .5f, // was z - .5f, .5f, -.5f });// was x + .5f, -.5f, .5f, // was z + .5f, .5f, -.5f });// was x // : new float[] { 1, 0, 1, 1, 1, 0, 0, 1, 1 }) break; case 'F': // WAS f = new float[] { .5f, .5f, 0, 0, .5f, .5f, .5f, 0, .5f }; - mf = M3.newA9(new float[] { 0, 0.5f, 0.5f, 0.5f, 0, 0.5f, 0.5f, 0.5f, 0 }); + mf = M3.newA9(new float[] { 0, 0.5f, 0.5f, + 0.5f, 0, 0.5f, + 0.5f, 0.5f, 0 }); // : new float[] { 1, -1, 1, 1, 1, -1, -1, 1, 1 }) : null); break; } Modified: branches/v14_4/Jmol/src/org/jmol/util/ColorEncoder.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/util/ColorEncoder.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/util/ColorEncoder.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -425,7 +425,7 @@ return colix; } - public int getPaletteColorCount(int palette) { + private int getPaletteColorCount(int palette) { switch (palette) { case CUSTOM: return thisScale.length; @@ -445,7 +445,7 @@ case RESU: return ce.userScale.length; case JMOL: - return argbsCpk.length; + return ce.argbsCpk.length; case RASMOL: return getRasmolScale().length; case SHAPELY: Modified: branches/v14_4/Jmol/src/org/jmol/viewer/Jmol.properties =================================================================== --- branches/v14_4/Jmol/src/org/jmol/viewer/Jmol.properties 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/viewer/Jmol.properties 2016-03-30 00:39:48 UTC (rev 21033) @@ -7,8 +7,16 @@ # see also http://chemapps.stolaf.edu/jmol/zip for daily updates -Jmol.___JmolVersion="14.4.4_2016.03.27" +Jmol.___JmolVersion="14.4.4_2016.03.29" +new feature: Polyhedra command allows for min and max radius + -- polyhedra 2.8 3.0 @3 + +bug fix: unitcell PRIMITIVE for rhombohedral groups not implemented +bug fix: unitcell("primitive","R") not implemented + +bug fix: WRITE IMAGE with negative width or height should throw a Jmol ScriptException +bug fix: draw ... [x y] does not position properly with antialias true bug fix: allow AXES TYPE "" or non-recognized to be same as "abc" bug fix: AXES TYPE "ab" should also be allowed when offset or center is set bug fix: labels should not change size when creating images of Modified: branches/v14_4/Jmol/src/org/jmol/viewer/Viewer.java =================================================================== --- branches/v14_4/Jmol/src/org/jmol/viewer/Viewer.java 2016-03-28 02:27:04 UTC (rev 21032) +++ branches/v14_4/Jmol/src/org/jmol/viewer/Viewer.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -3431,12 +3431,6 @@ setShapeProperty(JC.SHAPE_LABELS, "clearBoxes", null); imageFontScaling = (antialiased ? 2f : 1f) * (isReset || tm.scale3D || width <= 0 ? 1 : (g.zoomLarge == (height > width) ? height : width) * 1f / getScreenDim()); - System.out.println(dimScreen.width + " " + dimScreen.height - + " " + (antialiased ? 2f : 1f) - + " " + width + " " + height + " " + (isReset || width <= 0 ? 1 - : (g.zoomLarge == (height > width) ? height : width) * 1.0f / getScreenDim())); - if (imageFontScaling == 0) - System.out.println("??? viewer"); if (width > 0) { dimScreen.width = width; dimScreen.height = height; Modified: trunk/Jmol/src/org/jmol/modelset/Text.java =================================================================== --- trunk/Jmol/src/org/jmol/modelset/Text.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/modelset/Text.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -349,7 +349,7 @@ float y = (movableYPercent != Integer.MAX_VALUE ? movableYPercent * windowHeight / 100 : is3dEcho ? movableY : movableY * scale); boxXY[1] = (is3dEcho ? y : (windowHeight - y)) + offsetY * scale; - } + } if (align == JC.TEXT_ALIGN_CENTER) boxXY[1] -= (image != null ? boxHeight : xyz != null ? boxHeight Modified: trunk/Jmol/src/org/jmol/render/TextRenderer.java =================================================================== --- trunk/Jmol/src/org/jmol/render/TextRenderer.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/render/TextRenderer.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -59,7 +59,7 @@ // now write properly aligned text for (int i = 0; i < text.lines.length; i++) { text.setXYA(temp, i); - + System.out.println("textrend x y " + temp[0] + " " + temp[1] + " " + text.lines[i]); g3d.drawString(text.lines[i], text.font, (int) temp[0], (int) temp[1], text.z, text.zSlab, text.bgcolix); } Modified: trunk/Jmol/src/org/jmol/renderspecial/DrawRenderer.java =================================================================== --- trunk/Jmol/src/org/jmol/renderspecial/DrawRenderer.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/renderspecial/DrawRenderer.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -359,6 +359,7 @@ private void renderXyPoint() { // new in Jmol 14.5 + int f = (g3d.isAntialiased() ? 2 : 1); pt0.setT(vertices[0]); if (diameter == 0) diameter = (int) width; @@ -367,11 +368,8 @@ pt0.y *= vwr.tm.height / 100f; diameter = (int) (diameter * vwr.getScreenDim() / 100f); } - if (g3d.isAntialiased()) - diameter *= 2; - pt0.y = vwr.tm.height - pt0.y; - pt0.z = vwr.tm.cameraDistance; - pt1i.set((int) pt0.x, (int) pt0.y, (int) pt0.z); + diameter *= f; + pt1i.set((int) (pt0.x * f), (int) (vwr.tm.height - pt0.y * f), (int) vwr.tm.cameraDistance); g3d.fillSphereI(diameter, pt1i); } Modified: trunk/Jmol/src/org/jmol/scriptext/CmdExt.java =================================================================== --- trunk/Jmol/src/org/jmol/scriptext/CmdExt.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/scriptext/CmdExt.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -3275,7 +3275,7 @@ if (nAtomSets > 0) invPO(); propertyName = (radius != 0 ? "radius1" : "radius"); - propertyValue = Float.valueOf(floatParameter(i)); + propertyValue = Float.valueOf(radius = floatParameter(i)); needsGenerating = true; break; case T.offset: @@ -3651,7 +3651,11 @@ } if (tokAtArray(pt, args) == T.integer) { width = SV.iValue(tokenAt(pt++, args)); + if (width <= 0) + invArg(); height = SV.iValue(tokenAt(pt++, args)); + if (height <= 0) + invArg(); } break; } @@ -3670,7 +3674,11 @@ if (tokAtArray(pt + 1, args) == T.integer && tokAtArray(pt + 2, args) == T.integer) { width = SV.iValue(tokenAt(++pt, args)); + if (width <= 0) + invArg(); height = SV.iValue(tokenAt(++pt, args)); + if (height <= 0) + invArg(); } if (tokAtArray(pt + 1, args) == T.integer) quality = SV.iValue(tokenAt(++pt, args)); Modified: trunk/Jmol/src/org/jmol/scriptext/IsoExt.java =================================================================== --- trunk/Jmol/src/org/jmol/scriptext/IsoExt.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/scriptext/IsoExt.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -393,8 +393,8 @@ points = new P3[nVertices]; for (int j = 0; j < nVertices; j++) points[j] = centerParameter(++eval.iToken); - i = eval.iToken; } + i = eval.iToken; int[][] polygons = null; switch (tokAt(i + 1)) { case T.matrix3f: Modified: trunk/Jmol/src/org/jmol/shapespecial/Polyhedra.java =================================================================== --- trunk/Jmol/src/org/jmol/shapespecial/Polyhedra.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/shapespecial/Polyhedra.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -696,7 +696,7 @@ if (myBondingRadius == 0) return null; float bondTolerance = vwr.getFloat(T.bondtolerance); - float minBondDistance = vwr.getFloat(T.minbonddistance); + float minBondDistance = (radiusMin == 0 ? vwr.getFloat(T.minbonddistance) : radiusMin); float minBondDistance2 = minBondDistance * minBondDistance; int otherAtomCount = 0; outer: while (iter.hasNext()) { @@ -734,22 +734,22 @@ distanceRef = radius; float r2 = radius * radius; float r2min = radiusMin * radiusMin; - float r; outer: while (iter.hasNext()) { Atom other = atoms[iter.next()]; P3 pt = iter.getPosition(); if (pt == null) { // this will happen with standard radius atom iterator pt = other; - if (bsVertices != null && !bsVertices.get(other.i) - || (r = atom.distanceSquared(pt)) > r2 || r < r2min) + if (bsVertices != null && !bsVertices.get(other.i)) continue; } - if (other.altloc != atom.altloc && other.altloc != 0 && atom.altloc != 0) + float r = atom.distanceSquared(pt); + if (other.altloc != atom.altloc && other.altloc != 0 && atom.altloc != 0 + || r > r2 || r < r2min) continue; if (otherAtomCount == MAX_VERTICES) break; - for (int i = 0; i < otherAtomCount; i++) + for (int i = 0; i < otherAtomCount; i++) if (otherAtoms[i].distanceSquared(pt) < 0.01f) continue outer; Modified: trunk/Jmol/src/org/jmol/symmetry/SpaceGroup.java =================================================================== --- trunk/Jmol/src/org/jmol/symmetry/SpaceGroup.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/symmetry/SpaceGroup.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -555,7 +555,6 @@ } switch (h.latticeCode) { case '\0': - case 'R': case 'S': case 'T': case 'P': Modified: trunk/Jmol/src/org/jmol/symmetry/UnitCell.java =================================================================== --- trunk/Jmol/src/org/jmol/symmetry/UnitCell.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/symmetry/UnitCell.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -684,7 +684,7 @@ /** * * @param toPrimitive or assumed conventional - * @param type P, A, B, C, I(BCC), or F(FCC) + * @param type P, R, A, B, C, I(BCC), or F(FCC) * @param uc either [origin, va, vb, vc] or just [va, vb, vc] * @return true if successful */ @@ -703,24 +703,37 @@ toPrimitive = true; break; case 'A': - mf = M3.newA9(new float[] { 1, 0, 0, 0, 0.5f, -0.5f, 0, 0.5f, 0.5f}); + mf = M3.newA9(new float[] { 1, 0, 0, + 0, 0.5f, -0.5f, + 0, 0.5f, 0.5f}); break; case 'B': - mf = M3.newA9(new float[] { 0.5f, 0, -0.5f, 0, 1, 0, 0.5f, 0, 0.5f}); + mf = M3.newA9(new float[] { 0.5f, 0, -0.5f, + 0, 1, 0, + 0.5f, 0, 0.5f}); break; case 'C': - mf = M3.newA9(new float[] { 0.5f, -0.5f, 0, 0.5f, 0.5f, 0, 0, 0, 1}); + mf = M3.newA9(new float[] { 0.5f, -0.5f, 0, + 0.5f, 0.5f, 0, + 0, 0, 1}); break; + case 'R': + mf = M3.newA9(new float[] { 1/3f, 1/3f, -2/3f, + -1/3f, 2/3f, -1/3f, + 1/3f, 1/3f, 1/3f}); + break; case 'I': // f = new float[] { .5f, .5f, -.5f, -.5f, .5f, .5f, .5f, -.5f, .5f }; mf = M3.newA9(new float[] { -.5f, .5f, .5f, // was y - .5f, -.5f, .5f, // was z - .5f, .5f, -.5f });// was x + .5f, -.5f, .5f, // was z + .5f, .5f, -.5f });// was x // : new float[] { 1, 0, 1, 1, 1, 0, 0, 1, 1 }) break; case 'F': // WAS f = new float[] { .5f, .5f, 0, 0, .5f, .5f, .5f, 0, .5f }; - mf = M3.newA9(new float[] { 0, 0.5f, 0.5f, 0.5f, 0, 0.5f, 0.5f, 0.5f, 0 }); + mf = M3.newA9(new float[] { 0, 0.5f, 0.5f, + 0.5f, 0, 0.5f, + 0.5f, 0.5f, 0 }); // : new float[] { 1, -1, 1, 1, 1, -1, -1, 1, 1 }) : null); break; } Modified: trunk/Jmol/src/org/jmol/util/ColorEncoder.java =================================================================== --- trunk/Jmol/src/org/jmol/util/ColorEncoder.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/util/ColorEncoder.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -425,7 +425,7 @@ return colix; } - public int getPaletteColorCount(int palette) { + private int getPaletteColorCount(int palette) { switch (palette) { case CUSTOM: return thisScale.length; @@ -445,7 +445,7 @@ case RESU: return ce.userScale.length; case JMOL: - return argbsCpk.length; + return ce.argbsCpk.length; case RASMOL: return getRasmolScale().length; case SHAPELY: Modified: trunk/Jmol/src/org/jmol/viewer/Jmol.properties =================================================================== --- trunk/Jmol/src/org/jmol/viewer/Jmol.properties 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/viewer/Jmol.properties 2016-03-30 00:39:48 UTC (rev 21033) @@ -72,8 +72,16 @@ TODO: vector traces saved in state? TODO: slightly stronger unitcell lines for near point? -Jmol.___JmolVersion="14.5.4_2016.03.27" +Jmol.___JmolVersion="14.5.4_2016.03.29" +new feature: Polyhedra command allows for min and max radius + -- polyhedra 2.8 3.0 @3 + +bug fix: unitcell PRIMITIVE for rhombohedral groups not implemented +bug fix: unitcell("primitive","R") not implemented + +bug fix: WRITE IMAGE with negative width or height should throw a Jmol ScriptException +bug fix: draw ... [x y] does not position properly with antialias true bug fix: allow AXES TYPE "" or non-recognized to be same as "abc" bug fix: AXES TYPE "ab" should also be allowed when offset or center is set bug fix: labels should not change size when creating images of Modified: trunk/Jmol/src/org/jmol/viewer/Viewer.java =================================================================== --- trunk/Jmol/src/org/jmol/viewer/Viewer.java 2016-03-28 02:27:04 UTC (rev 21032) +++ trunk/Jmol/src/org/jmol/viewer/Viewer.java 2016-03-30 00:39:48 UTC (rev 21033) @@ -3431,12 +3431,6 @@ setShapeProperty(JC.SHAPE_LABELS, "clearBoxes", null); imageFontScaling = (antialiased ? 2f : 1f) * (isReset || tm.scale3D || width <= 0 ? 1 : (g.zoomLarge == (height > width) ? height : width) * 1f / getScreenDim()); - System.out.println(dimScreen.width + " " + dimScreen.height - + " " + (antialiased ? 2f : 1f) - + " " + width + " " + height + " " + (isReset || width <= 0 ? 1 - : (g.zoomLarge == (height > width) ? height : width) * 1.0f / getScreenDim())); - if (imageFontScaling == 0) - System.out.println("??? viewer"); if (width > 0) { dimScreen.width = width; dimScreen.height = height; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Transform Data into Opportunity. Accelerate data analysis in your applications with Intel Data Analytics Acceleration Library. Click to learn more. http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140 _______________________________________________ Jmol-commits mailing list Jmol-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-commits