From: James Procter
Date: Thu, 2 Nov 2023 23:34:39 +0000 (+0000)
Subject: Merge branch 'develop' into releases/Release_2_11_3_Branch
X-Git-Tag: Release_2_11_3_0~3
X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=893f21fe8df6a9d47ced8140e3ba75f03407be00;hp=ecc31307701d785d41f503484fa5a823580ea79f;p=jalview.git
Merge branch 'develop' into releases/Release_2_11_3_Branch
---
diff --git a/build.gradle b/build.gradle
index 8ac2757..011be67 100644
--- a/build.gradle
+++ b/build.gradle
@@ -52,7 +52,7 @@ plugins {
id 'application'
id 'eclipse'
id "com.diffplug.gradle.spotless" version "3.28.0"
- id 'com.github.johnrengelman.shadow' version '4.0.3'
+ id 'com.github.johnrengelman.shadow' version '6.0.0'
id 'com.install4j.gradle' version '10.0.3'
id 'com.dorongold.task-tree' version '2.1.1' // only needed to display task dependency tree with gradle task1 [task2 ...] taskTree
id 'com.palantir.git-version' version '0.13.0' apply false
@@ -1851,7 +1851,9 @@ tasks.withType(Test).matching {t -> t.getName().startsWith("testTask")}.all { te
showExceptions true
showCauses true
showStackTraces true
-
+ if (test_output) {
+ showStandardStreams true
+ }
info.events = [ TestLogEvent.FAILED ]
}
@@ -2154,12 +2156,33 @@ shadowJar {
if (buildDist) {
dependsOn makeDist
}
- from ("${jalviewDir}/${libDistDir}") {
- include("*.jar")
- }
- manifest {
- attributes "Implementation-Version": JALVIEW_VERSION,
- "Application-Name": applicationName
+
+ def jarFiles = fileTree(dir: "${jalviewDir}/${libDistDir}", include: "*.jar", exclude: "regex.jar").getFiles()
+ def groovyJars = jarFiles.findAll {it1 -> file(it1).getName().startsWith("groovy-swing")}
+ def otherJars = jarFiles.findAll {it2 -> !file(it2).getName().startsWith("groovy-swing")}
+ from groovyJars
+ from otherJars
+
+ // we need to include the groovy-swing Include-Package for it to run in the shadowJar
+ doFirst {
+ def jarFileManifests = []
+ groovyJars.each { jarFile ->
+ def mf = zipTree(jarFile).getFiles().find { it.getName().equals("MANIFEST.MF") }
+ if (mf != null) {
+ jarFileManifests += mf
+ }
+ }
+
+ manifest {
+ attributes "Implementation-Version": JALVIEW_VERSION, "Application-Name": applicationName
+ from (jarFileManifests) {
+ eachEntry { details ->
+ if (!details.key.equals("Import-Package")) {
+ details.exclude()
+ }
+ }
+ }
+ }
}
duplicatesStrategy "INCLUDE"
@@ -3021,6 +3044,7 @@ task sourceDist(type: Tar) {
into project.name
def EXCLUDE_FILES=[
+ "dist/*",
"build/*",
"bin/*",
"test-output/",
diff --git a/doc/building.md b/doc/building.md
index 34d5d67..bbcc011 100644
--- a/doc/building.md
+++ b/doc/building.md
@@ -23,10 +23,10 @@ java -jar getdown-launcher.jar . jalview
> To get set up using _only_ the Eclipse IDE () then please see the section [Setting up in Eclipse IDE](#setting-up-in-eclipse-ide)
-The method here is described in terms of using a command line. You can easily do this on linux or in a Terminal window in macOS. You can do it in Windows.
+The method here is described assumes using a command line. You can easily do this on linux or in a Terminal window in macOS. You can do it in Windows.
* Java 11 compliant JDK
-* gradle 5.2 or above *(NB gradle 6.6 and above currently produces NullPointerExceptions during the build. This is non-fatal and does not affect the build. Use gradle 6.5.1 to avoid this)*
+* gradle 7.6.3 or above, but not gradle 8
* git
> The versions and installation methods here are just suggestions (which we have tested
@@ -336,7 +336,7 @@ the `tests/` folder. A summary of results should appear in your console.
You can run different defined groups of tests with
```bash
-gradle test -PtestngGroups=Network
+gradle test -Ptestng_groups=Network
```
Available groups include Functional (default), Network, External.
@@ -348,9 +348,15 @@ Some of Jalview's Functional tests don't pass reliably in all environments. We t
To exclude one or more groups of tests, add them as a comma separated list in testngExcludedGroups.
```bash
-gradle test -PtestngExcludedGroups=Not-bamboo
+gradle test -Ptestng_excluded_groups=Not-bamboo
```
+#### Viewing stdout and stderr for tests
+By default, gradle doesn't report any of the output or error streams produced by tests. You can enable output by setting the following:
+
+```bash
+gradle test -Ptest_output=1
+```
### Installer packaging with *install4j*
diff --git a/examples/groovy/ComputePeptideVariants.groovy b/examples/groovy/ComputePeptideVariants.groovy
index 6caa69c..e5ece51 100644
--- a/examples/groovy/ComputePeptideVariants.groovy
+++ b/examples/groovy/ComputePeptideVariants.groovy
@@ -1,6 +1,6 @@
import jalview.datamodel.SequenceFeature
import jalview.gui.Desktop
-def af = jalview.bin.Jalview.currentAlignFrame
+def af = Jalview.getCurrentAlignFrame()
def av = af.viewport
def fr = Desktop.getAlignFrameFor(av.codingComplement).getFeatureRenderer()
def counts = 0
@@ -29,4 +29,4 @@ for (seq in av.alignment.sequences)
}
af.getFeatureRenderer().featuresAdded()
af.alignPanel.paintAlignment(true, true)
-println "Added " + countm + " missense and " + counts + " synonymous variants"
\ No newline at end of file
+println "Added " + countm + " missense and " + counts + " synonymous variants"
diff --git a/examples/groovy/JvLoadTester.groovy b/examples/groovy/JvLoadTester.groovy
index d844d62..cc92e40 100644
--- a/examples/groovy/JvLoadTester.groovy
+++ b/examples/groovy/JvLoadTester.groovy
@@ -21,7 +21,7 @@
import jalview.gui.*;
import jalview.io.*;
-def class JvLoadTest {
+class JvLoadTest {
FileLoader fl = null;
def String safename = null;
JvLoadTest(String sname) {
@@ -155,4 +155,4 @@ def JvLoadTest newJvLoadTest(String tempFile) {
System.gc();
jalview.gui.Desktop.instance.desktop.showMemoryUsage(true);
return new JvLoadTest(tempFile)
-}
\ No newline at end of file
+}
diff --git a/examples/groovy/PIDmatrix.groovy b/examples/groovy/PIDmatrix.groovy
index b97abcc..76b9de7 100644
--- a/examples/groovy/PIDmatrix.groovy
+++ b/examples/groovy/PIDmatrix.groovy
@@ -56,7 +56,7 @@ printSimilarityMatrix(true,true,SimilarityParams.Jalview)
void printSimilarityMatrix(boolean selview=false, boolean includeids=true, SimilarityParams pidMethod) {
- def currentAlignFrame = jalview.bin.Jalview.getCurrentAlignFrame()
+ def currentAlignFrame = Jalview.getCurrentAlignFrame()
jalview.gui.AlignViewport av = currentAlignFrame.getCurrentView()
@@ -96,4 +96,4 @@ void printSimilarityMatrix(boolean selview=false, boolean includeids=true, Simil
print "\n"
}
-}
\ No newline at end of file
+}
diff --git a/examples/groovy/alignLoadedFile.groovy b/examples/groovy/alignLoadedFile.groovy
index 764fdae..df68e2b 100644
--- a/examples/groovy/alignLoadedFile.groovy
+++ b/examples/groovy/alignLoadedFile.groovy
@@ -20,6 +20,7 @@
*/
// run an alignment on the current alignFrame
import jalview.ws.jws2.*;
+import jalview.ws.jws2.jabaws2.Jws2Instance;
import jalview.datamodel.*;
// First get the JABA service discoverer and see if there are any services.
@@ -33,7 +34,7 @@ if (!disc.isRunning() && !disc.hasServices())
disc.run();
}
-for (jalview.ws.jws2.Jws2Discoverer.Jws2Instance service: disc.getServices()) {
+for (jalview.ws.jws2.jabaws2.Jws2Instance service: disc.getServices()) {
if (service.serviceType.indexOf("uscle")>-1) {
// now - go through the services if any, and find a Muscle service
diff --git a/examples/groovy/annotationForSelectedSequence.groovy b/examples/groovy/annotationForSelectedSequence.groovy
index abfad35..7cb3082 100644
--- a/examples/groovy/annotationForSelectedSequence.groovy
+++ b/examples/groovy/annotationForSelectedSequence.groovy
@@ -31,7 +31,7 @@ import java.awt.datatransfer.StringSelection
import static java.awt.Toolkit.*
-def curviewport = Jalview.getAlignFrames()[Jalview.getAlignFrames().length-1].getViewport();
+def curviewport = Jalview.getCurrentAlignFrame().getViewport();
// TSV output by default.
// change "\t" to "," to output CSV file
diff --git a/examples/groovy/parseproperties.groovy b/examples/groovy/parseproperties.groovy
index 879bd49..ceec6d2 100644
--- a/examples/groovy/parseproperties.groovy
+++ b/examples/groovy/parseproperties.groovy
@@ -1,19 +1,19 @@
/*
* Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
* Copyright (C) $$Year-Rel$$ The Jalview Authors
- *
+ *
* This file is part of Jalview.
- *
+ *
* Jalview is free software: you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
+ * modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation, either version 3
* of the License, or (at your option) any later version.
- *
- * Jalview is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+ *
+ * Jalview is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE. See the GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with Jalview. If not, see .
* The Jalview Authors are detailed in the 'AUTHORS' file.
@@ -23,10 +23,9 @@ import jalview.datamodel.*;
import jalview.gui.AlignFrame;
import jalview.gui.AlignViewport;
-def af = Jalview.getAlignFrames();
-def al = af[0].viewport.alignment;
+def al = Jalview.getCurrentAlignFrame().viewport.alignment;
ParseProperties pp = new ParseProperties(al);
-pp.getScoresFromDescription("Score", "ScanPS Raw Score", "([-0-9.+]+)");
+pp.getScoresFromDescription("Score", "ScanPS Raw Score", "([-0-9.+]+)", true);
def sqs = al.getSequenceAt(0);
def annots = sqs.getAnnotation();
diff --git a/examples/groovy/printtitle.groovy b/examples/groovy/printtitle.groovy
index b3387ea..a048d65 100644
--- a/examples/groovy/printtitle.groovy
+++ b/examples/groovy/printtitle.groovy
@@ -1,35 +1,35 @@
/*
* Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
* Copyright (C) $$Year-Rel$$ The Jalview Authors
- *
+ *
* This file is part of Jalview.
- *
+ *
* Jalview is free software: you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
+ * modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation, either version 3
* of the License, or (at your option) any later version.
- *
- * Jalview is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+ *
+ * Jalview is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE. See the GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with Jalview. If not, see .
* The Jalview Authors are detailed in the 'AUTHORS' file.
*/
// do something groovy in jalview
println "Hello World.\n"
-println "First sequence is " + currentAlFrame.viewport.alignment.getSequenceAt(0).getDisplayId(true)
+println "First sequence is " + Jalview.getCurrentAlignFrame().viewport.alignment.getSequenceAt(0).getDisplayId(true)
def alf = Jalview.getAlignFrames()
for (ala in alf)
{
- // ala is an jalview.gui.AlignFrame object
+ // ala is an jalview.gui.AlignFrame object
println ala.getTitle()
// get the parent jalview.datamodel.Alignment from the alignment viewport
def alignment = ala.viewport.alignment
// get the first sequence from the jalview.datamodel.Alignment object
- def seq = alignment.getSequenceAt(0)
+ def seq = alignment.getSequenceAt(0)
}
Jalview.quit()
diff --git a/examples/groovy/removeFeaturesByGroup.groovy b/examples/groovy/removeFeaturesByGroup.groovy
index 341e06f..c947a5b 100644
--- a/examples/groovy/removeFeaturesByGroup.groovy
+++ b/examples/groovy/removeFeaturesByGroup.groovy
@@ -46,6 +46,7 @@ for (ala in af)
}
}
}
+ ala.repaint();
}
diff --git a/examples/groovy/selectColumnsByFeatureAndGroup.groovy b/examples/groovy/selectColumnsByFeatureAndGroup.groovy
index b8edaa7..aaa3405 100644
--- a/examples/groovy/selectColumnsByFeatureAndGroup.groovy
+++ b/examples/groovy/selectColumnsByFeatureAndGroup.groovy
@@ -23,7 +23,7 @@ import jalview.datamodel.*;
import jalview.gui.AlignFrame;
import jalview.gui.AlignViewport;
import java.util.BitSet;
-import javax.swing.JOptionPane;
+import jalview.gui.JvOptionPane;
import groovy.swing.SwingBuilder;
def toselect = getFeatureInput(); // change this to select the desired feature type
@@ -81,7 +81,7 @@ for (ala in Jalview.getAlignFrames()) {
cs.addElement(i);
}
ala.viewport.setColumnSelection(cs);
- ala.alignPanel.paintAlignment(true);
+ ala.alignPanel.paintAlignment(true, true);
ala.statusBar.setText("Marked "+bs.cardinality()+" columns containing features of type "+toselect)
} else {
ala.statusBar.setText("No features of type "+toselect+" found.");
@@ -96,4 +96,4 @@ String getFeatureInput(){
null, 'Select columns by feature by type','Enter type of feature', JvOptionPane.OK_OPTION)
return response
- }
\ No newline at end of file
+ }
diff --git a/examples/groovy/sitesForSelectedColumns.groovy b/examples/groovy/sitesForSelectedColumns.groovy
index 8165373..f775f18 100644
--- a/examples/groovy/sitesForSelectedColumns.groovy
+++ b/examples/groovy/sitesForSelectedColumns.groovy
@@ -29,7 +29,7 @@
import java.awt.datatransfer.StringSelection
import static java.awt.Toolkit.*
-def curviewport = Jalview.getAlignFrames()[Jalview.getAlignFrames().length-1].getViewport()
+def curviewport = Jalview.getCurrentAlignFrame().getViewport()
def debug = false
diff --git a/examples/groovy/stripUniprotPrefixes.groovy b/examples/groovy/stripUniprotPrefixes.groovy
index 71b3a9f..5a01da4 100644
--- a/examples/groovy/stripUniprotPrefixes.groovy
+++ b/examples/groovy/stripUniprotPrefixes.groovy
@@ -29,7 +29,7 @@ def af = Jalview.getAlignFrames();
for (ala in af)
{
- def al = ala.viewport.alignment;
+ def al = ala.getViewport().getAlignment();
if (al!=null)
{
SequenceI[] seqs = al.getSequencesArray();
@@ -47,5 +47,6 @@ for (ala in af)
}
}
}
+ ala.repaint();
}
-
\ No newline at end of file
+
diff --git a/examples/groovy/visibleFeaturesCounter.groovy b/examples/groovy/visibleFeaturesCounter.groovy
index b3180f8..510f600 100644
--- a/examples/groovy/visibleFeaturesCounter.groovy
+++ b/examples/groovy/visibleFeaturesCounter.groovy
@@ -1,38 +1,37 @@
/*
* Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
* Copyright (C) $$Year-Rel$$ The Jalview Authors
- *
+ *
* This file is part of Jalview.
- *
+ *
* Jalview is free software: you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
+ * modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation, either version 3
* of the License, or (at your option) any later version.
- *
- * Jalview is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+ *
+ * Jalview is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE. See the GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with Jalview. If not, see .
* The Jalview Authors are detailed in the 'AUTHORS' file.
*/
-import jalview.bin.Jalview
import jalview.workers.FeatureSetCounterI
import jalview.workers.AlignmentAnnotationFactory
/*
* Demonstration of FeatureSetCounterI
- * compute annotation tracks counting number of displayed
+ * compute annotation tracks counting number of displayed
* features of each type in each column
*/
/*
* discover features on the current view
*/
-
-def featuresDisp=Jalview.currentAlignFrame.currentView.featuresDisplayed
+
+def featuresDisp=Jalview.getCurrentAlignFrame().currentView.featuresDisplayed
if (featuresDisp == null) {
print 'Need at least one feature visible on alignment'
}
@@ -40,12 +39,12 @@ def visibleFeatures=featuresDisp.visibleFeatures.toList()
assert 'java.util.ArrayList' == visibleFeatures.class.name
/*
- * A closure that returns an array of features present
+ * A closure that returns an array of features present
* for each feature type in visibleFeatures
- * Argument 'features' will be a list of SequenceFeature
+ * Argument 'features' will be a list of SequenceFeature
*/
-def getCounts =
- { features ->
+def getCounts =
+ { features ->
int[] obs = new int[visibleFeatures.size]
for (sf in features)
{
@@ -56,9 +55,9 @@ def getCounts =
* or sf.getValue(attributeName) for GFF 'column 9' properties
*/
int pos = 0
- for (type in visibleFeatures)
+ for (type in visibleFeatures)
{
- if (type.equals(sf.type))
+ if (type.equals(sf.type))
{
obs[pos]++
}
@@ -67,19 +66,19 @@ def getCounts =
}
obs
}
-
+
/*
* Define something that counts each visible feature type
*/
def columnSetCounter =
[
- getNames: { visibleFeatures as String[] },
+ getNames: { visibleFeatures as String[] },
getDescriptions: { visibleFeatures as String[] },
getMinColour: { [0, 255, 255] as int[] }, // cyan
getMaxColour: { [0, 0, 255] as int[] }, // blue
- count:
- { res, feats ->
- getCounts.call(feats)
+ count:
+ { res, feats ->
+ getCounts.call(feats)
}
] as FeatureSetCounterI
diff --git a/getdown/lib/FJVL_VERSION b/getdown/lib/FJVL_VERSION
index 25d39f4..2d83e61 100644
--- a/getdown/lib/FJVL_VERSION
+++ b/getdown/lib/FJVL_VERSION
@@ -1 +1 @@
-1.8.3-1.3.0_FJVL
+1.8.3-1.3.1_FJVL
diff --git a/getdown/lib/JVL_VERSION b/getdown/lib/JVL_VERSION
index 12110b2..7d618e2 100644
--- a/getdown/lib/JVL_VERSION
+++ b/getdown/lib/JVL_VERSION
@@ -1 +1 @@
-1.8.3-1.3.0_JVL
+1.8.3-1.3.1_JVL
diff --git a/getdown/lib/getdown-core.jar b/getdown/lib/getdown-core.jar
index fb8f1bc..3fc97b5 100644
Binary files a/getdown/lib/getdown-core.jar and b/getdown/lib/getdown-core.jar differ
diff --git a/getdown/lib/getdown-launcher-local.jar b/getdown/lib/getdown-launcher-local.jar
index c74dcc5..6ba0a6d 100644
Binary files a/getdown/lib/getdown-launcher-local.jar and b/getdown/lib/getdown-launcher-local.jar differ
diff --git a/getdown/lib/getdown-launcher.jar b/getdown/lib/getdown-launcher.jar
index e1f1726..7c75a34 100644
Binary files a/getdown/lib/getdown-launcher.jar and b/getdown/lib/getdown-launcher.jar differ
diff --git a/getdown/src/getdown/ant/pom.xml b/getdown/src/getdown/ant/pom.xml
index d8bb7e9..4c91f74 100644
--- a/getdown/src/getdown/ant/pom.xml
+++ b/getdown/src/getdown/ant/pom.xml
@@ -4,7 +4,7 @@
com.threerings.getdowngetdown
- 1.8.3-1.3.0_FJVL
+ 1.8.3-1.3.1_FJVLgetdown-ant
diff --git a/getdown/src/getdown/core/pom.xml b/getdown/src/getdown/core/pom.xml
index 6126686..2e43522 100644
--- a/getdown/src/getdown/core/pom.xml
+++ b/getdown/src/getdown/core/pom.xml
@@ -4,7 +4,7 @@
com.threerings.getdowngetdown
- 1.8.3-1.3.0_FJVL
+ 1.8.3-1.3.1_FJVLgetdown-core
diff --git a/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java b/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java
index 9d9fe14..435ebbd 100644
--- a/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java
+++ b/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java
@@ -1137,7 +1137,6 @@ public class Application
String query = jalviewUri.getQuery();
_appargs.clear();
- _appargs.add("-open");
if (host != null && host.length() > 0) {
URL newUrl = new URL(
(https?"https":"http")
@@ -1253,8 +1252,6 @@ public class Application
}
if (ext != null && LOCATOR_FILE_EXTENSION.equals(ext.toLowerCase(Locale.ROOT))) {
// this file extension should have been dealt with in Getdown class
- } else {
- _appargs.add(0, "-open");
}
}
diff --git a/getdown/src/getdown/launcher/pom.xml b/getdown/src/getdown/launcher/pom.xml
index 4374899..c6b9ff3 100644
--- a/getdown/src/getdown/launcher/pom.xml
+++ b/getdown/src/getdown/launcher/pom.xml
@@ -4,7 +4,7 @@
com.threerings.getdowngetdown
- 1.8.3-1.3.0_FJVL
+ 1.8.3-1.3.1_FJVLgetdown-launcher
diff --git a/getdown/src/getdown/mvn_cmd b/getdown/src/getdown/mvn_cmd
index ba092a7..10942f8 100755
--- a/getdown/src/getdown/mvn_cmd
+++ b/getdown/src/getdown/mvn_cmd
@@ -3,7 +3,7 @@
if [ x$JVLVERSION != x ]; then
export VERSION=$JVLVERSION
else
- export VERSION=1.8.3-1.3.0_JVL
+ export VERSION=1.8.3-1.3.1_JVL
fi
if [ x${VERSION%_JVL} = x$VERSION ]; then
diff --git a/getdown/src/getdown/pom.xml b/getdown/src/getdown/pom.xml
index 51e9514..cf32333 100644
--- a/getdown/src/getdown/pom.xml
+++ b/getdown/src/getdown/pom.xml
@@ -10,7 +10,7 @@
com.threerings.getdowngetdownpom
- 1.8.3-1.3.0_FJVL
+ 1.8.3-1.3.1_FJVLgetdownAn application installer and updater.
diff --git a/gradle.properties b/gradle.properties
index c2e217f..79fb11d 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -28,6 +28,8 @@ jalview_keydig = SHA1
testng_groups = Functional
testng_excluded_groups =
+test_output =
+
j8libDir = j8lib
j11libDir = j11lib
diff --git a/help/help/html/features/clarguments-reference.html b/help/help/html/features/clarguments-reference.html
index b2e29e9..b1588e5 100644
--- a/help/help/html/features/clarguments-reference.html
+++ b/help/help/html/features/clarguments-reference.html
@@ -92,6 +92,11 @@
+
‑‑javaconsole / ‑‑nojavaconsole
+
Show (/ or don't show) the Java Console. Using one of these overrides any saved Preference.
+
+
+
‑‑questionnaire / ‑‑noquestionnaire
Show (/ or don't show) the questionnaire if one is available.
diff --git a/help/help/html/features/groovy.html b/help/help/html/features/groovy.html
index cb0b10c..6b5c4c0 100644
--- a/help/help/html/features/groovy.html
+++ b/help/help/html/features/groovy.html
@@ -20,11 +20,11 @@
* The Jalview Authors are detailed in the 'AUTHORS' file.
-->
-Groovy Shell
+Groovy Console
- The Groovy Shell
+ The Groovy Console
Groovy (www.groovy-lang.org)
@@ -41,8 +41,8 @@
short pause, you should then see the Groovy
Console appear. This allows you to interactively execute Groovy
- scripts whilst Jalview is running. We've also provided a Calculations→Execute
- Groovy Script button so you can execute the currently loaded
+ scripts whilst Jalview is running. We've also provided a Calculations→Run
+ Groovy Console Script button so you can execute the currently loaded
groovy script whilst viewing an alignment.
@@ -63,31 +63,36 @@
we recommend you also take a look at Jalview's source, since all the
public methods of the jalview class hierarchy can be called from
Groovy scripts. In addition, the following objects are also defined:
+
-
-
-
Jalview - this is bound to jalview.bin.Jalview. Useful
- methods include:
+
Jalview - this is bound to jalview.bin.groovy.JalviewObject providing access to the following useful
+ methods:
Jalview.getAlignFrames() - returns a list of
jalview.gui.AlignFrame objects
Jalview.getCurrentAlignFrame() - returns the alignment
- window which is currently being looked at by the user
+ window which has most recently been in focus. If you change focus to another alignment window then re-running Jalview.getCurrentAlignFrame() will return the new AlignFrame.
-
currentAlFrame - this is only defined when
- running a Groovy script via the --groovy command line argument. It
- returns the first alignment window created after acting on the
- other arguments passed on the command line.
+
currentAlFrame When used on the command line this refers to the current opened alignment.
+
+ When used from the Groovy Console, it refers to the alignment that was in focus when the Groovy Console was opened.
+
+ When a Groovy Console script is run from Calculate->Run Groovy Console Script, currentAlFrame us updated to that alignment.
+ If you specify a --groovy argument before an --open argument
+ then you should ensure your script doesn't refer to currentAlFrame.
+
+
+
A simple script
Getting the title, alignment and first sequence from the
current alignFrame
Show Chains Select which of the PDB file's chains are to be
displayed.
-
Colour by .. Submenu
+
Ligands
+ When available, allows the display of all, none or specific
+ ligands (also known as HETATM groups) in the Jmol view, using CPK
+ spacefilling.
+
Colour by .. Submenu
allowing specific alignment views to be selected for
colouring associated chains in the structure display. This
menu contains all the alignment views associated with the
diff --git a/help/help/html/features/xsspannotation.html b/help/help/html/features/xsspannotation.html
index 870b005..5f33dfe 100644
--- a/help/help/html/features/xsspannotation.html
+++ b/help/help/html/features/xsspannotation.html
@@ -29,8 +29,9 @@
Jalview can process PDB data associated with sequences to display
values extracted from the Temperature Factor column for
- corresponding sites, and secondary structure from DSSP or RNAView
- (as appropriate).
+ corresponding sites, and secondary structure from DSSP. For computationally determined structures, jalview will show
+ model quality data encoded in the temperature factor column as AlphaFold Reliability (PLDDT) or Model
+ Quality as appropriate.
Extracting data from PDB files Annotation is
@@ -43,20 +44,21 @@
the Add Reference Annotation in the Selection
and Sequence ID sub-menus of the Sequence ID
Panel's popup menu. Please note:Protein structures
- are analysed in situ, but Jalview employs a web service to
- process RNA structures which can cause long delays if your internet
- connection is slow.
+ are analysed in situ.
The Annotations
alignment menu provides settings useful for controlling the
- display of secondary structure annotation.
-
+ display of sequence-associated annotation. To compare several tracks from different structures for one or more
+ sequences, use 'sort by label' - which will also display PDB and Chain IDs for secondary structure and temperature
+ factor/quality annotation tracks for easier identification.
+
Shading sequences by associated structure
annotation The annotation colouring dialog (opened by the Colour→By
- Annotation option) allows sequences with associated secondary
+ Annotation option) or by right-clicking a particular annotation tracks's label allows sequences with
+ associated secondary
structure data to be shaded according to secondary structure type.
Once the dialog is opened, select the Per Sequence option
and then choose Secondary structure from the dropdown menu. When
diff --git a/help/help/html/groovy/featuresCounter.html b/help/help/html/groovy/featuresCounter.html
index bd7144e..494dd3e 100644
--- a/help/help/html/groovy/featuresCounter.html
+++ b/help/help/html/groovy/featuresCounter.html
@@ -36,7 +36,7 @@
Copy and paste it into the groovy script console
Load the example Feredoxin project (the one that opens by
default when you first launched Jalview)
-
Select Calculations→Execute Groovy
+
Select Calculations→Run Groovy Console
Script from the alignment window's menu bar to run the script on
the current view.
For more information, you might also want to take a look at the
documentation section of the Jalview website (https://www.jalview.org/about/documentation).
+ href="https://www.jalview.org/help">https://www.jalview.org/help).
If you are using the Jalview Desktop application and are looking for
diff --git a/help/help/html/logging.html b/help/help/html/logging.html
index a7da021..547fff2 100644
--- a/help/help/html/logging.html
+++ b/help/help/html/logging.html
@@ -163,7 +163,7 @@
If you come across a problem in Jalview where something is not
working as described, or how you think it should, you should first
- check the Jalview FAQ to
+ check the Jalview FAQ to
see if this is a known problem and if there is a suggested
workaround.
diff --git a/help/markdown/releases/release-2_11_3_0.md b/help/markdown/releases/release-2_11_3_0.md
index 8847eb2..cdd74eb 100644
--- a/help/markdown/releases/release-2_11_3_0.md
+++ b/help/markdown/releases/release-2_11_3_0.md
@@ -1,6 +1,6 @@
---
version: 2.11.3.0
-date: 2023-10-03
+date: 2023-11-03
channel: "release"
---
@@ -18,12 +18,14 @@ channel: "release"
- sequence descriptions are updated from database reference sources if not already defined
- Visible adjuster marks to grab and adjust annotation panel height and id width
- Adjustable ID margin when alignment is wrapped
-- Command line options and configurable bitmap export preferences for height, width and scale factor
+- Command line options and configurable bitmap export (via preferences file) for height, width and scale factor
+- Show or hide ligands in a Jmol structure view via View Ligands submenu
+- Jmol's display is antialiased by default (smoother, less pixellated)
-### Improved support for working with computationally determined models
+### Improved support for working with structures and computationally determined models
- Alphafold red/orange/yellow/green colourscheme for structures
- Interactive picking of low pAE score regions
-- contact matrix datatype in Jalview
+- Predicted Alignment Error annotation tracks for structures from AlphaFold DB
- Selections with visual feedback via contact matrix annotation
- Discover and import alphafold2 models and metadata from https://alphafold.ebi.ac.uk/
- Visual indication of relationship with associated sequence to distinguish different sequence associated annotation rows
@@ -32,7 +34,11 @@ channel: "release"
- Import and display alphafold alignment uncertainty matrices from JSON
- Column-wise alignment groups and selections and interactive tree viewer for PAE matrices
- Store/Restore PAE data and visualisation settings from Jalview Project
+- Store and restore adjustable ID margin and annotation panel height in Jalview projects
- Multiple residue sidechain highlighting in structure viewers from PAE mouseovers
+- Per-structure and chain shown when annotation shown sorted by label enabling secondary structure and temperature factor scores from different chains and structures for the same sequence to be visually compared.
+- PDB or mmCIF files with chains with negative RESNUMs for their whole sequence extent cannot be linked to alignments
+
### Jalview on the command line
- New command line argument framework allowing flexible batch processing, import of structures, pae matrices and other sequence associated data, and alignment and structure figure generation.
@@ -40,14 +46,14 @@ channel: "release"
- Assume --headless when jalview is run with a command line argument that generates output
- Automatically adjust Left margin on import to avoid cropping of annotation labels & sequence IDs
- Specify alignment title on import via --title argument
-- sensible responses from the CLI when things go wrong during image export
-- Add a command line option to set Jalview properties for this session only
-- Add a command line option to suppress opening the startup file for this session
+- Sensible responses from the CLI when things go wrong during image export
+- Add a command line option to set Jalview properties for this session only
+- Add a command line option to suppress opening the startup file for this session
### Other improvements
- Secondary structure annotation glyphs are rendered anti-aliasing when enabled
-- Helix and Sheet glyphs vertically centered with respect to grey coil secondary structure annotation track
-- Lower line of the sequence group border does not align with vertical and background residue box
+- Helix and Sheet glyphs vertically centred with respect to grey coil secondary structure annotation track
+- feature should be displayed when its rendering and filtering settings are adjusted
- Updated JFreeSVG (https://www.jfree.org/jfreesvg) from 2.1 to 3.4.3
- Name of alignment and view included in overview window's title
- "add reference annotation" add all positions in reference annotation tracks, not just positions in the currently highlighted columns/selection range
@@ -55,18 +61,25 @@ channel: "release"
- In Linux desktops' task-managers, the grouped Jalview windows get a generic name
- Improved file chooser's 'recent files' view and added filter for 'All known alignment files'
- Relative files added to recent files list via import from command line are selected when Jalview opened from same location
-- Allow log level configuration via Jalview's Java Console, and a Copy to Clipboard button
+- Reduce number of database crossreferences shown in tooltip
+- Drag and drop feature colours file on an alignment to quickly apply feature settings
+- Improved startup info in console output: which properties file was being used and slight revisions to the formatting of platform information.
+- Upgrade bundled groovy to v4.0.15 and regularised interface for groovy scripts run from CLI, interactively and headlessly.
+- Overview display and hidden region visibility stored in Jalview projects
+- Updated faq and documentation urls in splashscreen and help documentation
### Development and Deployment
- Installers built with install4j10
- Create separate gradle test task for some tests
- Prevent gradle test on macOS continuously grabbing focus
- Allow gradle build to create suffixed DEVELOP-... builds with channel appbase
+- Update .jvl generation in build.gradle for jalview branch builds
- Jalview bio.tools description maintained under jalview's git repo and bundled with source release
+- Output stderr and stdout when running tests via gradle
+- New gradle task providing runtime acceptance test for JalviewJS based on Chromium for Tests (still work in progress)
## Issues Resolved
- Jmol view not always centred on structures when multiple structures are viewed
-- Cancelling interactive calculation leaves empty progress bar.
- Unsaved Alignment windows close without prompting to save, individually or at application quit.
- Can quit Jalview while 'save project' is in progress
- 'Use original colours' option of colour by annotation not honoured when restoring view from project
@@ -78,26 +91,40 @@ channel: "release"
- Don't add string label version of DSSP secondary structure codes in secondary structure annotation rows
- reference annotation not correctly transferred to alignment containing a sub-sequence when a selection is active
- Can press 'Add' or 'New View' multiple times when manually adding and viewing a 3D structure via structure chooser
+- 3D beacons sources providing models scored with PLDDT and pTM not sorted against alphaFoldDB models
- Jalview project does not preserve font aspect ratio when Viewport is zoomed with mouse
+- Lower line of the sequence group border does not align with vertical and background residue box
- Resizing overview quickly with solid-drags enabled causes exception
- Sequences copied to clipboard from within Jalview cannot be pasted via the desktop's popup menu to a new alignment window
- Overview window is saved in project file, and state of 'show hidden regions' is preserved.
- JvCacheableInputBoxTest flaky on build server
- SLF4J produces an error to STDERR at Jalview startup due to missing class
-- macOS Dock and KDE taskbar names Jalview icon "java" when running
+- macOS Dock and KDE taskbar names Jalview icon "java" when running jalview via the getdown app launcher
- HeadlessException in console in headless mode (actually fixed in 2.11.{0,1,2))
+- Groovy console does not open when Jalview launched from jalview's Java 11 executable jar (available via conda) for recent versions of groovy
+- Don't offer View model page for sources that do not have model pages
+- Java Console opening at startup with the exampleFile_v2_7.jvp opening (nearly always) causes Jalview to hang
+- automatic positioning of ID width for imported project can fail for certain font size configured in User preferences (affects most versions of Jalview prior to 2.11.3.0)
+- RNAML import missing terminal residue
+- RNA secondary structure annotation final-ending-solo-brace arrow points the wrong way
+- Jalview source distribution unnecessarily includes dist directory with built jalview jar and dependencies
+- Jmol sessions involving large molecules may not be fully saved in Jalview project files (known defect in 2.11.2.x)
## New Known defects
- EBI-AlphaFold PLDDT colours cannot be overlaid on alignment via 'Colour by annotation' unless the alignment's colourscheme has been set to 'None' via the Colours menu.
- Tree renderer doesn't show bottom-most leaves of tree when Fit-To-Window is enabled.
- Cannot cancel structure view open action once it has been started via the structure chooser dialog
- Example project's multiple views do not open in distinct locations when eXpand views is used to show them all separately
-- 'Reload' for a jalview project results in all windows being duplicated
+- 'Reload' for a jalview project results in all windows being duplicated (since 2.11.2.6, more severe in 2.11.3.0
+- Overview shown and then closed when importing legacy jalview projects without overview store/restore information
- Missing last letter when copying consensus sequence from alignment if first column is hidden
- Last sequence ID in alignment not shown and annotation labels are misaligned in HTML export
- Files opened via command line with a relative path are added as relative paths to Recent files list (since 2.0.x)
- Test coverage for ID width adjustment disabled pending fix for new annotation label geometry and width calculation
-
-
-
+- scripts adding new fileformats or colourschemes do not work when run via command line
+- Headless alignment export with structure annotations doesn't include secondary structure and temperature factor
+- Copy sequences from one alignment and Pasting as new window in another alignment doesn't propagate title from original alignment's window)
+- Annotation colouring dialog box doesn't remember 'use original colours' settings when opened via the Colour menu
+- When the Groovy console is open Jalview does not prompt to save before quitting
+- Jalview works with but is not fully compatible with latest Ensembl REST API (15.6)
diff --git a/j11lib/getdown-core.jar b/j11lib/getdown-core.jar
index fb8f1bc..3fc97b5 100644
Binary files a/j11lib/getdown-core.jar and b/j11lib/getdown-core.jar differ
diff --git a/j11lib/groovy-4.0.15.jar b/j11lib/groovy-4.0.15.jar
new file mode 100644
index 0000000..8423d99
Binary files /dev/null and b/j11lib/groovy-4.0.15.jar differ
diff --git a/j11lib/groovy-all-2.4.21-indy.jar b/j11lib/groovy-all-2.4.21-indy.jar
deleted file mode 100644
index 15ee98d..0000000
Binary files a/j11lib/groovy-all-2.4.21-indy.jar and /dev/null differ
diff --git a/j11lib/groovy-ant-4.0.15.jar b/j11lib/groovy-ant-4.0.15.jar
new file mode 100644
index 0000000..b6a39ac
Binary files /dev/null and b/j11lib/groovy-ant-4.0.15.jar differ
diff --git a/j11lib/groovy-astbuilder-4.0.15.jar b/j11lib/groovy-astbuilder-4.0.15.jar
new file mode 100644
index 0000000..f341fac
Binary files /dev/null and b/j11lib/groovy-astbuilder-4.0.15.jar differ
diff --git a/j11lib/groovy-cli-commons-4.0.15.jar b/j11lib/groovy-cli-commons-4.0.15.jar
new file mode 100644
index 0000000..b482258
Binary files /dev/null and b/j11lib/groovy-cli-commons-4.0.15.jar differ
diff --git a/j11lib/groovy-cli-picocli-4.0.15.jar b/j11lib/groovy-cli-picocli-4.0.15.jar
new file mode 100644
index 0000000..3223ba9
Binary files /dev/null and b/j11lib/groovy-cli-picocli-4.0.15.jar differ
diff --git a/j11lib/groovy-console-4.0.15.jar b/j11lib/groovy-console-4.0.15.jar
new file mode 100644
index 0000000..04a402a
Binary files /dev/null and b/j11lib/groovy-console-4.0.15.jar differ
diff --git a/j11lib/groovy-contracts-4.0.15.jar b/j11lib/groovy-contracts-4.0.15.jar
new file mode 100644
index 0000000..6825657
Binary files /dev/null and b/j11lib/groovy-contracts-4.0.15.jar differ
diff --git a/j11lib/groovy-datetime-4.0.15.jar b/j11lib/groovy-datetime-4.0.15.jar
new file mode 100644
index 0000000..312575a
Binary files /dev/null and b/j11lib/groovy-datetime-4.0.15.jar differ
diff --git a/j11lib/groovy-dateutil-4.0.15.jar b/j11lib/groovy-dateutil-4.0.15.jar
new file mode 100644
index 0000000..5893f97
Binary files /dev/null and b/j11lib/groovy-dateutil-4.0.15.jar differ
diff --git a/j11lib/groovy-docgenerator-4.0.15.jar b/j11lib/groovy-docgenerator-4.0.15.jar
new file mode 100644
index 0000000..bf76564
Binary files /dev/null and b/j11lib/groovy-docgenerator-4.0.15.jar differ
diff --git a/j11lib/groovy-ginq-4.0.15.jar b/j11lib/groovy-ginq-4.0.15.jar
new file mode 100644
index 0000000..46f561e
Binary files /dev/null and b/j11lib/groovy-ginq-4.0.15.jar differ
diff --git a/j11lib/groovy-groovydoc-4.0.15.jar b/j11lib/groovy-groovydoc-4.0.15.jar
new file mode 100644
index 0000000..b818919
Binary files /dev/null and b/j11lib/groovy-groovydoc-4.0.15.jar differ
diff --git a/j11lib/groovy-groovysh-4.0.15.jar b/j11lib/groovy-groovysh-4.0.15.jar
new file mode 100644
index 0000000..253eff6
Binary files /dev/null and b/j11lib/groovy-groovysh-4.0.15.jar differ
diff --git a/j11lib/groovy-jmx-4.0.15.jar b/j11lib/groovy-jmx-4.0.15.jar
new file mode 100644
index 0000000..8667ac4
Binary files /dev/null and b/j11lib/groovy-jmx-4.0.15.jar differ
diff --git a/j11lib/groovy-json-4.0.15.jar b/j11lib/groovy-json-4.0.15.jar
new file mode 100644
index 0000000..76b486a
Binary files /dev/null and b/j11lib/groovy-json-4.0.15.jar differ
diff --git a/j11lib/groovy-jsr223-4.0.15.jar b/j11lib/groovy-jsr223-4.0.15.jar
new file mode 100644
index 0000000..5ae9f69
Binary files /dev/null and b/j11lib/groovy-jsr223-4.0.15.jar differ
diff --git a/j11lib/groovy-macro-4.0.15.jar b/j11lib/groovy-macro-4.0.15.jar
new file mode 100644
index 0000000..e5f7abb
Binary files /dev/null and b/j11lib/groovy-macro-4.0.15.jar differ
diff --git a/j11lib/groovy-macro-library-4.0.15.jar b/j11lib/groovy-macro-library-4.0.15.jar
new file mode 100644
index 0000000..92c208f
Binary files /dev/null and b/j11lib/groovy-macro-library-4.0.15.jar differ
diff --git a/j11lib/groovy-nio-4.0.15.jar b/j11lib/groovy-nio-4.0.15.jar
new file mode 100644
index 0000000..e6e2ad8
Binary files /dev/null and b/j11lib/groovy-nio-4.0.15.jar differ
diff --git a/j11lib/groovy-servlet-4.0.15.jar b/j11lib/groovy-servlet-4.0.15.jar
new file mode 100644
index 0000000..711a1e2
Binary files /dev/null and b/j11lib/groovy-servlet-4.0.15.jar differ
diff --git a/j11lib/groovy-sql-4.0.15.jar b/j11lib/groovy-sql-4.0.15.jar
new file mode 100644
index 0000000..058db44
Binary files /dev/null and b/j11lib/groovy-sql-4.0.15.jar differ
diff --git a/j11lib/groovy-swing-4.0.15.jar b/j11lib/groovy-swing-4.0.15.jar
new file mode 100644
index 0000000..848d074
Binary files /dev/null and b/j11lib/groovy-swing-4.0.15.jar differ
diff --git a/j11lib/groovy-templates-4.0.15.jar b/j11lib/groovy-templates-4.0.15.jar
new file mode 100644
index 0000000..3cd0245
Binary files /dev/null and b/j11lib/groovy-templates-4.0.15.jar differ
diff --git a/j11lib/groovy-test-4.0.15.jar b/j11lib/groovy-test-4.0.15.jar
new file mode 100644
index 0000000..e600dc7
Binary files /dev/null and b/j11lib/groovy-test-4.0.15.jar differ
diff --git a/j11lib/groovy-test-junit5-4.0.15.jar b/j11lib/groovy-test-junit5-4.0.15.jar
new file mode 100644
index 0000000..abcc69a
Binary files /dev/null and b/j11lib/groovy-test-junit5-4.0.15.jar differ
diff --git a/j11lib/groovy-testng-4.0.15.jar b/j11lib/groovy-testng-4.0.15.jar
new file mode 100644
index 0000000..60c1b58
Binary files /dev/null and b/j11lib/groovy-testng-4.0.15.jar differ
diff --git a/j11lib/groovy-toml-4.0.15.jar b/j11lib/groovy-toml-4.0.15.jar
new file mode 100644
index 0000000..ad49634
Binary files /dev/null and b/j11lib/groovy-toml-4.0.15.jar differ
diff --git a/j11lib/groovy-typecheckers-4.0.15.jar b/j11lib/groovy-typecheckers-4.0.15.jar
new file mode 100644
index 0000000..dc113c3
Binary files /dev/null and b/j11lib/groovy-typecheckers-4.0.15.jar differ
diff --git a/j11lib/groovy-xml-4.0.15.jar b/j11lib/groovy-xml-4.0.15.jar
new file mode 100644
index 0000000..21aeea0
Binary files /dev/null and b/j11lib/groovy-xml-4.0.15.jar differ
diff --git a/j11lib/groovy-yaml-4.0.15.jar b/j11lib/groovy-yaml-4.0.15.jar
new file mode 100644
index 0000000..207d47d
Binary files /dev/null and b/j11lib/groovy-yaml-4.0.15.jar differ
diff --git a/j11lib/javaparser-core-3.25.5.jar b/j11lib/javaparser-core-3.25.5.jar
new file mode 100644
index 0000000..92eed53
Binary files /dev/null and b/j11lib/javaparser-core-3.25.5.jar differ
diff --git a/j8lib/getdown-core.jar b/j8lib/getdown-core.jar
index fb8f1bc..3fc97b5 100644
Binary files a/j8lib/getdown-core.jar and b/j8lib/getdown-core.jar differ
diff --git a/j8lib/groovy-4.0.15.jar b/j8lib/groovy-4.0.15.jar
new file mode 100644
index 0000000..8423d99
Binary files /dev/null and b/j8lib/groovy-4.0.15.jar differ
diff --git a/j8lib/groovy-all-2.4.21-indy.jar b/j8lib/groovy-all-2.4.21-indy.jar
deleted file mode 100644
index 15ee98d..0000000
Binary files a/j8lib/groovy-all-2.4.21-indy.jar and /dev/null differ
diff --git a/j8lib/groovy-ant-4.0.15.jar b/j8lib/groovy-ant-4.0.15.jar
new file mode 100644
index 0000000..b6a39ac
Binary files /dev/null and b/j8lib/groovy-ant-4.0.15.jar differ
diff --git a/j8lib/groovy-astbuilder-4.0.15.jar b/j8lib/groovy-astbuilder-4.0.15.jar
new file mode 100644
index 0000000..f341fac
Binary files /dev/null and b/j8lib/groovy-astbuilder-4.0.15.jar differ
diff --git a/j8lib/groovy-cli-commons-4.0.15.jar b/j8lib/groovy-cli-commons-4.0.15.jar
new file mode 100644
index 0000000..b482258
Binary files /dev/null and b/j8lib/groovy-cli-commons-4.0.15.jar differ
diff --git a/j8lib/groovy-cli-picocli-4.0.15.jar b/j8lib/groovy-cli-picocli-4.0.15.jar
new file mode 100644
index 0000000..3223ba9
Binary files /dev/null and b/j8lib/groovy-cli-picocli-4.0.15.jar differ
diff --git a/j8lib/groovy-console-4.0.15.jar b/j8lib/groovy-console-4.0.15.jar
new file mode 100644
index 0000000..04a402a
Binary files /dev/null and b/j8lib/groovy-console-4.0.15.jar differ
diff --git a/j8lib/groovy-contracts-4.0.15.jar b/j8lib/groovy-contracts-4.0.15.jar
new file mode 100644
index 0000000..6825657
Binary files /dev/null and b/j8lib/groovy-contracts-4.0.15.jar differ
diff --git a/j8lib/groovy-datetime-4.0.15.jar b/j8lib/groovy-datetime-4.0.15.jar
new file mode 100644
index 0000000..312575a
Binary files /dev/null and b/j8lib/groovy-datetime-4.0.15.jar differ
diff --git a/j8lib/groovy-dateutil-4.0.15.jar b/j8lib/groovy-dateutil-4.0.15.jar
new file mode 100644
index 0000000..5893f97
Binary files /dev/null and b/j8lib/groovy-dateutil-4.0.15.jar differ
diff --git a/j8lib/groovy-docgenerator-4.0.15.jar b/j8lib/groovy-docgenerator-4.0.15.jar
new file mode 100644
index 0000000..bf76564
Binary files /dev/null and b/j8lib/groovy-docgenerator-4.0.15.jar differ
diff --git a/j8lib/groovy-ginq-4.0.15.jar b/j8lib/groovy-ginq-4.0.15.jar
new file mode 100644
index 0000000..46f561e
Binary files /dev/null and b/j8lib/groovy-ginq-4.0.15.jar differ
diff --git a/j8lib/groovy-groovydoc-4.0.15.jar b/j8lib/groovy-groovydoc-4.0.15.jar
new file mode 100644
index 0000000..b818919
Binary files /dev/null and b/j8lib/groovy-groovydoc-4.0.15.jar differ
diff --git a/j8lib/groovy-groovysh-4.0.15.jar b/j8lib/groovy-groovysh-4.0.15.jar
new file mode 100644
index 0000000..253eff6
Binary files /dev/null and b/j8lib/groovy-groovysh-4.0.15.jar differ
diff --git a/j8lib/groovy-jmx-4.0.15.jar b/j8lib/groovy-jmx-4.0.15.jar
new file mode 100644
index 0000000..8667ac4
Binary files /dev/null and b/j8lib/groovy-jmx-4.0.15.jar differ
diff --git a/j8lib/groovy-json-4.0.15.jar b/j8lib/groovy-json-4.0.15.jar
new file mode 100644
index 0000000..76b486a
Binary files /dev/null and b/j8lib/groovy-json-4.0.15.jar differ
diff --git a/j8lib/groovy-jsr223-4.0.15.jar b/j8lib/groovy-jsr223-4.0.15.jar
new file mode 100644
index 0000000..5ae9f69
Binary files /dev/null and b/j8lib/groovy-jsr223-4.0.15.jar differ
diff --git a/j8lib/groovy-macro-4.0.15.jar b/j8lib/groovy-macro-4.0.15.jar
new file mode 100644
index 0000000..e5f7abb
Binary files /dev/null and b/j8lib/groovy-macro-4.0.15.jar differ
diff --git a/j8lib/groovy-macro-library-4.0.15.jar b/j8lib/groovy-macro-library-4.0.15.jar
new file mode 100644
index 0000000..92c208f
Binary files /dev/null and b/j8lib/groovy-macro-library-4.0.15.jar differ
diff --git a/j8lib/groovy-nio-4.0.15.jar b/j8lib/groovy-nio-4.0.15.jar
new file mode 100644
index 0000000..e6e2ad8
Binary files /dev/null and b/j8lib/groovy-nio-4.0.15.jar differ
diff --git a/j8lib/groovy-servlet-4.0.15.jar b/j8lib/groovy-servlet-4.0.15.jar
new file mode 100644
index 0000000..711a1e2
Binary files /dev/null and b/j8lib/groovy-servlet-4.0.15.jar differ
diff --git a/j8lib/groovy-sql-4.0.15.jar b/j8lib/groovy-sql-4.0.15.jar
new file mode 100644
index 0000000..058db44
Binary files /dev/null and b/j8lib/groovy-sql-4.0.15.jar differ
diff --git a/j8lib/groovy-swing-4.0.15.jar b/j8lib/groovy-swing-4.0.15.jar
new file mode 100644
index 0000000..848d074
Binary files /dev/null and b/j8lib/groovy-swing-4.0.15.jar differ
diff --git a/j8lib/groovy-templates-4.0.15.jar b/j8lib/groovy-templates-4.0.15.jar
new file mode 100644
index 0000000..3cd0245
Binary files /dev/null and b/j8lib/groovy-templates-4.0.15.jar differ
diff --git a/j8lib/groovy-test-4.0.15.jar b/j8lib/groovy-test-4.0.15.jar
new file mode 100644
index 0000000..e600dc7
Binary files /dev/null and b/j8lib/groovy-test-4.0.15.jar differ
diff --git a/j8lib/groovy-test-junit5-4.0.15.jar b/j8lib/groovy-test-junit5-4.0.15.jar
new file mode 100644
index 0000000..abcc69a
Binary files /dev/null and b/j8lib/groovy-test-junit5-4.0.15.jar differ
diff --git a/j8lib/groovy-testng-4.0.15.jar b/j8lib/groovy-testng-4.0.15.jar
new file mode 100644
index 0000000..60c1b58
Binary files /dev/null and b/j8lib/groovy-testng-4.0.15.jar differ
diff --git a/j8lib/groovy-toml-4.0.15.jar b/j8lib/groovy-toml-4.0.15.jar
new file mode 100644
index 0000000..ad49634
Binary files /dev/null and b/j8lib/groovy-toml-4.0.15.jar differ
diff --git a/j8lib/groovy-typecheckers-4.0.15.jar b/j8lib/groovy-typecheckers-4.0.15.jar
new file mode 100644
index 0000000..dc113c3
Binary files /dev/null and b/j8lib/groovy-typecheckers-4.0.15.jar differ
diff --git a/j8lib/groovy-xml-4.0.15.jar b/j8lib/groovy-xml-4.0.15.jar
new file mode 100644
index 0000000..21aeea0
Binary files /dev/null and b/j8lib/groovy-xml-4.0.15.jar differ
diff --git a/j8lib/groovy-yaml-4.0.15.jar b/j8lib/groovy-yaml-4.0.15.jar
new file mode 100644
index 0000000..207d47d
Binary files /dev/null and b/j8lib/groovy-yaml-4.0.15.jar differ
diff --git a/j8lib/javaparser-core-3.25.5.jar b/j8lib/javaparser-core-3.25.5.jar
new file mode 100644
index 0000000..92eed53
Binary files /dev/null and b/j8lib/javaparser-core-3.25.5.jar differ
diff --git a/resources/lang/Messages.properties b/resources/lang/Messages.properties
index 70eeb95..c3c8589 100644
--- a/resources/lang/Messages.properties
+++ b/resources/lang/Messages.properties
@@ -1246,8 +1246,8 @@ label.mapping_method = Sequence \u27f7 Structure mapping method
status.cancelled_image_export_operation = Cancelled {0} export operation
info.error_creating_file = Error creating {0} file
exception.outofmemory_loading_mmcif_file = Out of memory loading mmCIF File
-label.run_groovy = Run Groovy console script
-label.run_groovy_tip = Run the script in the Groovy console over this alignment
+label.run_groovy = Run Groovy Console Script
+label.run_groovy_tip = Run the script in the Groovy Console over this alignment
label.couldnt_run_groovy_script = Failed to run Groovy script
label.uniprot_sequence_fetcher = UniProt Sequence Fetcher
action.next_page= >>
@@ -1468,3 +1468,4 @@ label.command_line_arguments = Command Line Arguments
warning.using_old_command_line_arguments = It looks like you are using old command line arguments. These are now deprecated and will be removed in a future release of Jalview.\nFind out about the new command line arguments at\n
warning.using_mixed_command_line_arguments = Jalview cannot use both old (-arg) and new (--arg) command line arguments. Please check your command line arguments.\ne.g. {0} and {1}
warning.the_following_errors = The following errors and warnings occurred whilst processing files:
+action.show_hetatm = Show Ligands (HETATM)
diff --git a/schemas/jalview.xsd b/schemas/jalview.xsd
index adaa3ee..c5d35fb 100755
--- a/schemas/jalview.xsd
+++ b/schemas/jalview.xsd
@@ -501,6 +501,8 @@
+
+
diff --git a/schemas/vamsas.xsd b/schemas/vamsas.xsd
index fedbae3..364bfbe 100755
--- a/schemas/vamsas.xsd
+++ b/schemas/vamsas.xsd
@@ -23,58 +23,83 @@
xjc schemas/jalview.xsd -d src -p jalview.xml.binding.jalview
Note this also generates code for included schemas
-->
-
+
-
-
+
+
-
- developed after mapRangeType from http://www.vamsas.ac.uk/schemas/1.0/vamsasTypes
+
+ developed after mapRangeType from
+ http://www.vamsas.ac.uk/schemas/1.0/vamsasTypes
- This effectively represents a java.util.MapList object
+ This effectively represents a java.util.MapList
+ object
-
+
- a region from start to end inclusive
+ a region from start to end inclusive
+
-
-
+
+
-
-
+
+
- a region from start to end inclusive
+ a region from start to end inclusive
+
-
-
+
+
-
+
-
+
- number of dictionary symbol widths involved in each
- mapped position on this sequence (for example, 3 for a dna sequence exon
- region that is being mapped to a protein sequence). This is optional,
- since the unit can be usually be inferred from the dictionary type of
- each sequence involved in the mapping.
+ number of dictionary symbol widths involved in
+ each
+ mapped position on this sequence (for example, 3 for a dna
+ sequence exon
+ region that is being mapped to a protein sequence).
+ This is optional,
+ since the unit can be usually be inferred from the
+ dictionary type of
+ each sequence involved in the mapping.
+
-
+
- number of dictionary symbol widths involved in each
- mapped position on this sequence (for example, 3 for a dna sequence exon
- region that is being mapped to a protein sequence). This is optional,
- since the unit can be usually be inferred from the dictionary type of
- each sequence involved in the mapping.
+ number of dictionary symbol widths involved in
+ each
+ mapped position on this sequence (for example, 3 for a dna
+ sequence exon
+ region that is being mapped to a protein sequence).
+ This is optional,
+ since the unit can be usually be inferred from the
+ dictionary type of
+ each sequence involved in the mapping.
+
@@ -82,74 +107,94 @@
- Represent the jalview.datamodel.Mapping object - it also provides
- a way of storing sequences that are mapped 'to' without adding them
- to the sequence set (which will mean they are then added to the alignment too).
+ Represent the jalview.datamodel.Mapping object -
+ it also provides
+ a way of storing sequences that are mapped 'to'
+ without adding them
+ to the sequence set (which will mean they are
+ then added to the alignment too).
-
+
- The sequence whose dataset sequence is to be referenced here
+ The sequence whose dataset sequence is to
+ be referenced here
+
-
+
- Biotype of the mapping e.g. CdsToPeptide
+ Biotype of the mapping e.g. CdsToPeptide
+
-
+
-
+
- specifies a series of aligned codons from an associated DNA sequence alignment that when translated correspond to columns of a peptide alignment.
- Element may have either all pos1,2,3 attributes specified, or none at all (indicating a gapped column with no translated peptide).
+ specifies a series of aligned codons from an
+ associated DNA sequence alignment that when translated
+ correspond to columns of a peptide alignment.
+ Element may have
+ either all pos1,2,3 attributes specified, or none at all
+ (indicating a gapped column with no translated peptide).
-
-
-
+
+
+
-
+
-
+
- a Mapping entry and an associated protein sequence
+ a Mapping entry and an associated protein
+ sequence
-
+
- internal jalview id for the dnasq for this mapping.
+ internal jalview id for the dnasq for this
+ mapping.
-
+
-
+
@@ -158,39 +203,49 @@
-
+
-
-
-
-
-
-
+
+
+
+
+
+
- true for gene locus mapping, source=species, version=assembly, accession=chromosome
+ true for gene locus mapping, source=species,
+ version=assembly, accession=chromosome
-
+
- true for the representative accession for databases where multiple accessions map to the same entry (eg. Uniprot)
+ true for the representative accession for
+ databases where multiple accessions map to the same entry
+ (eg. Uniprot)
-
+
- dataset sequence id for this sequence. Will be created as union of sequences.
+ dataset sequence id for this sequence. Will be
+ created as union of sequences.
-
+
Biotype of the sequence (if known)
@@ -216,13 +271,16 @@
-
+
-
+
-
-
+
+
-
- height in pixels for the graph if this is a graph-type annotation.
+
+
+ height in pixels for the graph if this is a
+ graph-type annotation.
+
+
+
-
+
-
- is an autocalculated annotation row
-
-
- is to be shown below the alignment - introduced in Jalview 2.8 for visualizing T-COFFEE alignment scores
-
- Optional string identifier used to group sets of annotation produced by a particular calculation. Values are opaque strings but have semantic meaning to Jalview's renderer, data importer and calculation system.
+
+
+ is an autocalculated annotation row
+
+
+
+
+
+ is to be shown below the alignment - introduced
+ in Jalview 2.8 for visualizing T-COFFEE alignment scores
+
+
+
+
+
+ Optional string identifier used to group sets of
+ annotation produced by a particular calculation. Values are opaque
+ strings but have semantic meaning to Jalview's renderer, data
+ importer and calculation system.
+
+
-
+
-
-
-
+
+
+
-
-
+
+
-
+
+
+
+ Matrices referred to by this set of sequences.
+
+
+
-
-
+
+
- reference to set where jalview will gather the dataset sequences for all sequences in the set.
+ reference to set where jalview will gather the
+ dataset sequences for all sequences in the set.
@@ -283,36 +379,47 @@
-
-
+
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
+
+ Represents matrix data imported to Jalview, and the
+ results of any derived calculations (independent of a particular
+ view
+ on the matrix).
+
+ serialised representation of matrix as one or
- more sets of comma separated values
+ more sets of comma separated values
+
-
-
- mapping from the matrix row and column positions to
- associated reference frame
-
-
@@ -349,13 +449,43 @@
use="optional" />
-
+
+
+
+ Defines a mapping from the local frame to a matrix
+ and its associated data specified by MatrixType
+
+
+
+
+
+
+ mapping from the matrix row and column positions
+ to
+ associated reference frame
+
+
+
+
+
+
+
+
+ reference to the matrix type this Map refers to
+
+
+
+
+
-
-
+
+
diff --git a/src/jalview/api/structures/JalviewStructureDisplayI.java b/src/jalview/api/structures/JalviewStructureDisplayI.java
index 532e545..77f2b6d 100644
--- a/src/jalview/api/structures/JalviewStructureDisplayI.java
+++ b/src/jalview/api/structures/JalviewStructureDisplayI.java
@@ -21,6 +21,8 @@
package jalview.api.structures;
import java.io.File;
+import java.util.Collections;
+import java.util.List;
import jalview.api.AlignmentViewPanel;
import jalview.datamodel.PDBEntry;
@@ -192,4 +194,12 @@ public interface JalviewStructureDisplayI
File saveSession();
+ /**
+ *
+ * @return heteroatoms in a form suitable for display and passing to command generator to display hetatms
+ */
+ default List getHetatms() {
+ return Collections.EMPTY_LIST;
+ }
+
}
diff --git a/src/jalview/bin/Cache.java b/src/jalview/bin/Cache.java
index 1abb171..483b1fc 100755
--- a/src/jalview/bin/Cache.java
+++ b/src/jalview/bin/Cache.java
@@ -54,6 +54,8 @@ import javax.swing.LookAndFeel;
import javax.swing.UIManager;
import jalview.analytics.Plausible;
+import jalview.bin.argparser.Arg;
+import jalview.bin.argparser.ArgParser;
import jalview.datamodel.PDBEntry;
import jalview.gui.Preferences;
import jalview.gui.UserDefinedColours;
@@ -1663,27 +1665,36 @@ public class Cache
}
if (file == null || !file.exists())
{
+ if (file != null)
+ {
+ jalview.bin.Console
+ .errPrintln("Could not load bootstrap preferences file '"
+ + file.getPath() + "'");
+ }
String channelPrefsFilename = ChannelProperties
.getProperty("preferences.filename");
String propertiesFilename = System.getProperty("user.home")
+ File.separatorChar + channelPrefsFilename;
+ jalview.bin.Console.errPrintln(
+ "Using default properties file '" + propertiesFilename + "'");
file = new File(propertiesFilename);
}
if (file == null || !file.exists())
+
{
String releasePrefsFilename = fallbackPropertiesFile;
String releasePropertiesFilename = System.getProperty("user.home")
+ File.separatorChar + releasePrefsFilename;
+ jalview.bin.Console.errPrintln("Falling back to properties file '"
+ + releasePropertiesFilename + "'");
file = new File(releasePropertiesFilename);
}
- if (filename == null)
- return null;
if (!file.exists())
{
jalview.bin.Console
.errPrintln("Could not load bootstrap preferences file '"
- + filename + "'");
+ + file.getPath() + "'");
return null;
}
@@ -1723,4 +1734,10 @@ public class Cache
{
return key == null ? null : sessionProperties.get(key);
}
+
+ public static boolean getArgCacheDefault(Arg a, String pref, boolean def)
+ {
+ ArgParser ap = Jalview.getInstance().getArgParser();
+ return ap.isSet(a) ? ap.getBoolean(a) : getDefault(pref, def);
+ }
}
diff --git a/src/jalview/bin/Commands.java b/src/jalview/bin/Commands.java
index 5d3b50d..2794b02 100644
--- a/src/jalview/bin/Commands.java
+++ b/src/jalview/bin/Commands.java
@@ -13,6 +13,8 @@ import java.util.List;
import java.util.Locale;
import java.util.Map;
+import javax.swing.SwingUtilities;
+
import jalview.analysis.AlignmentUtils;
import jalview.api.structures.JalviewStructureDisplayI;
import jalview.bin.Jalview.ExitCode;
@@ -194,7 +196,7 @@ public class Commands
if (avm.containsArg(Arg.APPEND) || avm.containsArg(Arg.OPEN))
{
commandArgsProvided = true;
- long progress = -1;
+ final long progress = System.currentTimeMillis();
boolean first = true;
boolean progressBarSet = false;
@@ -220,10 +222,18 @@ public class Commands
first = false;
if (!headless && desktop != null)
{
- desktop.setProgressBar(
- MessageManager.getString(
- "status.processing_commandline_args"),
- progress = System.currentTimeMillis());
+ SwingUtilities.invokeLater(new Runnable()
+ {
+ @Override
+ public void run()
+ {
+ desktop.setProgressBar(
+ MessageManager.getString(
+ "status.processing_commandline_args"),
+ progress);
+
+ }
+ });
progressBarSet = true;
}
}
@@ -365,24 +375,49 @@ public class Commands
boolean showSSAnnotations = avm.getFromSubValArgOrPref(
Arg.SHOWSSANNOTATIONS, av.getSubVals(), null,
"STRUCT_FROM_PDB", true);
- af.setAnnotationsVisibility(showSSAnnotations, true, false);
// Show sequence annotations?
boolean showAnnotations = avm.getFromSubValArgOrPref(
Arg.SHOWANNOTATIONS, av.getSubVals(), null,
"SHOW_ANNOTATIONS", true);
- af.setAnnotationsVisibility(showAnnotations, false, true);
- // show temperature factor annotations?
- if (avm.getBoolean(Arg.NOTEMPFAC))
+ boolean hideTFrows = (avm.getBoolean(Arg.NOTEMPFAC));
+ final AlignFrame _af = af;
+ // many of jalview's format/layout methods are only thread safe on the
+ // swingworker thread.
+ // all these methods should be on the alignViewController so it can
+ // coordinate such details
+ try
{
- // do this better (annotation types?)
- List hideThese = new ArrayList<>();
- hideThese.add("Temperature Factor");
- hideThese.add(AlphaFoldAnnotationRowBuilder.LABEL);
- AlignmentUtils.showOrHideSequenceAnnotations(
- af.getCurrentView().getAlignment(), hideThese, null,
- false, false);
+ SwingUtilities.invokeAndWait(new Runnable()
+ {
+
+ @Override
+ public void run()
+ {
+ _af.setAnnotationsVisibility(showSSAnnotations, true,
+ false);
+
+ _af.setAnnotationsVisibility(showAnnotations, false, true);
+
+ // show temperature factor annotations?
+ if (hideTFrows)
+ {
+ // do this better (annotation types?)
+ List hideThese = new ArrayList<>();
+ hideThese.add("Temperature Factor");
+ hideThese.add(AlphaFoldAnnotationRowBuilder.LABEL);
+ AlignmentUtils.showOrHideSequenceAnnotations(
+ _af.getCurrentView().getAlignment(), hideThese,
+ null, false, false);
+ }
+ }
+ });
+ } catch (Exception x)
+ {
+ Console.warn(
+ "Unexpected exception adjusting annotation row visibility.",
+ x);
}
// wrap alignment? do this last for formatting reasons
@@ -408,9 +443,11 @@ public class Commands
{
Console.debug(
"Opening '" + openFile + "' in existing alignment frame");
+
DataSourceType dst = HttpUtils.startsWithHttpOrHttps(openFile)
? DataSourceType.URL
: DataSourceType.FILE;
+
FileLoader fileLoader = new FileLoader(!headless);
fileLoader.LoadFile(af.getCurrentView(), openFile, dst, null,
false);
@@ -439,11 +476,14 @@ public class Commands
// open the structure (from same PDB file or given PDBfile)
if (!avm.getBoolean(Arg.NOSTRUCTURE))
{
+
AlignFrame af = afMap.get(id);
if (avm.containsArg(Arg.STRUCTURE))
{
commandArgsProvided = true;
- for (ArgValue av : avm.getArgValueList(Arg.STRUCTURE))
+ for (
+
+ ArgValue av : avm.getArgValueList(Arg.STRUCTURE))
{
argParser.setStructureFilename(null);
String val = av.getValue();
@@ -775,10 +815,11 @@ public class Commands
// RESTORE SESSION AFTER EXPORT IF NEED BE
if (sessionToRestore != null)
{
- Console.debug("Restoring session from "
- + sessionToRestore);
-
- sview.getBinding().restoreSession(sessionToRestore.getAbsolutePath());
+ Console.debug(
+ "Restoring session from " + sessionToRestore);
+
+ sview.getBinding().restoreSession(
+ sessionToRestore.getAbsolutePath());
}
} catch (ImageOutputException ioexec)
@@ -789,11 +830,14 @@ public class Commands
continue;
} finally
{
- try {
+ try
+ {
this.colourAlignFrame(af, originalColourScheme);
} catch (Exception t)
{
- addError("Unexpected error when restoring colourscheme to alignment after temporary change for export.",t);
+ addError(
+ "Unexpected error when restoring colourscheme to alignment after temporary change for export.",
+ t);
}
}
}
@@ -806,6 +850,7 @@ public class Commands
if (wrap)
{
+
AlignFrame af = afMap.get(id);
if (af != null)
{
@@ -817,16 +862,16 @@ public class Commands
boolean doShading = avm.getBoolean(Arg.TEMPFAC_SHADING);
if (doShading)
{
- AlignFrame af = afMap.get(id);
- for (AlignmentAnnotation aa : af.alignPanel.getAlignment()
- .findAnnotation(PDBChain.class.getName().toString()))
- {
- AnnotationColourGradient acg = new AnnotationColourGradient(aa,
- af.alignPanel.av.getGlobalColourScheme(), 0);
- acg.setSeqAssociated(true);
- af.changeColour(acg);
- Console.info("Changed colour " + acg.toString());
- }
+ AlignFrame af = afMap.get(id);
+ for (AlignmentAnnotation aa : af.alignPanel.getAlignment()
+ .findAnnotation(PDBChain.class.getName().toString()))
+ {
+ AnnotationColourGradient acg = new AnnotationColourGradient(aa,
+ af.alignPanel.av.getGlobalColourScheme(), 0);
+ acg.setSeqAssociated(true);
+ af.changeColour(acg);
+ Console.info("Changed colour " + acg.toString());
+ }
}
*/
@@ -838,21 +883,29 @@ public class Commands
ArgValuesMap avm = argParser.getLinkedArgs(id);
AlignFrame af = afMap.get(id);
- if (af == null)
+ if (avm != null && !avm.containsArg(Arg.GROOVY))
{
- addWarn("Did not have an alignment window for id=" + id);
+ // nothing to do
return;
}
+ if (af == null)
+ {
+ addWarn("Groovy script does not have an alignment window. Proceeding with caution!");
+ }
+
if (avm.containsArg(Arg.GROOVY))
{
- String groovyscript = avm.getValue(Arg.GROOVY);
- if (groovyscript != null)
+ for (ArgValue groovyAv : avm.getArgValueList(Arg.GROOVY))
{
- // Execute the groovy script after we've done all the rendering stuff
- // and before any images or figures are generated.
- Console.info("Executing script " + groovyscript);
- Jalview.getInstance().executeGroovyScript(groovyscript, af);
+ String groovyscript = groovyAv.getValue();
+ if (groovyscript != null)
+ {
+ // Execute the groovy script after we've done all the rendering stuff
+ // and before any images or figures are generated.
+ Console.info("Executing script " + groovyscript);
+ Jalview.getInstance().executeGroovyScript(groovyscript, af);
+ }
}
}
}
@@ -862,9 +915,16 @@ public class Commands
ArgValuesMap avm = argParser.getLinkedArgs(id);
AlignFrame af = afMap.get(id);
+ if (avm != null && !avm.containsArg(Arg.IMAGE))
+ {
+ // nothing to do
+ return true;
+ }
+
if (af == null)
{
- addWarn("Did not have an alignment window for id=" + id);
+ addWarn("Do not have an alignment window to create image from (id="
+ + id + "). Not proceeding.");
return false;
}
@@ -991,9 +1051,16 @@ public class Commands
ArgValuesMap avm = argParser.getLinkedArgs(id);
AlignFrame af = afMap.get(id);
+ if (avm != null && !avm.containsArg(Arg.OUTPUT))
+ {
+ // nothing to do
+ return true;
+ }
+
if (af == null)
{
- addWarn("Did not have an alignment window for id=" + id);
+ addWarn("Do not have an alignment window (id=" + id
+ + "). Not proceeding.");
return false;
}
diff --git a/src/jalview/bin/Console.java b/src/jalview/bin/Console.java
index 1b230ec..1bb8162 100644
--- a/src/jalview/bin/Console.java
+++ b/src/jalview/bin/Console.java
@@ -21,10 +21,8 @@
package jalview.bin;
import java.io.PrintStream;
-import java.util.Locale;
import jalview.log.JLogger;
-import jalview.log.JLoggerI;
import jalview.log.JLoggerI.LogLevel;
import jalview.log.JLoggerLog4j;
import jalview.util.ChannelProperties;
@@ -241,7 +239,7 @@ public class Console
{
JLogger.LogLevel logLevel = JLogger.LogLevel.INFO;
- if (JLogger.isLevel(providedLogLevel))
+ if (providedLogLevel != null && JLogger.isLevel(providedLogLevel))
{
logLevel = Console.getLogLevel(providedLogLevel);
}
@@ -292,19 +290,23 @@ public class Console
public static void setLogLevel(String logLevelString)
{
- for (LogLevel logLevel : JLoggerI.LogLevel.values())
+ LogLevel l = null;
+ try
+ {
+ l = LogLevel.valueOf(logLevelString);
+ } catch (IllegalArgumentException | NullPointerException e1)
+ {
+ Console.debug("Invalid log level '" + logLevelString + "'");
+ return;
+ }
+ if (l != null)
{
- if (logLevel.toString().toLowerCase(Locale.ROOT)
- .equals(logLevelString.toLowerCase(Locale.ROOT)))
+ log.setLevel(l);
+ if (!Platform.isJS())
{
- log.setLevel(logLevel);
- if (!Platform.isJS())
- {
- Log4j.init(logLevel);
- }
- JLoggerLog4j.getLogger("org.apache.axis", logLevel);
- break;
+ Log4j.init(l);
}
+ JLoggerLog4j.getLogger("org.apache.axis", l);
}
}
diff --git a/src/jalview/bin/Jalview.java b/src/jalview/bin/Jalview.java
index b7d15e5..e343b0f 100755
--- a/src/jalview/bin/Jalview.java
+++ b/src/jalview/bin/Jalview.java
@@ -73,6 +73,8 @@ import jalview.bin.argparser.Arg.Opt;
import jalview.bin.argparser.Arg.Type;
import jalview.bin.argparser.ArgParser;
import jalview.bin.argparser.BootstrapArgs;
+import jalview.bin.groovy.JalviewObject;
+import jalview.bin.groovy.JalviewObjectI;
import jalview.ext.so.SequenceOntology;
import jalview.gui.AlignFrame;
import jalview.gui.Desktop;
@@ -118,7 +120,7 @@ import jalview.ws.jws2.Jws2Discoverer;
* @author $author$
* @version $Revision$
*/
-public class Jalview
+public class Jalview implements JalviewObjectI
{
static
{
@@ -138,7 +140,7 @@ public class Jalview
protected Commands cmds;
- public static AlignFrame currentAlignFrame;
+ public AlignFrame currentAlignFrame = null;
private ArgParser argparser = null;
@@ -447,7 +449,7 @@ public class Jalview
}
else if (bootstrapArgs.contains(Arg.DEBUG))
{
- logLevel = "DEBUG";
+ logLevel = bootstrapArgs.getBoolean(Arg.DEBUG) ? "DEBUG" : "INFO";
}
if (logLevel == null && !(bootstrapProperties == null))
{
@@ -642,14 +644,12 @@ public class Jalview
try
{
Console.initLogger();
- } catch (
-
- NoClassDefFoundError error)
+ } catch (NoClassDefFoundError error)
{
error.printStackTrace();
String message = "\nEssential logging libraries not found."
+ "\nUse: java -classpath \"$PATH_TO_LIB$/*:$PATH_TO_CLASSES$\" jalview.bin.Jalview";
- Jalview.exit(message, ExitCode.OK);
+ Jalview.exit(message, ExitCode.NO_LOGGING);
}
desktop = null;
@@ -1633,8 +1633,7 @@ public class Jalview
PromptUserConfig prompter = new PromptUserConfig(Desktop.desktop,
"USAGESTATS",
MessageManager.getString("prompt.analytics_title"),
- MessageManager.getString("prompt.analytics"),
- new Runnable()
+ MessageManager.getString("prompt.analytics"), new Runnable()
{
@Override
public void run()
@@ -1752,12 +1751,11 @@ public class Jalview
}
try
{
+ JalviewObjectI j = new JalviewObject(this);
Map vbinding = new HashMap<>();
- vbinding.put("Jalview", this);
- if (af != null)
- {
- vbinding.put("currentAlFrame", af);
- }
+ vbinding.put(JalviewObjectI.jalviewObjectName, j);
+ vbinding.put(JalviewObjectI.currentAlFrameName,
+ af != null ? af : getCurrentAlignFrame());
Binding gbinding = new Binding(vbinding);
GroovyScriptEngine gse = new GroovyScriptEngine(new URL[] { sfile });
gse.run(sfile.toString(), gbinding);
@@ -1773,7 +1771,6 @@ public class Jalview
.errPrintln("Exception Whilst trying to execute file " + sfile
+ " as a groovy script.");
e.printStackTrace(System.err);
-
}
}
@@ -1787,30 +1784,32 @@ public class Jalview
return false;
}
+ @Override
public AlignFrame[] getAlignFrames()
{
return desktop == null ? new AlignFrame[] { getCurrentAlignFrame() }
- : Desktop.getAlignFrames();
-
+ : Desktop.getDesktopAlignFrames();
}
/**
* jalview.bin.Jalview.quit() will just run the non-GUI shutdownHook and exit
*/
+ @Override
public void quit()
{
// System.exit will run the shutdownHook first
Jalview.exit("Quitting now. Bye!", ExitCode.OK);
}
- public static AlignFrame getCurrentAlignFrame()
+ @Override
+ public AlignFrame getCurrentAlignFrame()
{
- return Jalview.currentAlignFrame;
+ return currentAlignFrame;
}
- public static void setCurrentAlignFrame(AlignFrame currentAlignFrame)
+ public void setCurrentAlignFrame(AlignFrame af)
{
- Jalview.currentAlignFrame = currentAlignFrame;
+ this.currentAlignFrame = af;
}
public Commands getCommands()
@@ -1862,7 +1861,7 @@ public class Jalview
// only add new ones to the end of the list (to preserve ordinal values)
OK, FILE_NOT_FOUND, FILE_NOT_READABLE, NO_FILES, INVALID_FORMAT,
INVALID_ARGUMENT, INVALID_VALUE, MIXED_CLI_ARGUMENTS,
- ERROR_RUNNING_COMMANDS;
+ ERROR_RUNNING_COMMANDS, NO_LOGGING, GROOVY_ERROR;
}
/******************************
@@ -2041,8 +2040,8 @@ public class Jalview
j.getArgParser().getMixedExamples());
String quit = MessageManager.getString("action.quit");
- Desktop.instance.nonBlockingDialog(title, warning, quit,
- JvOptionPane.WARNING_MESSAGE, false, true);
+ Desktop.instance.nonBlockingDialog(title, warning, null, quit,
+ JvOptionPane.WARNING_MESSAGE, false, false, true, 30000);
Jalview.exit(
"Exiting due to mixed old and new command line arguments.",
@@ -2066,8 +2065,8 @@ public class Jalview
{
String cont = MessageManager.getString("label.continue");
- Desktop.instance.nonBlockingDialog(32, 2, title, warning, url, cont,
- JvOptionPane.WARNING_MESSAGE, false, true, true);
+ Desktop.instance.nonBlockingDialog(title, warning, url, cont,
+ JvOptionPane.WARNING_MESSAGE, false, true, true, 30000);
}
}
if (j.getCommands() != null && j.getCommands().getErrors().size() > 0)
@@ -2087,7 +2086,7 @@ public class Jalview
Math.max(message.length(), Math.min(60, shortest)),
Math.min(errors.size(), 20), title, message,
j.getCommands().errorsToString(), ok,
- JvOptionPane.WARNING_MESSAGE, true, false, true);
+ JvOptionPane.WARNING_MESSAGE, true, false, true, -1);
}
}
}
diff --git a/src/jalview/bin/argparser/Arg.java b/src/jalview/bin/argparser/Arg.java
index 2a3a4a1..93156ac 100644
--- a/src/jalview/bin/argparser/Arg.java
+++ b/src/jalview/bin/argparser/Arg.java
@@ -44,6 +44,8 @@ public enum Arg
QUESTIONNAIRE(Type.CONFIG,
"Show (or don't show) the questionnaire if one is available.",
true, Opt.BOOLEAN, Opt.BOOTSTRAP),
+ JAVACONSOLE(Type.CONFIG, "Show (or don't show) the Java Console.", false,
+ Opt.BOOLEAN, Opt.BOOTSTRAP),
NOUSAGESTATS(Type.CONFIG, "Don't send initial launch usage stats.",
Opt.UNARY, Opt.BOOTSTRAP),
NOSTARTUPFILE(Type.CONFIG, "Don't show the default startup file.",
diff --git a/src/jalview/bin/argparser/ArgParser.java b/src/jalview/bin/argparser/ArgParser.java
index 1b8e6ad..155f69e 100644
--- a/src/jalview/bin/argparser/ArgParser.java
+++ b/src/jalview/bin/argparser/ArgParser.java
@@ -318,9 +318,13 @@ public class ArgParser
}
if (bsa != null)
+ {
this.bootstrapArgs = bsa;
+ }
else
+ {
this.bootstrapArgs = BootstrapArgs.getBootstrapArgs(args);
+ }
parse(args, initsubstitutions, allowPrivate);
}
diff --git a/src/jalview/bin/argparser/BootstrapArgs.java b/src/jalview/bin/argparser/BootstrapArgs.java
index d32a5b2..5c21d03 100644
--- a/src/jalview/bin/argparser/BootstrapArgs.java
+++ b/src/jalview/bin/argparser/BootstrapArgs.java
@@ -214,6 +214,13 @@ public class BootstrapArgs
}
}
}
+
+ // if in an argfile, remove it from the hashset so it can be re-used in
+ // another argfile
+ if (inArgFile != null)
+ {
+ argFiles.remove(inArgFile);
+ }
}
public boolean contains(Arg a)
diff --git a/src/jalview/bin/groovy/JalviewObject.java b/src/jalview/bin/groovy/JalviewObject.java
new file mode 100644
index 0000000..e271c3c
--- /dev/null
+++ b/src/jalview/bin/groovy/JalviewObject.java
@@ -0,0 +1,42 @@
+package jalview.bin.groovy;
+
+import jalview.bin.Jalview.ExitCode;
+import jalview.gui.AlignFrame;
+
+public class JalviewObject implements JalviewObjectI
+{
+ private JalviewObjectI object = null;
+
+ public JalviewObject(JalviewObjectI j)
+ {
+ this.object = j;
+ }
+
+ @Override
+ public AlignFrame[] getAlignFrames()
+ {
+ return object == null ? null : object.getAlignFrames();
+ }
+
+ @Override
+ public AlignFrame getCurrentAlignFrame()
+ {
+ return object == null ? null : object.getCurrentAlignFrame();
+ }
+
+ @Override
+ public void quit()
+ {
+ if (object != null)
+ {
+ object.quit();
+ }
+ else
+ {
+ jalview.bin.Jalview.exit(
+ "Groovy console quit without Jalview object.",
+ ExitCode.GROOVY_ERROR);
+ }
+ }
+
+}
diff --git a/src/jalview/bin/groovy/JalviewObjectI.java b/src/jalview/bin/groovy/JalviewObjectI.java
new file mode 100644
index 0000000..f365d30
--- /dev/null
+++ b/src/jalview/bin/groovy/JalviewObjectI.java
@@ -0,0 +1,16 @@
+package jalview.bin.groovy;
+
+import jalview.gui.AlignFrame;
+
+public interface JalviewObjectI
+{
+ public AlignFrame[] getAlignFrames();
+
+ public AlignFrame getCurrentAlignFrame();
+
+ public final static String currentAlFrameName = "currentAlFrame";
+
+ public final static String jalviewObjectName = "Jalview";
+
+ public void quit();
+}
diff --git a/src/jalview/datamodel/Alignment.java b/src/jalview/datamodel/Alignment.java
index aef2038..375e6b4 100755
--- a/src/jalview/datamodel/Alignment.java
+++ b/src/jalview/datamodel/Alignment.java
@@ -2057,7 +2057,7 @@ public class Alignment implements AlignmentI, AutoCloseable
if (cm == null && _aa.sequenceRef != null)
{
cm = _aa.sequenceRef.getContactMatrixFor(_aa);
- if (cm == null)
+ if (cm == null && _aa.sequenceRef.getDatasetSequence()!=null)
{
// TODO fix up this logic and unify with getContactListFor
cm = _aa.sequenceRef.getDatasetSequence().getContactMatrixFor(_aa);
diff --git a/src/jalview/datamodel/AlignmentAnnotation.java b/src/jalview/datamodel/AlignmentAnnotation.java
index 7e6b904..d85c3d8 100755
--- a/src/jalview/datamodel/AlignmentAnnotation.java
+++ b/src/jalview/datamodel/AlignmentAnnotation.java
@@ -142,7 +142,8 @@ public class AlignmentAnnotation
scaleColLabel = true;
_markRnaHelices();
}
- // jalview.bin.Console.outPrintln("featuregroup " + _rnasecstr[0].getFeatureGroup());
+ // jalview.bin.Console.outPrintln("featuregroup " +
+ // _rnasecstr[0].getFeatureGroup());
}
@@ -309,7 +310,8 @@ public class AlignmentAnnotation
public static final int CONTACT_MAP = 4;
/**
- * property that when set to non-empty string disables display of column groups defined on the contact matrix
+ * property that when set to non-empty string disables display of column
+ * groups defined on the contact matrix
*/
public static final String CONTACT_MAP_NOGROUPS = "CMNOGRPS";
@@ -446,7 +448,8 @@ public class AlignmentAnnotation
}
}
- // jalview.bin.Console.outPrintln("displaychar " + annotations[i].displayCharacter);
+ // jalview.bin.Console.outPrintln("displaychar " +
+ // annotations[i].displayCharacter);
if (annotations[i].displayCharacter == null
|| annotations[i].displayCharacter.length() == 0)
@@ -1750,23 +1753,30 @@ public class AlignmentAnnotation
}
return aa;
}
-
+
/**
- * convenience method to check for the 'CONTACT_MAP_NOGROUPS' property for this alignment annotation row
- * @return true if no CONTACT_MAP_NOGROUPS property is found, or it is set to ""
+ * convenience method to check for the 'CONTACT_MAP_NOGROUPS' property for
+ * this alignment annotation row
+ *
+ * @return true if no CONTACT_MAP_NOGROUPS property is found, or it is set to
+ * ""
*/
public boolean isShowGroupsForContactMatrix()
{
- return getProperty(AlignmentAnnotation.CONTACT_MAP_NOGROUPS)==null || "".equals(getProperty(AlignmentAnnotation.CONTACT_MAP_NOGROUPS));
+ return getProperty(AlignmentAnnotation.CONTACT_MAP_NOGROUPS) == null
+ || "".equals(
+ getProperty(AlignmentAnnotation.CONTACT_MAP_NOGROUPS));
}
+
/**
* set the 'CONTACT_MAP_NOGROUPS' property for this alignment annotation row
+ *
* @see isShowGroupsForContactMatrix
*/
public void setShowGroupsForContactMatrix(boolean showGroups)
{
- setProperty(AlignmentAnnotation.CONTACT_MAP_NOGROUPS, showGroups ? "" : "nogroups");
+ setProperty(AlignmentAnnotation.CONTACT_MAP_NOGROUPS,
+ showGroups ? "" : "nogroups");
}
-
}
diff --git a/src/jalview/datamodel/ContactMapHolder.java b/src/jalview/datamodel/ContactMapHolder.java
index af083dd..3a64917 100644
--- a/src/jalview/datamodel/ContactMapHolder.java
+++ b/src/jalview/datamodel/ContactMapHolder.java
@@ -3,6 +3,7 @@ package jalview.datamodel;
import java.util.Collection;
import java.util.Collections;
import java.util.HashMap;
+import java.util.HashSet;
import java.util.Map;
import jalview.ws.datamodel.MappableContactMatrixI;
@@ -17,7 +18,8 @@ public class ContactMapHolder implements ContactMapHolderI
{
if (contactmaps != null && contactmaps.size() > 0)
{
- return contactmaps.values();
+ // defensive copy, and return non redundant set of ContactMatrixI instances
+ return new HashSet(contactmaps.values());
}
return Collections.EMPTY_LIST;
}
diff --git a/src/jalview/datamodel/ContactMatrix.java b/src/jalview/datamodel/ContactMatrix.java
index 48b6e6b..2e12a91 100644
--- a/src/jalview/datamodel/ContactMatrix.java
+++ b/src/jalview/datamodel/ContactMatrix.java
@@ -1,17 +1,12 @@
package jalview.datamodel;
-import java.awt.Color;
-import java.math.BigInteger;
import java.util.ArrayList;
-import java.util.BitSet;
-import java.util.HashMap;
import java.util.List;
-import java.util.Spliterator;
import java.util.StringTokenizer;
import jalview.bin.Console;
-public abstract class ContactMatrix implements ContactMatrixI
+public abstract class ContactMatrix extends GroupSetHolder implements ContactMatrixI
{
/**
* are contacts reflexive ?
@@ -107,26 +102,7 @@ public abstract class ContactMatrix implements ContactMatrixI
@Override
public double getContactAt(int column)
{
- List clist;
- Float cl = null;
- if (symmetric)
- {
- if (p < column)
- {
- clist = contacts.get(p);
- cl = clist.get(column);
- }
- else
- {
- clist = contacts.get(column);
- cl = clist.get(p);
- }
- }
- else
- {
- clist = contacts.get(p);
- cl = clist.get(column);
- }
+ Float cl = getFloatElementAt(column, p);
if (cl == null)
{
// return 0 not NaN ?
@@ -136,7 +112,41 @@ public abstract class ContactMatrix implements ContactMatrixI
}
});
}
-
+ private Float getFloatElementAt(int column, int p)
+ {
+
+ List clist;
+ Float cl = null;
+ if (symmetric)
+ {
+ if (p < column)
+ {
+ clist = contacts.get(p);
+ cl = clist.get(column);
+ }
+ else
+ {
+ clist = contacts.get(column);
+ cl = clist.get(p);
+ }
+ }
+ else
+ {
+ clist = contacts.get(p);
+ cl = clist.get(column);
+ }
+ return cl;
+ }
+ @Override
+ public double getElementAt(int column, int row)
+ {
+ Float cl = getFloatElementAt(column, row);
+ if (cl!=null)
+ {
+ return cl;
+ }
+ throw(new RuntimeException("Out of Bounds "+column+","+row));
+ }
@Override
public float getMin()
{
@@ -160,30 +170,27 @@ public abstract class ContactMatrix implements ContactMatrixI
{
return "Contact Matrix";
}
- GroupSet grps = new GroupSet();
- @Override
- public GroupSetI getGroupSet()
- {
- return grps;
- }
- @Override
- public void setGroupSet(GroupSet makeGroups)
- {
- grps = makeGroups;
- }
public static String contactToFloatString(ContactMatrixI cm)
{
StringBuilder sb = new StringBuilder();
for (int c = 0; c < cm.getWidth(); c++)
{
ContactListI cl = cm.getContactList(c);
+ long lastsb=-1;
if (cl != null)
{
for (int h = 0; h <= cl.getContactHeight(); h++)
{
if (sb.length() > 0)
{
- sb.append('\t');
+ if (sb.length()-lastsb>320)
+ {
+ // newline
+ sb.append('\n');
+ lastsb=sb.length();
+ } else {
+ sb.append('\t');
+ }
}
sb.append(cl.getContactAt(h));
}
@@ -196,7 +203,7 @@ public abstract class ContactMatrix implements ContactMatrixI
int rows)
{
float[][] vals = new float[cols][rows];
- StringTokenizer tabsep = new StringTokenizer(values, "" + '\t');
+ StringTokenizer tabsep = new StringTokenizer(values, "" + '\t'+'\n');
int c = 0, r = 0;
while (tabsep.hasMoreTokens())
{
diff --git a/src/jalview/datamodel/ContactMatrixI.java b/src/jalview/datamodel/ContactMatrixI.java
index 925025f..4261519 100644
--- a/src/jalview/datamodel/ContactMatrixI.java
+++ b/src/jalview/datamodel/ContactMatrixI.java
@@ -199,5 +199,17 @@ public interface ContactMatrixI
}
return Color.white;
}
+
+ /**
+ * direct access to column and row position of matrix
+
+ * Implementations are allowed to throw
+ * RunTimeExceptions if _column/i are out of bounds
+ *
+ * @param column
+ * @param row
+ * @return
+ */
+ double getElementAt(int column, int row);
}
diff --git a/src/jalview/datamodel/FloatContactMatrix.java b/src/jalview/datamodel/FloatContactMatrix.java
new file mode 100644
index 0000000..5fb156f
--- /dev/null
+++ b/src/jalview/datamodel/FloatContactMatrix.java
@@ -0,0 +1,133 @@
+package jalview.datamodel;
+
+public class FloatContactMatrix extends GroupSetHolder implements ContactMatrixI
+{
+
+ int maxrow = 0, maxcol = 0;
+
+
+ float[][] elements;
+
+ float maxscore;
+
+
+ public FloatContactMatrix(float[][] matrix)
+ {
+ maxcol = 0;
+ for (float[] row : matrix)
+ {
+ if (row.length > maxcol)
+ {
+ maxcol = row.length;
+ }
+ maxscore = row[0];
+ for (float f : row)
+ {
+ if (maxscore < f)
+ {
+ maxscore = f;
+ }
+ }
+ }
+ maxrow = matrix.length;
+ elements = matrix;
+ }
+
+ public FloatContactMatrix(float[][] elements2, GroupSet grps2)
+ {
+ this(elements2);
+ setGroupSet(grps2);
+ }
+
+ /**
+ * getContactList(column) @returns the vector of predicted alignment errors
+ * for reference position given by column
+ */
+ @Override
+ public ContactListI getContactList(final int column)
+ {
+ if (column < 0 || column >= elements.length)
+ {
+ return null;
+ }
+
+ return new ContactListImpl(new ContactListProviderI()
+ {
+ @Override
+ public int getPosition()
+ {
+ return column;
+ }
+
+ @Override
+ public int getContactHeight()
+ {
+ return maxcol - 1;
+ }
+
+ @Override
+ public double getContactAt(int mcolumn)
+ {
+ if (mcolumn < 0 || mcolumn >= elements[column].length)
+ {
+ return -1;
+ }
+ return elements[column][mcolumn];
+ }
+ });
+ }
+
+ /**
+ * getElementAt(column, i) @returns the predicted superposition error for the
+ * ith position when column is used as reference
+ */
+ @Override
+ public double getElementAt(int _column, int i)
+ {
+ return elements[_column][i];
+ }
+
+ @Override
+ public float getMin()
+ {
+ return 0;
+ }
+
+ @Override
+ public float getMax()
+ {
+ return maxscore;
+ }
+
+ @Override
+ public String getAnnotDescr()
+ {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public String getAnnotLabel()
+ {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public String getType()
+ {
+ return null;
+ }
+
+ @Override
+ public int getWidth()
+ {
+ return maxcol;
+ }
+
+ @Override
+ public int getHeight()
+ {
+ return maxrow;
+ }
+}
diff --git a/src/jalview/datamodel/GroupSetHolder.java b/src/jalview/datamodel/GroupSetHolder.java
new file mode 100644
index 0000000..faeb7c0
--- /dev/null
+++ b/src/jalview/datamodel/GroupSetHolder.java
@@ -0,0 +1,24 @@
+package jalview.datamodel;
+
+/**
+ * holds a group set and provides getters and setters for ContactMatrixI
+ * implementations
+ *
+ * @author jprocter
+ */
+public class GroupSetHolder
+{
+
+ GroupSet grps = new GroupSet();
+
+ public GroupSetI getGroupSet()
+ {
+ return grps;
+ }
+
+ public void setGroupSet(GroupSet makeGroups)
+ {
+ grps = makeGroups;
+ }
+
+}
diff --git a/src/jalview/datamodel/SeqDistanceContactMatrix.java b/src/jalview/datamodel/SeqDistanceContactMatrix.java
index f8fd750..b04ac13 100644
--- a/src/jalview/datamodel/SeqDistanceContactMatrix.java
+++ b/src/jalview/datamodel/SeqDistanceContactMatrix.java
@@ -114,7 +114,7 @@ public class SeqDistanceContactMatrix
return width;
}
@Override
- protected double getElementAt(int _column, int i)
+ public double getElementAt(int _column, int i)
{
return Math.abs(_column - i);
}
diff --git a/src/jalview/ext/jmol/JalviewJmolBinding.java b/src/jalview/ext/jmol/JalviewJmolBinding.java
index dc18369..f51252c 100644
--- a/src/jalview/ext/jmol/JalviewJmolBinding.java
+++ b/src/jalview/ext/jmol/JalviewJmolBinding.java
@@ -26,6 +26,8 @@ import java.awt.event.ComponentListener;
import java.io.File;
import java.net.URL;
import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.StringTokenizer;
@@ -154,7 +156,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
jmolHistory(false);
if (lastCommand == null || !lastCommand.equals(cmd))
{
- jmolScript(cmd + "\n");
+ jmolScript(cmd + "\n",command.isWaitNeeded());
}
jmolHistory(true);
lastCommand = cmd;
@@ -184,7 +186,28 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
// End StructureListener
// //////////////////////////
-
+
+ ////////////////////////////
+ // HETATM get
+ //
+
+ @Override
+ public Map getHetatmNames()
+ {
+ HashMap hetlist=new HashMap();
+ for (int mc=0;mc hets = jmolViewer.ms.getHeteroList(mc);
+ if (hets!=null)
+ {
+ hetlist.putAll(hets);
+ }
+ }
+ return hetlist;
+ }
+ //
+ ////////////////////////////
+
@Override
public float[][] functionXY(String functionName, int x, int y)
{
diff --git a/src/jalview/ext/jmol/JmolCommands.java b/src/jalview/ext/jmol/JmolCommands.java
index f9ba1e4..1fb8761 100644
--- a/src/jalview/ext/jmol/JmolCommands.java
+++ b/src/jalview/ext/jmol/JmolCommands.java
@@ -241,7 +241,9 @@ public class JmolCommands extends StructureCommandsBase
/*
* https://chemapps.stolaf.edu/jmol/docs/#writemodel
*/
- return new StructureCommand("write STATE \"" + filepath + "\"");
+ StructureCommand sc = new StructureCommand("write STATE \"" + filepath + "\"");
+ sc.setWaitNeeded(true);
+ return sc;
}
@Override
@@ -323,6 +325,31 @@ public class JmolCommands extends StructureCommandsBase
"restore STATE \"" + Platform.escapeBackslashes(filePath) + "\"");
}
+ @Override
+ public List showHetatms(List toShow)
+ {
+ // always clear the current hetero cpk display
+
+ StringBuilder sb = new StringBuilder();
+ sb.append("select hetero; cpk off;");
+
+ if (toShow != null && !toShow.isEmpty())
+ {
+ // select what was requested
+ sb.append("select ");
+ boolean or = false;
+ for (String k : toShow)
+ {
+ sb.append(or ? " or " : " ");
+ sb.append(k);
+ or = true;
+ }
+ // and show as
+ sb.append("; cpk;");
+ }
+
+ return Arrays.asList(new StructureCommand(sb.toString()));
+ }
/**
* Obsolete method, only referenced from
* jalview.javascript.MouseOverStructureListener
diff --git a/src/jalview/fts/service/threedbeacons/TDB_FTSData.java b/src/jalview/fts/service/threedbeacons/TDB_FTSData.java
index 3045d3d..4e1b2b0 100644
--- a/src/jalview/fts/service/threedbeacons/TDB_FTSData.java
+++ b/src/jalview/fts/service/threedbeacons/TDB_FTSData.java
@@ -154,5 +154,14 @@ public class TDB_FTSData implements FTSData
{
return (String) getField(Model_id);
}
+
+ public String getConfidenceScoreType()
+ {
+ return (String) getField(Confidence_Score_Type);
+ }
+ public String getConfidenceScoreVersion()
+ {
+ return (String) getField(Confidence_Score_Version);
+ }
}
diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java
index f3cb012..4f13a78 100644
--- a/src/jalview/gui/AlignFrame.java
+++ b/src/jalview/gui/AlignFrame.java
@@ -95,6 +95,7 @@ import jalview.api.analysis.SimilarityParamsI;
import jalview.bin.Cache;
import jalview.bin.Console;
import jalview.bin.Jalview;
+import jalview.bin.groovy.JalviewObjectI;
import jalview.commands.CommandI;
import jalview.commands.EditCommand;
import jalview.commands.EditCommand.Action;
@@ -503,7 +504,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
@Override
public void focusGained(FocusEvent e)
{
- Jalview.setCurrentAlignFrame(AlignFrame.this);
+ Jalview.getInstance().setCurrentAlignFrame(AlignFrame.this);
}
});
@@ -4817,7 +4818,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
* Object[] { String,SequenceI}
*/
ArrayList