From 755b20d60ff16e01294e8a917520847222c7ae71 Mon Sep 17 00:00:00 2001 From: jprocter Date: Fri, 6 Nov 2009 11:52:08 +0000 Subject: [PATCH] better formed generic select residue X expression --- src/jalview/appletgui/AppletJmol.java | 10 ++++++---- src/jalview/gui/AppJmol.java | 13 ++++++++----- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/src/jalview/appletgui/AppletJmol.java b/src/jalview/appletgui/AppletJmol.java index aeec53d..4484b0c 100644 --- a/src/jalview/appletgui/AppletJmol.java +++ b/src/jalview/appletgui/AppletJmol.java @@ -544,16 +544,18 @@ public class AppletJmol extends EmbmenuFrame implements StructureListener, resetLastRes.setLength(0); resetLastRes.append("select " + pdbResNum); + eval.append(":"); + resetLastRes.append(":"); if (!chain.equals(" ")) { - eval.append(":" + chain); - resetLastRes.append(":" + chain); + eval.append(chain); + resetLastRes.append(chain); } - eval.append(";wireframe 100;" + eval.toString() + ".*;"); + eval.append(";wireframe 100;" + eval.toString() + " and not hetero;"); resetLastRes.append(";wireframe 0;" + resetLastRes.toString() - + ".*;spacefill 0;"); + + " and not hetero; spacefill 0;"); eval.append("spacefill 200;select none"); diff --git a/src/jalview/gui/AppJmol.java b/src/jalview/gui/AppJmol.java index 8e12b0d..0204ed2 100644 --- a/src/jalview/gui/AppJmol.java +++ b/src/jalview/gui/AppJmol.java @@ -611,19 +611,22 @@ public class AppJmol extends GStructureViewer implements StructureListener, resetLastRes.setLength(0); resetLastRes.append("select " + pdbResNum); + eval.append(":"); + resetLastRes.append(":"); if (!chain.equals(" ")) { - eval.append(":" + chain); - resetLastRes.append(":" + chain); + eval.append(chain); + resetLastRes.append(chain); } - eval.append(";wireframe 100;" + eval.toString() + ".*;"); + eval.append(";wireframe 100;" + eval.toString() + " and not hetero;"); // ".*;"); resetLastRes.append(";wireframe 0;" + resetLastRes.toString() - + ".*;spacefill 0;"); + //+ ".*;spacefill 0;"); + + " and not hetero;spacefill 0;"); eval.append("spacefill 200;select none"); - +// System.out.println("jmol:\n"+eval+"\n"); viewer.evalStringQuiet(eval.toString()); } -- 1.7.10.2