From: <ha...@us...> - 2011-10-01 11:38:39
|
Revision: 16189 http://jmol.svn.sourceforge.net/jmol/?rev=16189&view=rev Author: hansonr Date: 2011-10-01 11:38:32 +0000 (Sat, 01 Oct 2011) Log Message: ----------- version=12.2.RC8 # PLEASE RELEASE AS 12.2.0 with new branch # new feature: JmolSmilesApplet method (smiles1) # new feature: JmolSmilesApplet method getRelationship(smiles1, smiles2) # bug fix: xxx = {*}; xxx.property_x = 3 improperly parsed as a script command # new feature: The Jmol application can now communicate via sockets # with other Jmol applications or specialized servers. # The SYNC command has been expanded to make this very easy: # # sync -nnnn starts a server on local port nnnn accepting only local connections # sync nnnn "background white" (from another app, generally) would execute that # command on the app acting as a server # # You can also do this from one app frame to another, because they are independent # instances of Jmol. # # Jmol can provide server service to other apps using: # # sync -3000 # [start other app, connecting on 3000] # sync 3000 ..... # # Because once the server is started and another app has connected, # Jmol will send messages to that other app, not itself. # # To test the service within one application, just create the server and send # commands to itself using a negative port number: # # sync -3000;sync -3000 'Mouse: rotateZBy 30' # # Note that in this context the "server" is the one getting commands from the "client" # But the server can also send commands to the client provided the client has given the # appropriate handshake: {"magic":"JmolApp","event":"out"} # # Sent from Jmol (via outSocket): # # {"magic" : "JmolApp", "role" : "out"} (socket initialization for messages TO jmol) # {"magic" : "JmolApp", "role" : "in"} (socket initialization for messages FROM jmol) # {"type" : "script", "event" : "done"} (script completed) # # Sent to Jmol (via inSocket): # # {"type" : "command", "command" : command } (script command request) # {"type" : "content", "id" : id } (load content request) # {"type" : "move", "style" : (see below) } (mouse command request) # {"type" : "quit" } (shut down request) # {"type" : "sync", "sync" : (see below) } (sync command request) # {"type" : "touch", (a raw touch event) # "eventType" : eventType, # "touchID" : touchID, # "iData" : idata, # "time" : time, # "x" : x, "y" : y, "z" : z } # # For details on the "touch" type, see org.jmol.viewer.ActionManagerMT::processEvent # Content is assumed to be in a location determined by the Jmol variable # nioContentPath, with %ID% being replaced by some sort of ID number of tag provided by # the other half of the system. That file contains more JSON code: # # {"startup_script" : scriptFileName, "banner_text" : text } # # An additional option "banner" : "off" turns off the title banner. # The startup script must be in the same directory as the .json file, typically as a .spt file # # Move/sync commands include: # # {"type" : "move", "style" : "rotate", "x" : deltaX, "y", deltaY } # {"type" : "move", "style" : "translate", "x" : deltaX, "y", deltaY } # {"type" : "move", "style" : "zoom", "scale" : scale } (1.0 = 100%) # {"type" : "sync", "sync" : syncText } # # Note that all these moves utilize the Jmol sync functionality originally intended for # applets. So any valid sync command may be used with the "sync" style. These include # essentially all the actions that a user can make with a mouse, including the # following, where the notation <....> represents a number of a given type. These # events interrupt any currently running script, just as with typical mouse actions. # # "centerAt <int:x> <int:y> <float:ptx> <float:pty> <float:ptz>" # -- set {ptx,pty,ptz} at screen (x,y) # "rotateMolecule <float:deltaX> <float:deltaY>" # "rotateXYBy <float:deltaX> <float:deltaY>" # "rotateZBy <int:degrees>" # "rotateZBy <int:degrees> <int:x> <int:y>" (with center reset) # "rotateArcBall <int:x> <int:y> <float:factor>" # "spinXYBy <int:x> <int:y> <float:speed>" # -- a "flick" gesture # "translateXYBy <float:deltaX, float:deltaY>" # "zoomBy <int:pixels>" # "zoomByFactor <float:factor>" # "zoomByFactor <float:factor> <int:x> <int:y>" (with center reset) # # new feature: preliminary QuantumEspresso XML reader # bug fix: getproperty minimizationInfo returns JSON instead of readable string # bug fix: JaguarReader not reading D6 MOs properly # new feature: Jmol Application flags -k and -P # -- -k kiosk mode: like applet, but with a banner across the top # -- -P <port> JSON NIO client mode over port <port> # -- for JSON NIO, use -J or -j to set nioContentPath and nioTerminatorMessage # to the desired values. For example: # Jmol -k -P 31461 -j "nioContentPath='./%ID%/%ID%.json';nioTerminatorMessage='SCRIPT_DONE'" # # code: all references to java.awt and javax.swing isolated to # org.jmol.awt, rg.jmol.export, and org.jmol.multitouch # new feature: Jmol.js adds jmolSwitchToSignedApplet(). # This needed a new <span> tag that is now inserted around the applet. # bug fix: MOLDEN reader not reading spherical basis functions # bug fix: contact command not symmetric # Set A should generally be the ligand. However, consider note: # // check for O--H...N or O...H--N and not considering # // hydrogens and still have a filter # // a bit of asymmetry here: set A may or may not have H atoms added. # // This is particularly important for amines # The issue here is that we do not assume that hydrogens have been # added to ligands. So we make some allowances there. # # bug fix: null pointer exceptions when model with unit cell is appended to model without unit cell # bug fix: CIF reader not implemented with filter "CONF n" # bug fix: unit cell not turned off in state for PDB files loaded with biomolecule # new feature: filter "_Xx" for filtering element Xx # code: refactored Jmol core Swing classes restricted to # applet, console, export, modelkit, multitouch, popup # bug fix: SMILES [#6]-[#6] should not match bonds in benzene, only biphenyl # bug fix: in SMARTS matching of SMILES string, aromatic ring conditions were not matched # TODO: Question about what c=c should do. For now, changing that to NOT match C=C of benzene Modified Paths: -------------- trunk/Jmol/src/JmolSmilesApplet.java trunk/Jmol/src/org/jmol/adapter/readers/quantum/MoldenReader.java trunk/Jmol/src/org/jmol/viewer/Jmol.properties Modified: trunk/Jmol/src/JmolSmilesApplet.java =================================================================== --- trunk/Jmol/src/JmolSmilesApplet.java 2011-09-30 19:31:27 UTC (rev 16188) +++ trunk/Jmol/src/JmolSmilesApplet.java 2011-10-01 11:38:32 UTC (rev 16189) @@ -32,6 +32,18 @@ import org.jmol.smiles.InvalidSmilesException; import org.jmol.smiles.SmilesMatcher; +/* + * JmolSmilesApplet is a small applet that can do interesting things with + * SMILES strings. It is a subset of Jmol with no graphics capability + * + * find(String pattern, String smiles, boolean isSmarts, boolean isAll) + * getLastError() + * getRelationship(String smiles1, String smiles2) + * reverseChiralit(String smiles) + * setDebug(boolean TF) + * + * + */ public class JmolSmilesApplet extends Applet { @Override @@ -101,6 +113,17 @@ return (new SmilesMatcher()).getRelationship(smiles1, smiles2); } + + /** + * reverse the chirality throughout a SMILES string + * + * @param smiles + * @return reversed chirality SMILES string + */ + public String reverseChiralit(String smiles) { + return (new SmilesMatcher()).reverseChirality(smiles); + } + @Override public String getAppletInfo() { return "JmolSmilesApplet"; Modified: trunk/Jmol/src/org/jmol/adapter/readers/quantum/MoldenReader.java =================================================================== --- trunk/Jmol/src/org/jmol/adapter/readers/quantum/MoldenReader.java 2011-09-30 19:31:27 UTC (rev 16188) +++ trunk/Jmol/src/org/jmol/adapter/readers/quantum/MoldenReader.java 2011-10-01 11:38:32 UTC (rev 16189) @@ -36,7 +36,9 @@ optOnly = checkFilter("OPTONLY"); loadGeometries = !vibOnly && desiredVibrationNumber < 0 && !checkFilter("NOOPT"); loadVibrations = !optOnly && desiredModelNumber < 0 && !checkFilter("NOVIB"); - + + if (checkFilter("NORMALIZED")) + moData.put("isNormalized", Boolean.TRUE); if (checkFilter("ALPHA")) filter = "alpha"; else if (checkFilter("BETA")) Modified: trunk/Jmol/src/org/jmol/viewer/Jmol.properties =================================================================== --- trunk/Jmol/src/org/jmol/viewer/Jmol.properties 2011-09-30 19:31:27 UTC (rev 16188) +++ trunk/Jmol/src/org/jmol/viewer/Jmol.properties 2011-10-01 11:38:32 UTC (rev 16189) @@ -1,8 +1,12 @@ # Developers: to add a description of changes you have made, # add it on a line starting with # below the "version=..." line -version=12.2.RC8_dev +version=12.2.RC8 + +# PLEASE RELEASE AS 12.2.0 with new branch + +# new feature: JmolSmilesApplet method (smiles1) # new feature: JmolSmilesApplet method getRelationship(smiles1, smiles2) # bug fix: xxx = {*}; xxx.property_x = 3 improperly parsed as a script command # new feature: The Jmol application can now communicate via sockets This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |