From: <eg...@us...> - 2009-03-08 21:33:16
|
Revision: 14375 http://cdk.svn.sourceforge.net/cdk/?rev=14375&view=rev Author: egonw Date: 2009-03-08 21:33:00 +0000 (Sun, 08 Mar 2009) Log Message: ----------- Removed benzene: too common when we are not going to match element or bond order, and upright benzenes is fixed now anyway. Replaced it with a larger ring system, which otherwise end up as a close to circle ring polygon. Modified Paths: -------------- cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/templates.list cdk/branches/cdk-1.2.x/src/test/org/openscience/cdk/layout/TemplateHandlerTest.java Added Paths: ----------- cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/ring1.cml Removed Paths: ------------- cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/benzene.cml Deleted: cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/benzene.cml =================================================================== --- cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/benzene.cml 2009-03-08 21:31:49 UTC (rev 14374) +++ cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/benzene.cml 2009-03-08 21:33:00 UTC (rev 14375) @@ -1,19 +0,0 @@ -<?xml version="1.0" encoding="ISO-8859-1"?> -<molecule id="m1" dictRef="cdk:layoutTemplate" xmlns="http://www.xml-cml.org/schema"> - <atomArray> - <atom id="a1" elementType="C" x2="-0.9898" y2="-0.7462"/> - <atom id="a2" elementType="C" x2="-0.9898" y2="0.6538"/> - <atom id="a3" elementType="C" x2="-2.2023" y2="1.3538"/> - <atom id="a4" elementType="C" x2="-3.4147" y2="0.6538"/> - <atom id="a5" elementType="C" x2="-3.4147" y2="-0.7462"/> - <atom id="a6" elementType="C" x2="-2.2023" y2="-1.4462"/> - </atomArray> - <bondArray> - <bond id="b1" atomRefs2="a1 a2" order="S"/> - <bond id="b2" atomRefs2="a2 a3" order="S"/> - <bond id="b3" atomRefs2="a3 a4" order="S"/> - <bond id="b4" atomRefs2="a4 a5" order="S"/> - <bond id="b5" atomRefs2="a5 a6" order="S"/> - <bond id="b6" atomRefs2="a6 a1" order="S"/> - </bondArray> -</molecule> Added: cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/ring1.cml =================================================================== --- cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/ring1.cml (rev 0) +++ cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/ring1.cml 2009-03-08 21:33:00 UTC (rev 14375) @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="ISO-8859-1"?> +<molecule id="m1" dictRef="cdk:layoutTemplate" xmlns="http://www.xml-cml.org/schema"> + <atomArray> + <atom id="a1" elementType="C" x2="-0.0337" y2="1.4125"/> + <atom id="a2" elementType="C" x2="1.1787" y2="0.7125"/> + <atom id="a3" elementType="C" x2="1.1787" y2="-0.6875"/> + <atom id="a4" elementType="C" x2="-1.2461" y2="-0.6875"/> + <atom id="a5" elementType="C" x2="-1.2461" y2="0.7125"/> + <atom id="a6" elementType="C" x2="1.2042" y2="-3.4714"/> + <atom id="a7" elementType="C" x2="2.3911" y2="-2.7875"/> + <atom id="a8" elementType="C" x2="2.3911" y2="-1.3875"/> + <atom id="a9" elementType="C" x2="-2.4586" y2="-1.3875"/> + <atom id="a10" elementType="C" x2="-2.4586" y2="-2.7875"/> + <atom id="a11" elementType="C" x2="-1.2461" y2="-3.4875"/> + <atom id="a13" elementType="C" x2="1.2213" y2="-4.9348"/> + <atom id="a14" elementType="C" x2="-0.0826" y2="-5.4943"/> + <atom id="a15" elementType="C" x2="-1.2461" y2="-4.8875"/> + </atomArray> + <bondArray> + <bond id="b1" atomRefs2="a1 a2" order="S"/> + <bond id="b2" atomRefs2="a2 a3" order="S"/> + <bond id="b3" atomRefs2="a4 a5" order="S"/> + <bond id="b4" atomRefs2="a5 a1" order="S"/> + <bond id="b5" atomRefs2="a6 a7" order="S"/> + <bond id="b6" atomRefs2="a7 a8" order="S"/> + <bond id="b7" atomRefs2="a8 a3" order="S"/> + <bond id="b8" atomRefs2="a4 a9" order="S"/> + <bond id="b9" atomRefs2="a9 a10" order="S"/> + <bond id="b10" atomRefs2="a10 a11" order="S"/> + <bond id="b11" atomRefs2="a6 a13" order="S"/> + <bond id="b12" atomRefs2="a13 a14" order="S"/> + <bond id="b13" atomRefs2="a14 a15" order="S"/> + <bond id="b14" atomRefs2="a15 a11" order="S"/> + </bondArray> +</molecule> Modified: cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/templates.list =================================================================== --- cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/templates.list 2009-03-08 21:31:49 UTC (rev 14374) +++ cdk/branches/cdk-1.2.x/src/main/org/openscience/cdk/layout/templates/templates.list 2009-03-08 21:33:00 UTC (rev 14375) @@ -1,5 +1,5 @@ adamantane.cml cubane.cml diamantane.cml -benzene.cml sterane.cml +ring1.cml Modified: cdk/branches/cdk-1.2.x/src/test/org/openscience/cdk/layout/TemplateHandlerTest.java =================================================================== --- cdk/branches/cdk-1.2.x/src/test/org/openscience/cdk/layout/TemplateHandlerTest.java 2009-03-08 21:31:49 UTC (rev 14374) +++ cdk/branches/cdk-1.2.x/src/test/org/openscience/cdk/layout/TemplateHandlerTest.java 2009-03-08 21:33:00 UTC (rev 14375) @@ -86,7 +86,7 @@ @Test public void testOtherElements() throws Exception { boolean itIsInThere = false; TemplateHandler th = new TemplateHandler(DefaultChemObjectBuilder.getInstance()); - IMolecule mol = MoleculeFactory.makeCyclohexane(); + IMolecule mol = MoleculeFactory.makeSteran(); itIsInThere = th.mapTemplates(mol); Assert.assertTrue(itIsInThere); mol.getAtom(0).setSymbol("N"); @@ -100,7 +100,7 @@ @Test public void testOtherBondOrder() throws Exception { boolean itIsInThere = false; TemplateHandler th = new TemplateHandler(DefaultChemObjectBuilder.getInstance()); - IMolecule mol = MoleculeFactory.makeCyclohexane(); + IMolecule mol = MoleculeFactory.makeSteran(); itIsInThere = th.mapTemplates(mol); Assert.assertTrue(itIsInThere); mol.getBond(0).setOrder(IBond.Order.DOUBLE); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |