Merge branch 'develop' into patch/JAL-3088_finalbracenotinrightplace
authorJames Procter <j.procter@dundee.ac.uk>
Thu, 2 Nov 2023 18:49:04 +0000 (18:49 +0000)
committerJames Procter <j.procter@dundee.ac.uk>
Thu, 2 Nov 2023 18:49:04 +0000 (18:49 +0000)
 Conflicts: - JAL-4250
src/jalview/renderer/AnnotationRenderer.java

499 files changed:
THIRDPARTYLIBS
build.gradle
doc/building.md
examples/argfiles/test_fab41.txt
examples/argfiles/test_fab41_nostructureviewers.txt [new file with mode: 0644]
examples/groovy/ComputePeptideVariants.groovy
examples/groovy/JvLoadTester.groovy
examples/groovy/PIDmatrix.groovy
examples/groovy/alignLoadedFile.groovy
examples/groovy/annotationForSelectedSequence.groovy
examples/groovy/parseproperties.groovy
examples/groovy/printtitle.groovy
examples/groovy/removeFeaturesByGroup.groovy
examples/groovy/selectColumnsByFeatureAndGroup.groovy
examples/groovy/sitesForSelectedColumns.groovy
examples/groovy/stripUniprotPrefixes.groovy
examples/groovy/visibleFeaturesCounter.groovy
getdown/lib/FJVL_VERSION
getdown/lib/JVL_VERSION
getdown/lib/getdown-core.jar
getdown/lib/getdown-launcher-local.jar
getdown/lib/getdown-launcher.jar
getdown/src/getdown/ant/pom.xml
getdown/src/getdown/core/pom.xml
getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java
getdown/src/getdown/core/src/main/java/com/threerings/getdown/util/LaunchUtil.java
getdown/src/getdown/core/src/main/java/jalview/util/LaunchUtils.java
getdown/src/getdown/launcher/pom.xml
getdown/src/getdown/mvn_cmd
getdown/src/getdown/pom.xml
gradle.properties
help/help/help.jhm
help/help/helpTOC.xml
help/help/html/colourSchemes/annotationColouring.html
help/help/html/features/annotation.html
help/help/html/features/annotationsubmenucolbyannot.png [new file with mode: 0644]
help/help/html/features/clarguments-advanced.html
help/help/html/features/clarguments-argfiles.html
help/help/html/features/clarguments-basic.html
help/help/html/features/clarguments-reference.html
help/help/html/features/clarguments.html
help/help/html/features/groovy.html
help/help/html/features/jmol.html
help/help/html/features/local-pdb-import.png [new file with mode: 0644]
help/help/html/features/paematrices.html [new file with mode: 0644]
help/help/html/features/search.html
help/help/html/features/search.png
help/help/html/features/structurechooser.html
help/help/html/features/viewingpdbs.html
help/help/html/features/xsspannotation.html
help/help/html/groovy/featuresCounter.html
help/help/html/io/export.html
help/help/html/io/paematrixformat.html [new file with mode: 0644]
help/help/html/menus/alwannotationpanel.html
help/help/html/structures/epas1_annotdetail.png [new file with mode: 0644]
help/help/html/structures/epas1_pae_ebiaf.png [new file with mode: 0644]
help/help/icons/jalview_docs_logo.png [new file with mode: 0644]
help/markdown/releases/release-2_11_3_0.md
help/markdown/whatsnew/whatsnew-2_11_3_0.md
help/templates/whatsNew.html
j11lib/flatlaf-3.0.jar [deleted file]
j11lib/flatlaf-3.1.1.jar [deleted file]
j11lib/flatlaf-3.2.jar [new file with mode: 0644]
j11lib/flatlaf-extras-3.0.jar [deleted file]
j11lib/flatlaf-extras-3.2.jar [moved from j8lib/flatlaf-extras-3.1.1.jar with 52% similarity]
j11lib/getdown-core.jar
j11lib/groovy-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-all-2.4.21-indy.jar [deleted file]
j11lib/groovy-ant-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-astbuilder-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-cli-commons-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-cli-picocli-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-console-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-contracts-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-datetime-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-dateutil-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-docgenerator-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-ginq-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-groovydoc-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-groovysh-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-jmx-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-json-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-jsr223-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-macro-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-macro-library-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-nio-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-servlet-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-sql-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-swing-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-templates-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-test-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-test-junit5-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-testng-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-toml-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-typecheckers-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-xml-4.0.15.jar [new file with mode: 0644]
j11lib/groovy-yaml-4.0.15.jar [new file with mode: 0644]
j11lib/javaparser-core-3.25.5.jar [new file with mode: 0644]
j11lib/slf4j-api-1.7.32.jar [deleted file]
j11lib/slf4j-api-1.7.36.jar [new file with mode: 0644]
j11lib/slf4j-nop-1.7.36.jar [new file with mode: 0644]
j8lib/flatlaf-3.1.1.jar [deleted file]
j8lib/flatlaf-3.2.jar [new file with mode: 0644]
j8lib/flatlaf-extras-3.2.jar [moved from j11lib/flatlaf-extras-3.1.1.jar with 52% similarity]
j8lib/getdown-core.jar
j8lib/groovy-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-all-2.4.21-indy.jar [deleted file]
j8lib/groovy-ant-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-astbuilder-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-cli-commons-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-cli-picocli-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-console-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-contracts-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-datetime-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-dateutil-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-docgenerator-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-ginq-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-groovydoc-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-groovysh-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-jmx-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-json-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-jsr223-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-macro-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-macro-library-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-nio-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-servlet-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-sql-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-swing-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-templates-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-test-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-test-junit5-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-testng-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-toml-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-typecheckers-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-xml-4.0.15.jar [new file with mode: 0644]
j8lib/groovy-yaml-4.0.15.jar [new file with mode: 0644]
j8lib/javaparser-core-3.25.5.jar [new file with mode: 0644]
j8lib/slf4j-api-1.7.32.jar [deleted file]
j8lib/slf4j-api-1.7.36.jar [new file with mode: 0644]
j8lib/slf4j-nop-1.7.36.jar [new file with mode: 0644]
resources/lang/Messages.properties
resources/lang/Messages_es.properties
schemas/jalview.xsd
schemas/vamsas.xsd
src/jalview/analysis/AAFrequency.java
src/jalview/analysis/AlignSeq.java
src/jalview/analysis/AlignmentSorter.java
src/jalview/analysis/AlignmentUtils.java
src/jalview/analysis/Conservation.java
src/jalview/analysis/CrossRef.java
src/jalview/analysis/Dna.java
src/jalview/analysis/GeneticCodes.java
src/jalview/analysis/Grouping.java
src/jalview/analysis/ParseProperties.java
src/jalview/analysis/Rna.java
src/jalview/analysis/SeqsetUtils.java
src/jalview/analysis/StructureFrequency.java
src/jalview/analysis/TreeEngine.java
src/jalview/analysis/TreeModel.java
src/jalview/analysis/scoremodels/FeatureDistanceModel.java
src/jalview/analysis/scoremodels/ScoreMatrix.java
src/jalview/analysis/scoremodels/ScoreModels.java
src/jalview/api/SequenceRenderer.java
src/jalview/api/structures/JalviewStructureDisplayI.java
src/jalview/appletgui/APopupMenu.java
src/jalview/appletgui/AlignFrame.java
src/jalview/appletgui/AlignViewport.java
src/jalview/appletgui/AlignmentPanel.java
src/jalview/appletgui/AppletJmol.java
src/jalview/appletgui/ExtJmol.java
src/jalview/appletgui/PCAPanel.java
src/jalview/appletgui/PairwiseAlignPanel.java
src/jalview/appletgui/RedundancyPanel.java
src/jalview/appletgui/RotatableCanvas.java
src/jalview/appletgui/SeqCanvas.java
src/jalview/appletgui/SeqPanel.java
src/jalview/appletgui/SequenceRenderer.java
src/jalview/appletgui/TreePanel.java
src/jalview/bin/Cache.java
src/jalview/bin/Commands.java
src/jalview/bin/Console.java
src/jalview/bin/GetMemory.java
src/jalview/bin/HiDPISetting.java
src/jalview/bin/Jalview.java
src/jalview/bin/JalviewLite.java
src/jalview/bin/JalviewLiteURLRetrieve.java
src/jalview/bin/JalviewTaskbar.java
src/jalview/bin/Launcher.java
src/jalview/bin/MemorySetting.java
src/jalview/bin/argparser/Arg.java
src/jalview/bin/argparser/ArgParser.java
src/jalview/bin/argparser/ArgValues.java
src/jalview/bin/argparser/ArgValuesMap.java
src/jalview/bin/argparser/BootstrapArgs.java
src/jalview/bin/groovy/JalviewObject.java [new file with mode: 0644]
src/jalview/bin/groovy/JalviewObjectI.java [new file with mode: 0644]
src/jalview/commands/EditCommand.java
src/jalview/datamodel/AlignedCodonFrame.java
src/jalview/datamodel/Alignment.java
src/jalview/datamodel/AlignmentAnnotation.java
src/jalview/datamodel/AlignmentView.java
src/jalview/datamodel/ColumnSelection.java
src/jalview/datamodel/ContactListImpl.java
src/jalview/datamodel/ContactMapHolder.java
src/jalview/datamodel/ContactMatrix.java
src/jalview/datamodel/ContactMatrixI.java
src/jalview/datamodel/FloatContactMatrix.java [new file with mode: 0644]
src/jalview/datamodel/GroupSetHolder.java [new file with mode: 0644]
src/jalview/datamodel/HiddenSequences.java
src/jalview/datamodel/SearchResultMatchI.java
src/jalview/datamodel/SearchResults.java
src/jalview/datamodel/SearchResultsI.java
src/jalview/datamodel/SeqDistanceContactMatrix.java
src/jalview/datamodel/Sequence.java
src/jalview/datamodel/SequenceGroup.java
src/jalview/datamodel/features/FeatureMatcher.java
src/jalview/datamodel/features/FeatureMatcherSet.java
src/jalview/datamodel/features/FeatureStore.java
src/jalview/datamodel/features/SequenceFeatures.java
src/jalview/ext/ensembl/EnsemblGene.java
src/jalview/ext/ensembl/EnsemblLookup.java
src/jalview/ext/ensembl/EnsemblMap.java
src/jalview/ext/ensembl/EnsemblRestClient.java
src/jalview/ext/ensembl/EnsemblSeqProxy.java
src/jalview/ext/htsjdk/HtsContigDb.java
src/jalview/ext/jmol/JalviewJmolBinding.java
src/jalview/ext/jmol/JmolCommands.java
src/jalview/ext/jmol/JmolParser.java
src/jalview/ext/paradise/Annotate3D.java
src/jalview/ext/pymol/PymolManager.java
src/jalview/ext/rbvi/chimera/ChimeraListener.java
src/jalview/ext/rbvi/chimera/JalviewChimeraBinding.java
src/jalview/fts/core/FTSDataColumnPreferences.java
src/jalview/fts/service/alphafold/AlphafoldRestClient.java
src/jalview/fts/service/pdb/PDBFTSRestClient.java
src/jalview/fts/service/threedbeacons/TDB_FTSData.java
src/jalview/fts/service/threedbeacons/TDBeaconsFTSPanel.java
src/jalview/fts/service/threedbeacons/TDBeaconsFTSRestClient.java
src/jalview/fts/service/uniprot/UniProtFTSRestClient.java
src/jalview/gui/AlignExportOptions.java
src/jalview/gui/AlignFrame.java
src/jalview/gui/AlignViewport.java
src/jalview/gui/AlignmentPanel.java
src/jalview/gui/AnnotationLabels.java
src/jalview/gui/AnnotationPanel.java
src/jalview/gui/AppJmol.java
src/jalview/gui/AppJmolBinding.java
src/jalview/gui/AppVarna.java
src/jalview/gui/AppVarnaBinding.java
src/jalview/gui/BlogReader.java
src/jalview/gui/ChimeraViewFrame.java
src/jalview/gui/ColourMenuHelper.java
src/jalview/gui/Console.java
src/jalview/gui/CrossRefAction.java
src/jalview/gui/Desktop.java
src/jalview/gui/EditNameDialog.java
src/jalview/gui/FeatureEditor.java
src/jalview/gui/FeatureSettings.java
src/jalview/gui/FeatureTypeSettings.java
src/jalview/gui/Help.java
src/jalview/gui/IdCanvas.java
src/jalview/gui/IdwidthAdjuster.java
src/jalview/gui/ImageExporter.java
src/jalview/gui/JDatabaseTree.java
src/jalview/gui/JvOptionPane.java
src/jalview/gui/OptsAndParamsPage.java
src/jalview/gui/PaintRefresher.java
src/jalview/gui/PairwiseAlignPanel.java
src/jalview/gui/PopupMenu.java
src/jalview/gui/ProgressBar.java
src/jalview/gui/PymolBindingModel.java
src/jalview/gui/QuitHandler.java
src/jalview/gui/RedundancyPanel.java
src/jalview/gui/RestInputParamEditDialog.java
src/jalview/gui/RestServiceEditorPane.java
src/jalview/gui/ScalePanel.java
src/jalview/gui/SeqCanvas.java
src/jalview/gui/SeqCanvas.java.broken
src/jalview/gui/SeqPanel.java
src/jalview/gui/SequenceFetcher.java
src/jalview/gui/SequenceRenderer.java
src/jalview/gui/SplashScreen.java
src/jalview/gui/SplitFrame.java
src/jalview/gui/StructureChooser.java
src/jalview/gui/StructureViewer.java
src/jalview/gui/StructureViewerBase.java
src/jalview/gui/TreeCanvas.java
src/jalview/gui/TreePanel.java
src/jalview/gui/VamsasApplication.java
src/jalview/gui/WebserviceInfo.java
src/jalview/gui/WsJobParameters.java
src/jalview/gui/structurechooser/PDBStructureChooserQuerySource.java
src/jalview/gui/structurechooser/StructureChooserQuerySource.java
src/jalview/gui/structurechooser/TDBResultAnalyser.java
src/jalview/gui/structurechooser/ThreeDBStructureChooserQuerySource.java
src/jalview/httpserver/AbstractRequestHandler.java
src/jalview/httpserver/HttpServer.java
src/jalview/io/AnnotationFile.java
src/jalview/io/AppletFormatAdapter.java
src/jalview/io/BackupFilenameFilter.java
src/jalview/io/BioJsHTMLOutput.java
src/jalview/io/ClustalFile.java
src/jalview/io/DataSourceType.java
src/jalview/io/FeaturesFile.java
src/jalview/io/FileFormat.java
src/jalview/io/FileFormats.java
src/jalview/io/FileLoader.java
src/jalview/io/FileParse.java
src/jalview/io/HTMLOutput.java
src/jalview/io/HtmlSvgOutput.java
src/jalview/io/IdentifyFile.java
src/jalview/io/JPredFile.java
src/jalview/io/JSONFile.java
src/jalview/io/JalviewFileChooser.java
src/jalview/io/JalviewFileFilter.java
src/jalview/io/JalviewFileView.java
src/jalview/io/MSFfile.java
src/jalview/io/NewickFile.java
src/jalview/io/PIRFile.java
src/jalview/io/PfamFile.java
src/jalview/io/PhylipFile.java
src/jalview/io/RnamlFile.java
src/jalview/io/SequenceAnnotationReport.java
src/jalview/io/SimpleBlastFile.java
src/jalview/io/StockholmFile.java
src/jalview/io/StructureFile.java
src/jalview/io/TCoffeeScoreFile.java
src/jalview/io/VamsasAppDatastore.java
src/jalview/io/WSWUBlastClient.java
src/jalview/io/cache/JvCacheableInputBox.java
src/jalview/io/gff/ExonerateHelper.java
src/jalview/io/gff/Gff3Helper.java
src/jalview/io/gff/GffHelperBase.java
src/jalview/io/gff/SequenceOntologyLite.java
src/jalview/io/packed/JalviewDataset.java
src/jalview/io/packed/ParsePackedSet.java
src/jalview/io/vamsas/Sequencemapping.java
src/jalview/io/vamsas/Tree.java
src/jalview/io/vcf/VCFLoader.java
src/jalview/javascript/JSFunctionExec.java
src/jalview/javascript/JsSelectionSender.java
src/jalview/javascript/MouseOverListener.java
src/jalview/javascript/MouseOverStructureListener.java
src/jalview/jbgui/GAlignFrame.java
src/jalview/jbgui/GAlignmentPanel.java
src/jalview/jbgui/GDesktop.java
src/jalview/jbgui/GStructureChooser.java
src/jalview/jbgui/GStructureViewer.java
src/jalview/log/JLogger.java
src/jalview/math/Matrix.java
src/jalview/math/RotatableMatrix.java
src/jalview/project/Jalview2XML.java
src/jalview/renderer/AnnotationRenderer.java
src/jalview/renderer/ContactGeometry.java
src/jalview/renderer/ContactMapRenderer.java
src/jalview/rest/RestHandler.java
src/jalview/schemes/ColourSchemeLoader.java
src/jalview/schemes/ColourSchemes.java
src/jalview/schemes/Consensus.java
src/jalview/schemes/CovariationColourScheme.java
src/jalview/schemes/FeatureColour.java
src/jalview/schemes/RNAHelicesColour.java
src/jalview/schemes/ResidueProperties.java
src/jalview/schemes/UserColourScheme.java
src/jalview/structure/StructureCommandsBase.java
src/jalview/structure/StructureCommandsI.java
src/jalview/structure/StructureSelectionManager.java
src/jalview/structures/models/AAStructureBindingModel.java
src/jalview/urls/IdentifiersUrlProvider.java
src/jalview/urls/UrlProvider.java
src/jalview/util/AWTConsole.java
src/jalview/util/ChannelProperties.java
src/jalview/util/DBRefUtils.java
src/jalview/util/FileUtils.java
src/jalview/util/Format.java
src/jalview/util/GroupUrlLink.java
src/jalview/util/HttpUtils.java
src/jalview/util/ImageMaker.java
src/jalview/util/LaunchUtils.java
src/jalview/util/Log4j.java
src/jalview/util/MapUtils.java
src/jalview/util/Platform.java
src/jalview/util/StringUtils.java
src/jalview/util/UrlLink.java
src/jalview/util/imagemaker/BitmapImageSizing.java
src/jalview/viewmodel/AlignmentViewport.java
src/jalview/viewmodel/ViewportRanges.java
src/jalview/viewmodel/styles/ViewStyle.java
src/jalview/workers/AlignCalcManager.java
src/jalview/workers/AlignmentAnnotationFactory.java
src/jalview/workers/ConsensusThread.java
src/jalview/ws/AWSThread.java
src/jalview/ws/DBRefFetcher.java
src/jalview/ws/JobStateSummary.java
src/jalview/ws/SequenceFetcher.java
src/jalview/ws/datamodel/MappableContactMatrixI.java
src/jalview/ws/datamodel/alphafold/MappableContactMatrix.java
src/jalview/ws/datamodel/alphafold/PAEContactMatrix.java
src/jalview/ws/dbsources/EBIAlfaFold.java
src/jalview/ws/dbsources/EbiFileRetrievedProxy.java
src/jalview/ws/dbsources/EmblXmlSource.java
src/jalview/ws/dbsources/Pdb.java
src/jalview/ws/ebi/EBIFetchClient.java
src/jalview/ws/jws1/Annotate3D.java
src/jalview/ws/jws1/Discoverer.java
src/jalview/ws/jws1/JPredThread.java
src/jalview/ws/jws1/MsaWSThread.java
src/jalview/ws/jws1/SeqSearchWSThread.java
src/jalview/ws/jws2/AbstractJabaCalcWorker.java
src/jalview/ws/jws2/JabaParamStore.java
src/jalview/ws/jws2/JabaWsServerQuery.java
src/jalview/ws/jws2/JabawsCalcWorker.java
src/jalview/ws/jws2/JabawsMsaInterfaceAlignCalcWorker.java
src/jalview/ws/jws2/Jws2Discoverer.java
src/jalview/ws/jws2/MsaWSThread.java
src/jalview/ws/jws2/ParameterUtils.java
src/jalview/ws/jws2/jabaws2/Jws2Instance.java
src/jalview/ws/rest/InputType.java
src/jalview/ws/rest/RestClient.java
src/jalview/ws/rest/RestJobThread.java
src/jalview/ws/seqfetcher/ASequenceFetcher.java
src/jalview/ws/sifts/SiftsClient.java
src/jalview/ws/utils/UrlDownloadClient.java
src/jalview/xml/binding/jalview/AlcodonFrame.java
src/jalview/xml/binding/jalview/Annotation.java
src/jalview/xml/binding/jalview/AnnotationColourScheme.java
src/jalview/xml/binding/jalview/AnnotationElement.java
src/jalview/xml/binding/jalview/DoubleMatrix.java
src/jalview/xml/binding/jalview/DoubleVector.java
src/jalview/xml/binding/jalview/Feature.java
src/jalview/xml/binding/jalview/FeatureMatcher.java
src/jalview/xml/binding/jalview/FeatureMatcherSet.java
src/jalview/xml/binding/jalview/FilterBy.java
src/jalview/xml/binding/jalview/JalviewModel.java
src/jalview/xml/binding/jalview/JalviewUserColours.java
src/jalview/xml/binding/jalview/MapListType.java
src/jalview/xml/binding/jalview/MapOnAMatrixType.java [new file with mode: 0644]
src/jalview/xml/binding/jalview/Mapping.java
src/jalview/xml/binding/jalview/MatrixType.java
src/jalview/xml/binding/jalview/NoValueColour.java
src/jalview/xml/binding/jalview/ObjectFactory.java
src/jalview/xml/binding/jalview/PcaDataType.java
src/jalview/xml/binding/jalview/Pdbentry.java
src/jalview/xml/binding/jalview/Property.java
src/jalview/xml/binding/jalview/Sequence.java
src/jalview/xml/binding/jalview/SequenceSet.java
src/jalview/xml/binding/jalview/SequenceType.java
src/jalview/xml/binding/jalview/ThresholdType.java
src/jalview/xml/binding/jalview/VAMSAS.java
src/jalview/xml/binding/jalview/WebServiceParameterSet.java
src/jalview/xml/binding/jalview/package-info.java
test/files/annotation_label_width/sample.a2m [new file with mode: 0644]
test/files/annotation_label_width/test_fab41_nostructureviewers.txt [new file with mode: 0644]
test/jalview/bin/CommandLineOperations.java
test/jalview/bin/CommandLineOperationsNG.java
test/jalview/bin/CommandsTest.java
test/jalview/bin/CommandsTest2.java
test/jalview/bin/HiDPISettingTest1.java
test/jalview/bin/HiDPISettingTest2.java
test/jalview/bin/argparser/ArgParserTest.java
test/jalview/bin/commandsTest2.argfile1
test/jalview/bin/test1-3.fa [new file with mode: 0644]
test/jalview/bin/uniref50-output.blc [new file with mode: 0644]
test/jalview/bin/uniref50-output.fa [new file with mode: 0644]
test/jalview/datamodel/PAEContactMatrixTest.java
test/jalview/datamodel/SearchResultsTest.java
test/jalview/ext/jmol/JmolViewerTest.java
test/jalview/ext/rbvi/chimera/JalviewChimeraView.java
test/jalview/fts/service/pdb/PDBFTSRestClientTest.java
test/jalview/fts/threedbeacons/TDBeaconsFTSRestClientTest.java
test/jalview/fts/threedbeacons/q99814_tdb_fts_query.txt [new file with mode: 0644]
test/jalview/fts/threedbeacons/q99814_tdb_fts_query_resp.txt [new file with mode: 0644]
test/jalview/fts/threedbeacons/q99814_tdb_pdbfts_query_resp.txt [new file with mode: 0644]
test/jalview/gui/AlignFrameTest.java
test/jalview/gui/AlignViewportTest.java
test/jalview/gui/AlignmentPanelTest.java
test/jalview/gui/AnnotationLabelsTest2.java [new file with mode: 0644]
test/jalview/gui/DesktopTests.java
test/jalview/gui/FeatureSettingsTest.java
test/jalview/gui/FreeUpMemoryTest.java
test/jalview/gui/QuitHandlerTest.java
test/jalview/gui/ScalePanelTest.java
test/jalview/gui/SeqPanelTest.java
test/jalview/gui/SequenceRendererTest.java
test/jalview/gui/structurechooser/StructureChooserQuerySourceTest.java
test/jalview/io/AnnotatedPDBFileInputTest.java
test/jalview/io/CrossRef2xmlTests.java
test/jalview/io/JalviewExportPropertiesTests.java
test/jalview/io/SequenceAnnotationReportTest.java
test/jalview/io/cache/JvCacheableInputBoxTest.java
test/jalview/project/Jalview2xmlTests.java
test/jalview/renderer/ContactGeometryTest.java [new file with mode: 0644]
test/jalview/renderer/seqfeatures/FeatureRendererTest.java
test/jalview/schemes/ColourSchemesTest.java
test/jalview/util/FileUtilsTest.java
test/jalview/util/ImageMakerTest.java [new file with mode: 0644]
test/jalview/util/imagemaker/BitmapImageSizeTest.java [new file with mode: 0644]
utils/conda/jalview.sh [new file with mode: 0755]
utils/getdown/bin/jalview.sh

index a2710f4..e52f3f6 100644 (file)
@@ -58,7 +58,8 @@ miglayout-4.0-swing.jar       BSD - http://www.migcalendar.com/miglayout/versions/4.0/
 regex.jar
 saaj.jar
 servlet-api-3.1.jar
-slf4j-api-1.7.32.jar   MIT license - https://opensource.org/licenses/mit-license.php
+slf4j-api-1.7.36.jar   MIT license - https://opensource.org/licenses/mit-license.php - downloaded from https://repo1.maven.org/maven2/org/slf4j/
+slf4j-nop-1.7.36.jar   MIT license - https://opensource.org/licenses/mit-license.php - downloaded from https://repo1.maven.org/maven2/org/slf4j/
 vamsas-client.jar
 VARNAv3-93.jar GPL licenced software by K�vin Darty, Alain Denise and Yann Ponty - http://varna.lri.fr
 wsdl4j.jar
index 7ad6f99..011be67 100644 (file)
@@ -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
@@ -1783,6 +1783,27 @@ task testTask1(type: Test) {
   }
 }
 
+task testTask2(type: Test) {
+  group = "Verification"
+  description = "Tests that need to be isolated from the main test run"
+  useTestNG() {
+    includeGroups name
+    excludeGroups testng_excluded_groups.split(",")
+    preserveOrder true
+    useDefaultListeners=true
+  }
+}
+task testTask3(type: Test) {
+  group = "Verification"
+  description = "Tests that need to be isolated from the main test run"
+  useTestNG() {
+    includeGroups name
+    excludeGroups testng_excluded_groups.split(",")
+    preserveOrder true
+    useDefaultListeners=true
+  }
+}
+
 /* insert more testTaskNs here -- change N to next digit or other string */
 /*
 task testTaskN(type: Test) {
@@ -1830,10 +1851,16 @@ 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 ]
   }
 
+  if (OperatingSystem.current().isMacOsX()) {
+    testTask.systemProperty "apple.awt.UIElement", "true"
+    testTask.environment "JAVA_TOOL_OPTIONS", "-Dapple.awt.UIElement=true"
+  }
 
 
   ignoreFailures = true // Always try to run all tests for all modules
@@ -2129,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"
@@ -2996,6 +3044,7 @@ task sourceDist(type: Tar) {
   into project.name
 
   def EXCLUDE_FILES=[
+    "dist/*",
     "build/*",
     "bin/*",
     "test-output/",
index 34d5d67..aee827d 100644 (file)
@@ -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*
 
index e6f7627..b7f0d45 100644 (file)
@@ -10,4 +10,4 @@
 --paematrix=[label=pAE R4-M5]./examples/test_fab41.result/test_fab41_unrelaxed_rank_4_model_5_scores.json
 --structure=./examples/test_fab41.result/test_fab41_unrelaxed_rank_5_model_1.pdb
 --paematrix=[label=pAE R5-M1]./examples/test_fab41.result/test_fab41_unrelaxed_rank_5_model_1_scores.json
---image=output1.html
+--image=[textrenderer=text]output1.html
diff --git a/examples/argfiles/test_fab41_nostructureviewers.txt b/examples/argfiles/test_fab41_nostructureviewers.txt
new file mode 100644 (file)
index 0000000..ab52cdf
--- /dev/null
@@ -0,0 +1,14 @@
+--open=./examples/test_fab41.result/sample.a2m
+--colour=gecos:flower
+--gui
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb
+--paematrix=[label=pAE R1-M3]./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_2_model_4.pdb
+--paematrix=[label=pAE R2-M4]./examples/test_fab41.result/test_fab41_unrelaxed_rank_2_model_4_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_3_model_2.pdb
+--paematrix=[label=pAE R3-M2]./examples/test_fab41.result/test_fab41_unrelaxed_rank_3_model_2_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_4_model_5.pdb
+--paematrix=[label=pAE R4-M5]./examples/test_fab41.result/test_fab41_unrelaxed_rank_4_model_5_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_5_model_1.pdb
+--paematrix=[label=pAE R5-M1]./examples/test_fab41.result/test_fab41_unrelaxed_rank_5_model_1_scores.json
+--image=[textrenderer=text]output1.html
index 6caa69c..e5ece51 100644 (file)
@@ -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"
index d844d62..cc92e40 100644 (file)
@@ -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
+}
index b97abcc..76b9de7 100644 (file)
@@ -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
+}
index 764fdae..df68e2b 100644 (file)
@@ -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
index abfad35..7cb3082 100644 (file)
@@ -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
index 879bd49..ceec6d2 100644 (file)
@@ -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 <http://www.gnu.org/licenses/>.
  * 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();
 
index b3387ea..a048d65 100644 (file)
@@ -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 <http://www.gnu.org/licenses/>.
  * 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()
index 341e06f..c947a5b 100644 (file)
@@ -46,6 +46,7 @@ for (ala in af)
                        }
                }
        }
+       ala.repaint();
 }
        
 
index b8edaa7..aaa3405 100644 (file)
@@ -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
+    }
index 8165373..f775f18 100644 (file)
@@ -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
 
index 71b3a9f..5a01da4 100644 (file)
@@ -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
+       
index b3180f8..510f600 100644 (file)
@@ -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 <http://www.gnu.org/licenses/>.
  * 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
 
index 35bd812..2d83e61 100644 (file)
@@ -1 +1 @@
-1.8.3-1.2.14_FJVL
+1.8.3-1.3.1_FJVL
index 0a14c3b..7d618e2 100644 (file)
@@ -1 +1 @@
-1.8.3-1.2.14_JVL
+1.8.3-1.3.1_JVL
index 7c99c93..3fc97b5 100644 (file)
Binary files a/getdown/lib/getdown-core.jar and b/getdown/lib/getdown-core.jar differ
index c6901ae..6ba0a6d 100644 (file)
Binary files a/getdown/lib/getdown-launcher-local.jar and b/getdown/lib/getdown-launcher-local.jar differ
index 24e3eb2..7c75a34 100644 (file)
Binary files a/getdown/lib/getdown-launcher.jar and b/getdown/lib/getdown-launcher.jar differ
index b0c54e2..4c91f74 100644 (file)
@@ -4,7 +4,7 @@
   <parent>
     <groupId>com.threerings.getdown</groupId>
     <artifactId>getdown</artifactId>
-    <version>1.8.3-1.2.14_FJVL</version>
+    <version>1.8.3-1.3.1_FJVL</version>
   </parent>
 
   <artifactId>getdown-ant</artifactId>
index 5dd429d..2e43522 100644 (file)
@@ -4,7 +4,7 @@
   <parent>
     <groupId>com.threerings.getdown</groupId>
     <artifactId>getdown</artifactId>
-    <version>1.8.3-1.2.14_FJVL</version>
+    <version>1.8.3-1.3.1_FJVL</version>
   </parent>
 
   <artifactId>getdown-core</artifactId>
index 9d9fe14..435ebbd 100644 (file)
@@ -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");
           }
         }
 
index 0781a11..1faaa28 100644 (file)
@@ -17,6 +17,8 @@ import javax.xml.bind.DatatypeConverter;
 
 import java.security.MessageDigest;
 
+import jalview.util.LaunchUtils;
+
 import static com.threerings.getdown.Log.log;
 
 /**
@@ -88,6 +90,7 @@ public class LaunchUtil
         return getJVMPath(appdir, false);
     }
 
+    private static String jvmPath = null;
     /**
      * Reconstructs the path to the JVM used to launch this process.
      *
@@ -95,22 +98,27 @@ public class LaunchUtil
      */
     public static String getJVMPath (File appdir, boolean windebug)
     {
-        // first look in our application directory for an installed VM
-        String vmpath = checkJVMPath(new File(appdir, LOCAL_JAVA_DIR).getAbsolutePath(), windebug);
-        if (vmpath == null && isMacOS()) {
-                       vmpath = checkJVMPath(new File(appdir, LOCAL_JAVA_DIR + "/Contents/Home").getAbsolutePath(), windebug);
+        if (jvmPath != null) {
+          return jvmPath;
         }
+        
+        // first look in our application directory for an installed VM
+        final String appDir = isMacOS() ?
+                        (new File(appdir, LOCAL_JAVA_DIR).getAbsolutePath()) + "/Contents/Home"
+                        : new File(appdir, LOCAL_JAVA_DIR).getAbsolutePath();
+
+        String javaBin = LaunchUtils.findJavaBin(appDir, windebug, false);
 
         // then fall back to the VM in which we're already running
-        if (vmpath == null) {
-            vmpath = checkJVMPath(System.getProperty("java.home"), windebug);
+        if (javaBin == null) {
+            javaBin = LaunchUtils.findJavaBin(System.getProperty("java.home"), windebug, false);
         }
 
         // then throw up our hands and hope for the best
-        if (vmpath == null) {
+        if (javaBin == null) {
+            javaBin = LaunchUtils.findJavaBin(null, windebug, true);
             log.warning("Unable to find java [appdir=" + appdir +
                         ", java.home=" + System.getProperty("java.home") + "]!");
-            vmpath = "java";
         }
 
         // Oddly, the Mac OS X specific java flag -Xdock:name will only work if java is launched
@@ -120,15 +128,16 @@ public class LaunchUtil
         if (isMacOS()) {
             try {
                 File localVM = new File("/usr/bin/java").getCanonicalFile();
-                if (localVM.equals(new File(vmpath).getCanonicalFile())) {
-                    vmpath = "/usr/bin/java";
+                if (localVM.equals(new File(javaBin).getCanonicalFile())) {
+                    javaBin = "/usr/bin/java";
                 }
             } catch (IOException ioe) {
                 log.warning("Failed to check Mac OS canonical VM path.", ioe);
             }
         }
 
-        return vmpath;
+        jvmPath = javaBin;
+        return jvmPath;
     }
 
     private static String _getMD5FileChecksum (File file) {
index ee3b2c6..784eb5a 100644 (file)
@@ -32,6 +32,16 @@ import java.util.Properties;
 public class LaunchUtils
 {
 
+  // setting these is LaunchUtils so don't need to import Platform
+  public final static boolean isMac = System.getProperty("os.name")
+          .indexOf("Mac") > -1;
+
+  public final static boolean isWindows = System.getProperty("os.name")
+          .indexOf("Win") > -1;
+
+  private static boolean isJS = /** @j2sNative true || */
+          false;
+
   public static void loadChannelProps(File dir)
   {
     ChannelProperties.loadProps(dir);
@@ -81,7 +91,11 @@ public class LaunchUtils
 
   public static int getJavaCompileVersion()
   {
-    if (JAVA_COMPILE_VERSION > 0)
+    if (LaunchUtils.isJS)
+    {
+      return -1;
+    }
+    else if (JAVA_COMPILE_VERSION > 0)
     {
       return JAVA_COMPILE_VERSION;
     }
@@ -125,7 +139,11 @@ public class LaunchUtils
 
   public static int getJavaVersion()
   {
-    if (JAVA_VERSION > 0)
+    if (LaunchUtils.isJS)
+    {
+      return -1;
+    }
+    else if (JAVA_VERSION > 0)
     {
       return JAVA_VERSION;
     }
@@ -153,6 +171,10 @@ public class LaunchUtils
 
   public static boolean checkJavaVersion()
   {
+    if (LaunchUtils.isJS)
+    {
+      return true;
+    }
     String buildDetails = "jar:".concat(LaunchUtils.class
             .getProtectionDomain().getCodeSource().getLocation().toString()
             .concat("!" + "/.build_properties"));
@@ -174,4 +196,88 @@ public class LaunchUtils
 
     return true;
   }
+
+  public static String findJavaBin(boolean winConsole)
+  {
+    return findJavaBin(System.getProperty("java.home"), winConsole, true);
+  }
+
+  /*
+   * Returns a string path to the most likely java binary wanted to run this
+   * installation of Jalview.
+   * 
+   * @param  winConsole  whether to use java.exe (console) in preference to javaw.exe
+   *                     (only affects Windows).
+   * @param  javaHome    Try this javaHome dir (defaults to the running java.home).
+   * @param  generic     Return a generic java command if not found.
+   */
+  public static String findJavaBin(String javaHome, boolean winConsole,
+          boolean generic)
+  {
+    String javaBin = null;
+    final String javaExe = winConsole ? "java.exe" : "javaw.exe";
+    final String java = "java";
+
+    if (javaHome != null)
+    {
+      // property "channel.app_name" is set by install4j when launching getdown
+      String propertyAppName = System.getProperty("channel.app_name");
+      final String appName = (propertyAppName != null
+              && propertyAppName.length() > 0) ? propertyAppName
+                      : ChannelProperties.getProperty("app_name");
+
+      final String javaBinDir = javaHome + File.separator + "bin"
+              + File.separator;
+
+      // appName and "Jalview" will not point to javaw.exe or java.exe but in
+      // this case that's okay because the taskbar display name problem doesn't
+      // manifest in Windows. See JAL-3820, JAL-4189.
+      for (String name : new String[] { appName, "Jalview", java, javaExe })
+      {
+        if (LaunchUtils.checkJVMSymlink(javaBinDir + name, winConsole))
+        {
+          javaBin = javaBinDir + name;
+          break;
+        }
+      }
+    }
+
+    if (javaBin == null && generic)
+    {
+      javaBin = LaunchUtils.isWindows ? javaExe : java;
+    }
+
+    return javaBin;
+  }
+
+  /*
+   * checkJVMSymlink returns true if the path in testBin *is* a java binary, or
+   * points to a java binary.
+   * @param  testBin     The binary or symbolic link to check
+   * @param  winConsole  whether we are in/want a Windows console (only relevant for Windows,
+   *                     determines whether we use java.exe or javaw.exe)
+   */
+  private static boolean checkJVMSymlink(String testBin, boolean winConsole)
+  {
+    File testBinFile = new File(testBin);
+    if (!testBinFile.exists())
+    {
+      return false;
+    }
+    File targetFile = null;
+    try
+    {
+      targetFile = testBinFile.getCanonicalFile();
+    } catch (IOException e)
+    {
+      return false;
+    }
+    final String javaExe = winConsole ? "java.exe" : "javaw.exe";
+    if (targetFile != null && ("java".equals(targetFile.getName())
+            || javaExe.equals(targetFile.getName())))
+    {
+      return true;
+    }
+    return false;
+  }
 }
index ea3b6ef..c6b9ff3 100644 (file)
@@ -4,7 +4,7 @@
   <parent>
     <groupId>com.threerings.getdown</groupId>
     <artifactId>getdown</artifactId>
-    <version>1.8.3-1.2.14_FJVL</version>
+    <version>1.8.3-1.3.1_FJVL</version>
   </parent>
 
   <artifactId>getdown-launcher</artifactId>
index b30194f..10942f8 100755 (executable)
@@ -3,7 +3,7 @@
 if [ x$JVLVERSION != x ]; then
   export VERSION=$JVLVERSION
 else
-  export VERSION=1.8.3-1.2.14_JVL
+  export VERSION=1.8.3-1.3.1_JVL
 fi
 
 if [ x${VERSION%_JVL} = x$VERSION ]; then
index ef8c811..cf32333 100644 (file)
@@ -10,7 +10,7 @@
   <groupId>com.threerings.getdown</groupId>
   <artifactId>getdown</artifactId>
   <packaging>pom</packaging>
-  <version>1.8.3-1.2.14_FJVL</version>
+  <version>1.8.3-1.3.1_FJVL</version>
 
   <name>getdown</name>
   <description>An application installer and updater.</description>
index 547304f..79fb11d 100644 (file)
@@ -28,6 +28,8 @@ jalview_keydig = SHA1
 
 testng_groups = Functional
 testng_excluded_groups = 
+test_output =
 
 j8libDir = j8lib
 j11libDir = j11lib
@@ -177,7 +179,7 @@ imagemagick_convert = ~/buildtools/imagemagick/bin/convert
 
 bamboo_channelbase = https://builds.jalview.org/browse
 bamboo_planKey = 
-bamboo_getdown_channel_suffix = /latest/artifact/shared/getdown-channel
+bamboo_getdown_channel_suffix = /latest/artifact/shared/getdown-build-for-website/default
 
 eclipse_codestyle_file = utils/eclipse/JalviewCodeStyle.xml
 eclipse_extra_jdt_prefs_file = utils/eclipse/org.eclipse.jdt.core.jalview.prefs
index a2094f7..5fb7901 100755 (executable)
    <mapID target="pdbfts" url="html/features/pdbsequencefetcher.html#pdbfts" />
    <mapID target="siftsmapping" url="html/features/siftsmapping.html" />
    <mapID target="pdbchooser" url="html/features/structurechooser.html" />
+   <mapID target="structureandpaefromfile" url="html/features/structurechooser.html#loadfromfile" />
    <mapID target="structuresvia3dbeacons" url="html/features/structurechooser.html#3dbeaconssearch" />   
+   <mapID target="workingwithpae" url="html/features/paematrices.html" />
+   <mapID target="paematrixformat" url="html/io/paematrixformat.html" />
    <mapID target="selectcolbyannot" url="html/features/columnFilterByAnnotation.html" />
    <mapID target="biojsmsa" url="html/features/biojsmsa.html" />
    
index d7ff3d4..6d7c948 100755 (executable)
 <!-- DO NOT WRAP THESE LINES - help2Website relies on each item being on one line! -->
        <tocitem text="Jalview Documentation" target="home" expand="true">
                        <tocitem text="What's new" target="new" expand="true">
-                               <tocitem text="Latest Release Notes" target="release"/>
-                       <tocitem text="Support for ChimeraX" target="chimera"/>
-                               <tocitem text="Support for Pymol" target="pymol"/>
-                               <tocitem text="Structures via 3D Beacons" target="structuresvia3dbeacons" />
-                               <tocitem text="Startup Memory Settings" target="startupprefs" />
-                       <tocitem text="The Java Console, Logging and Reporting Bugs" target="logging" />
-                       <tocitem text="Command line launch" target="jalviewcltool"/>
+                       <tocitem text="Latest Release Notes" target="release"/>
+                       <tocitem text="Next Generation Command Line Interface" target="clarguments" />
+                       <tocitem text="AlphaFold PAE Matrices" target="workingwithpae" />
+                       <tocitem text="Nucleotide Ambiguity colours" target="colours.nucleotideambiguity" />                            
                </tocitem>
                
                <tocitem text="Editing Alignments" target="edit" />
index 2272503..c9221a1 100755 (executable)
   <p>Jalview allows the columns of an alignment to be coloured using
     any numerical annotation rows added to that alignment.</p>
   Select &quot;Colour&quot;
-  <strong>&#8594;</strong> &quot;.. by Annotation&quot; to bring up the
+  <strong>&#8594;</strong> &quot;by Annotation...&quot; to bring up the
   Colour by Annotation settings window.
   <br>
+       <br>You can also apply Colour by annotation for a particular annotation
+       (or per-sequence set) by right-clicking an annotation row's label and selecting &quot;Colour by Annotation...&quot; or &quot;Colour by Annotation (per Sequence)...&quot; from the 
+       <strong>Annotation label popup menu</strong>. (<em>Since Jalview 2.11.3</em>)
+       <br>
+  <div align="center">
+  <img src="../features/annotationsubmenucolbyannot.png" width="414" height="266">
+  </div>
+  <p><strong>The Colour by Annotation Settings Window</strong></p>
   <br>
   <div align="center">
     <img src="annotationColourSetting.gif" width="471" height="256">
index b63d20b..76b23eb 100755 (executable)
@@ -29,7 +29,7 @@
 
   <p>
     In addition to the definition of groups and sequence features,
-    Jalview can display symbols and graphs under the columns of an
+    Jalview can display symbols, line graphs, histograms and heatmaps under the columns of an
     alignment. These annotation tracks are displayed in the annotation
     area below the alignment. The annotation area's visibility is
     controlled with the <strong>View&#8594;Show Annotation</strong>
   <ul>
     <li><a name="seqannots"><strong>Sequence
           associated annotation.</strong></a><br />Data displayed on sequence
-      annotation rows are associated with the positions of a sequence.
+      associated annotation rows are associated with the positions of a sequence.
       Often this is 'Reference annotation' such as secondary structure
       information derived from 3D structure data, or from the results of
       sequence based prediction of <a href="../webServices/jnet.html">secondary
         structure</a> and <a href="../webServices/proteinDisorder.html">disorder</a>.
-      If reference annotation is available for a the currently selected
-      sequences, it can be shown by selecting the <strong>Add
+      If reference annotations are available for a particular sequence or the current selections, they can be shown by selecting the <strong>Add
         Reference Annotation</strong> option in the sequence or selection popup
-      menu.</li>
+      menu.<br/>Jalview currently supports the following sources of sequence associated annotation:<ul><li>Protein and RNA Secondary Structure<br/>These can be obtained from JPred and RNAAliFold secondary structure prediction services, and also for imported 3D Structure data.</li><li>Temperature factor, Model Quality or AlphaFold Reliability</br>Jalview extracts and displays values from the 'Temperature Factor' column of PDB and mmCIF files, interpreted in various ways. For regular PDB files, these are imported directly as 'Temperature Factor', but for structures from computational methods such as EBI-AlphaFold, these values are interpreted and shown as 'AlphaFold Reliability' or 'Model Quality' according to the source.</li><li><a href="paematrices.html">Predicted Alignment Error</a> heatmaps<br/>These are displayed for models retrieved from EBI-AlphaFold or when a supported JSON format PAE file is provided when importing a <a href="structurechooser.html#loadpdbfile">local 3D structure file</a>.</li></ul></li>
     <li><strong>Group associated annotation.</strong><br />Data can
       be associated with groups defined on the alignment. If sequence
       groups are defined, <a href="../calculations/conservation.html">Conservation</a>
       alignment</a>. Annotations can also be used to <a
       href="../features/columnFilterByAnnotation.html">select or
       hide columns</a> via the dialog opened from the <strong>Selection</strong>
-    menu.
+    menu. You can also colour, select or hide columns of the alignment using any displayed annotation row by right-clicking its label and selecting the option from the displayed pop-up menu.
   </p>
   <p>
+    <strong>Adjusting the height of histograms, line graphs and heatmaps</strong><br/>The height of line graphs, bar charts and <a href="paematrices.html">predicted alignment error (PAE) matrix heatmaps</a> can be adjusted simply by click-dragging them up or down to increase or decrease the height. Hold down <em><strong>SHIFT</strong></em> to adjust the height of all instances of a particular type of annotation row.</p>
+  <p>
     <strong>Sequence Highlighting and Selection from Annotation</strong>
   </p>
   <p>
       (Mac CMD) double-click</strong> will toggle inclusion of associated
     sequences in the selection.
   <p>
+    <strong>Selecting, analysing and exploring heatmap annotation</strong>
+  </p><p>Mouseovers on heap annotation tracks result in a tooltip displaying information about the range of values under the mouse, and their associated row and column in the heatmap.<br/>For <a href="paematrices.html">Predicted Alignment Error (PAE) matrices</a>, the only form of heatmap annotation currently supported by Jalview, both the vertical and horizontal positions in the heatmap correspond to positions in linked 3D structures and the associated sequence in the alignment - so clicking any position in a heatmap will select columns in the alignment corresponding to the selected row(s) and column under the mouse.
+    <ul>
+      <li>Rows and columns in the heatmap corresponding to currently selected columns in the alignment are shown as red horizontal and vertical bands.</li>
+      <li><em>Rectangular Selections</em> can be created by pressing <em>CMD (or Window/Meta key)</em> whilst click-dragging across an area of the annotation.</li>
+      <li><em>Data driven selections</em> - e.g. selecting regions of low values of Predicted Alignment Error in a heatmap can be dome by pressing <em>CTRL</em> whilst clicking a region of an alignment.</li>
+    </ul>
+    Heatmap annotations can also be clustered, enabling columns of the alignment to be grouped based on similarity of the sets of values in the heatmap. <em>Double clicking</em> a region of a clustered heatmap annotation will select both the row and columns of the alignment grouped by the clustering. See <a href="paematrices.html#clustering">clustering PAE matrices</a> for more information.
+  <p>
     <strong>Interactive Alignment Annotation</strong>
   </p>
   <p>
         in 2.5)</em><br> <em>Selecting this toggles whether column
         labels will be shrunk to fit within each column, or displayed
         using the view's standard font size.</em></li>
+    <li><strong></strong><em>(introduced in 2.11.3)</em><br/><em></em></li>
+    <li><strong></strong><em>(introduced in 2.11.3)</em><br/><em></em></li>
+    <li><strong></strong><em>(introduced in 2.11.3)</em><br/><em></em></li>
+    <li><strong></strong><em>(introduced in 2.11.3)</em><br/><em></em></li>
+    <li><strong></strong><em>(introduced in 2.11.3)</em><br/><em></em></li>
+    <li><strong></strong><em>(introduced in 2.11.3)</em><br/><em></em></li>
+    
   </ul>
   <p>
     <strong>Editing labels and secondary structure annotation
diff --git a/help/help/html/features/annotationsubmenucolbyannot.png b/help/help/html/features/annotationsubmenucolbyannot.png
new file mode 100644 (file)
index 0000000..22f69d9
Binary files /dev/null and b/help/help/html/features/annotationsubmenucolbyannot.png differ
index a235727..8e4012c 100644 (file)
   <h2><a name="alignmentlinkedids"></a>Alignment linked IDs</h2>
 
   <p>
-  Jalview's alignment related arguments are linked together using a <em>linked ID</em>.  In all of the basic usage examples this linked ID is assigned using a default formula of <code>JALVIEW:<em>n</em></code> where <em>n</em> starts at 0 and increments every time there is an <code>--open</code>ed file (or a first use of <code>--append</code>) or the <code>--new</code> argument is used.
+  Jalview's alignment related arguments are linked together using a <em>linked ID</em>.  In all of the basic usage examples this linked ID is assigned using a default formula of <code>JALVIEW:<em>n</em></code> where <em>n</em> starts at 0 and increments every time there is an <code>&#8209;&#8209;open</code>ed file (or a first use of <code>&#8209;&#8209;append</code>) or the <code>&#8209;&#8209;new</code> argument is used.
   </p>
 
   <p>
-  When another alignment related argument is used (without a specified linked ID), it is assigned this default linked ID.  When the <code>--all</code> argument is used, following alignment related arguments are applied to all of the linked IDs (made so far).
+  When another alignment related argument is used (without a specified linked ID), it is assigned this default linked ID.  When the <code>&#8209;&#8209;all</code> argument is used, following alignment related arguments are applied to all of the linked IDs (made so far).
   </p>
 
   <p>
@@ -67,7 +67,7 @@
   </p>
 
   <p>
-  A specified linked ID will also take precedence over a wildcard or <code>--all</code> set linked ID. e.g.
+  A specified linked ID will also take precedence over a wildcard or <code>&#8209;&#8209;all</code> set linked ID. e.g.
   <pre>
   jalview --open[myID] examples/uniref50.fa --all --colour taylor --colour[myID] gecos-blossom
   </pre>
   </p>
 
 
-  <h2><a name="moresubstitutions"></a>More substitutions (<code>{n}</code>, <code>{++n}</code>, <code>[*]</code>)</h2>
+  <h2><a name="moresubstitutions"></a>More substitutions (<code>{n}</code>, <code>{++n}</code>, <code>[*]</code>, <code>{m}</code>, <code>{++m}</code>)</h2>
 
   <p>
   In the <a href="clarguments-basic.html#substitutions">basic usage document</a> we have a list of special strings that get replaced in output filename values with parts of input filename values.
   </p>
 
   <p>
-  There is also an incrementor integer value <code>{n}</code> that can be put into both linked IDs and filenames and works across different linked IDs.  Whenever you use <code>{n}</code> in a linked ID or filename value it is replaced with the current value of <em>n</em>.  The initial value is 0, and it can be incremented by using the argument <code>--npp</code> or <code>--n++</code>, or using a another special substitution <code>{++n}</code> in either a linked ID or filename value which increments the value and is replaced with the new incremented value of <em>n</em>.
+  There is also an incrementor integer value <code>{n}</code> that can be put into both linked IDs and filenames and works across different linked IDs.  Whenever you use <code>{n}</code> in a linked ID or filename value it is replaced with the current value of <em>n</em>.  The initial value is 0, and it can be incremented by using the argument <code>&#8209;&#8209;npp</code> or <code>&#8209;&#8209;n++</code>, or using a another special substitution <code>{++n}</code> in either a linked ID or filename value which increments the value and is replaced with the new incremented value of <em>n</em>.
   </p>
 
   <p>
-  In the same way that the <code>--all</code> argument enables (some) following arguments to apply to all opened alignments so far, the special linked ID <code>*</code> will also apply an individual argument to all opened linked IDs (in fact when you use the <code>--all</code> argument it simply changes the default linked ID to <code>*</code>).
+  In the same way that the <code>&#8209;&#8209;all</code> argument enables (some) following arguments to apply to all opened alignments so far, the special linked ID <code>*</code> will also apply an individual argument to all opened linked IDs (in fact when you use the <code>&#8209;&#8209;all</code> argument it simply changes the default linked ID to <code>*</code>).
   <pre>
   jalview --open[myId1] fileA.fa --open[myId2] fileB.fa --open[myId3] fileC.fa --colour[*] taylor --all --image tmp/image-{++n}.png --headless
   </pre>
   </pre>
   because all of the command line arguments are read and sorted into their linked IDs before starting to be processed, and the <code>[myId3]</code> specified linked ID takes precedence over the <code>[*]</code> wildcard linked ID.
   </p>
-  </p>
 
+  <p>
+  All of the substitutions talked about so far are evaluated in the argument parsing process.  If in some cases (almost certainly involving structure images!) you find <code>{n}</code> is not incrementing when you think it should, when specifying <code>&#8209;&#8209;structureimage</code> filenames you can also use <code>{m}</code> and <code>{++m}</code>, along with <code>{structuredirname}</code>, <code>{structurebasename}</code> and <code>{structureextension}</code> which are substituted at the point of use.  <code>{m}</code> is just a plain counter starting at 0.
+  </p>
 
   <h2><a name="equalsseparatorandfileglobs"></a>Equals separator and Java file globs</h2>
 
   </p>
 
   <p>
-  One benefit of this is seen above in the <code>--image</code> argument, the special "alloutput" wildcard filename <code>*.png</code> will not be expanded by the shell, so does not need to be escaped or surrounded with quotation marks.
+  One benefit of this is seen above in the <code>&#8209;&#8209;image</code> argument, the special "alloutput" wildcard filename <code>*.png</code> will not be expanded by the shell, so does not need to be escaped or surrounded with quotation marks.
   </p>
 
   <p>
   </p>
 
   <p>
-  Some arguments (such as <code>--scale=<em>n</em></code>) are used to modify the behaviour of other "primary" arguments (such as <code>--image=filename</code>).  These arguments can alternatively be specifed as <em>sub-value modifiers</em> of the values given to the primary argument.  If specified as a sub-value modifier, this modifier takes precedence over any following linked argument if given. e.g
+  Some arguments (such as <code>&#8209;&#8209;scale=<em>n</em></code>) are used to modify the behaviour of other "primary" arguments (such as <code>&#8209;&#8209;image=filename</code>).  These arguments can alternatively be specifed as <em>sub-value modifiers</em> of the values given to the primary argument.  If specified as a sub-value modifier, this modifier takes precedence over any following linked argument if given. e.g
   <pre>
   jalview --open=[colour=zappo]examples/*.fa
   </pre>
   </p>
 
   <p>
-  You can specify multiple sub-value modifiers separating them with a comma (',').  If you wish to specify a "boolean" argument, such as <code>--wrap</code> or <code>--nowrap</code> then simply use the argument name without a value, like this:
+  You can specify multiple sub-value modifiers separating them with a comma (',').  If you wish to specify a "boolean" argument, such as <code>&#8209;&#8209;wrap</code> or <code>&#8209;&#8209;nowrap</code> then simply use the argument name without a value, like this:
   <pre>
   jalview --open=[colour=gecos-flower,wrap,noannotations,features=examples/plantfdx.features]examples/plantfdx.fa
   </pre>
index 5c71d16..ad27751 100644 (file)
@@ -86,7 +86,7 @@
   </p>
 
   <p>
-  Because <code>--argfiles</code> takes a filename argument, and multiple <code>--argfiles</code> can be read on the command line, you can also use file globs to specify multiple <code>--argfile</code> values.  If you produce an argument file for each set of alignment files that you wish to associate then you can act on all of them with, e.g.
+  Because <code>&#8209;&#8209;argfiles</code> takes a filename argument, and multiple <code>&#8209;&#8209;argfiles</code> can be read on the command line, you can also use file globs to specify multiple <code>&#8209;&#8209;argfile</code> values.  If you produce an argument file for each set of alignment files that you wish to associate then you can act on all of them with, e.g.
   <pre>
   jalview --argfile=*/argfile.txt --headless
   </pre>
   <h2><a name="onlyargumentfiles"></a>Only argument files</h2>
 
   <p>
-  When you use an <code>--argfile</code> argument, all other non-initialising arguments on the command line <em>will be ignored</em>.  Only the initialising arguments and any and all <code>--argfiles</code> arguments on the command line will be used.  You can also set initialising arguments in argument files.
+  When you use an <code>&#8209;&#8209;argfile</code> argument, all other non-initialising arguments on the command line <em>will be ignored</em>.  Only the initialising arguments and any and all <code>&#8209;&#8209;argfiles</code> arguments on the command line will be used.  You can also set initialising arguments in argument files.
   </p>
 
 
index 7a87602..238366c 100644 (file)
   <li><a href="#alloutputwildcard">The all output wildcard</a></li>
   </ul>
 
-  <h2><a name="openingalignments"></a>Opening alignments (<code>--open</code>, <code>--append</code>, <code>--new</code>)</h2>
+  <h2><a name="openingalignments"></a>Opening alignments (<code>&#8209;&#8209;open</code>, <code>&#8209;&#8209;append</code>, <code>&#8209;&#8209;new</code>)</h2>
 
   <p>
-  To simply open one or more alignment files in different windows just put the filenames as the first arguments:
+  To simply open one or more alignment files in different alignment windows just put the filenames as the first arguments:
   <pre>
   jalview filename1 filename2 ...
   </pre>
   </p>
 
   <p>
-  (Using initial filenames is the same as using the <code>--open</code> argument, and further arguments can be used
+  (Using initial filenames is the same as using the <code>&#8209;&#8209;open</code> argument, and further arguments can be used
   after the initial filenames.)
   </p>
 
-  <h3><a name="open"></a><code>--open</code></h3>
+  <h3><a name="open"></a><code>&#8209;&#8209;open</code></h3>
 
   <p>
-  Use the <code>--open</code> argument to open alignment files each in their own window.
+  Use the <code>&#8209;&#8209;open</code> argument to open alignment files each in their own window.
   </p>
 
   <p>
   </pre>
   </p>
 
-  <h3><a name="append"></a><code>--append</code></h3>
+  <h3><a name="append"></a><code>&#8209;&#8209;append</code></h3>
 
   <p>
   To append several alignment files together use:
   <pre>
   jalview --open filename1.fa --append filename2.fa filename3.fa
   </pre>
-  or, if you haven't previously used <code>--open</code> then you can use --append to open one new window and keep appending each set of alignments:
+  or, if you haven't previously used <code>&#8209;&#8209;open</code> then you can use --append to open one new window and keep appending each set of alignments:
   <pre>
   jalview --append these/filename*.fa --append more/filename*.fa
 
   </p>
 
   <p>
-  <strong>Note</strong> that whilst you can include a Jalview Project File (<code>.jvp</code>) as an <code>--append</code> value, the items in the file will always open in their original windows and not append to another.
+  <strong>Note</strong> that whilst you can include a Jalview Project File (<code>.jvp</code>) as an <code>&#8209;&#8209;append</code> value, the items in the file will always open in their original windows and not append to another.
   </p>
 
-  <h3><a name="new"></a><code>--new</code></h3>
+  <h3><a name="new"></a><code>&#8209;&#8209;new</code></h3>
 
   <p>
-  To append different sets of alignment files in different windows, use <code>--new</code> to move on to a new alignment window:
+  To append different sets of alignment files in different windows, use <code>&#8209;&#8209;new</code> to move on to a new alignment window:
   <pre>
   jalview --append these/filename*.fa --new --append other/filename*.fa
   </pre>
   </p>
 
   <p>
-  <code>--open</code> is like using <code>--new --append</code> applied to every filename/URL given to <code>--open</code>
+  <code>&#8209;&#8209;open</code> is like using <code>&#8209;&#8209;new --append</code> applied to every filename/URL given to <code>&#8209;&#8209;open</code>
   </p>
 
 
-  <h2><a name="alignmentoptions"></a>Alignment options (<code>--colour</code>, <code>--wrap</code>, <code>--showannotations</code>, <code>--title</code>)</h2>
+  <h2><a name="alignmentoptions"></a>Alignment options (<code>&#8209;&#8209;colour</code>, <code>&#8209;&#8209;wrap</code>, <code>&#8209;&#8209;showannotations</code>, <code>&#8209;&#8209;title</code>)</h2>
 
-  <h3><a name="colour"></a><code>--colour</code></h3>
+  <p>
+  An opened alignment window (or set of opened alignment windows) can be modified in its appearance using the following arguments before the next <code>&#8209;&#8209;open</code> argument.  These modifying arguments apply to the one or more files that were opened with the preceding <code>&#8209;&#8209;open</code> argument.  E.g. <code>&#8209;&#8209;open file.fa --colour gecos-flower</code> will colour the one alignment window with <code>file.fa</code>.  However, <code>&#8209;&#8209;open *.fa --colour gecos-flower</code> will colour every alignment window matching <code>file*.fa</code>, and <code> --open file1.fa file2.fa --colour gecos-flower</code>
+  will colour both opened alignment windows.
+  </p>
+
+  <h3><a name="colour"></a><code>&#8209;&#8209;colour</code></h3>
 
   <p>
-  You can specify a residue/base colouring for the alignment using the <code>--colour</code> option (note spelling -- Jalview is made in Scotland!):
+  You can specify a residue/base colouring for the alignment using the <code>&#8209;&#8209;colour</code> option (note spelling -- Jalview is made in Scotland!):
   <pre>
   jalview --open examples/uniref50.fa --colour gecos-flower
   </pre>
   <code>sequence-id</code>
   </p>
 
-  <h3><a name="wrap"></a><code>--wrap</code></h3>
+  <h3><a name="wrap"></a><code>&#8209;&#8209;wrap</code></h3>
   <p>
-  An alignment should open with your usual preferences stored in the <code>.jalview_properties</code> file.  To open an alignment with the sequences (definitely) wrapped, following your <code>--open</code> (or first <code>--append</code>) argument use the argument <code>--wrap</code>:
+  An alignment should open with your usual preferences stored in the <code>.jalview_properties</code> file.  To open an alignment with the sequences (definitely) wrapped, following your <code>&#8209;&#8209;open</code> (or first <code>&#8209;&#8209;append</code>) argument use the argument <code>&#8209;&#8209;wrap</code>:
   <pre>
   jalview --open examples/uniref50.fa --wrap
   </pre>
-  To ensure an alignment is not wrapped use <code>--nowrap</code>:
+  To ensure an alignment is not wrapped use <code>&#8209;&#8209;nowrap</code>:
   <pre>
   jalview --open examples/uniref50.fa --nowrap
   </pre>
   </p>
 
-  <h3><a name="showannotations"></a><code>--showannotations</code> / <code>--noshowannotations</code></h3>
+  <h3><a name="showannotations"></a><code>&#8209;&#8209;showannotations</code> / <code>&#8209;&#8209;noshowannotations</code></h3>
 
   <p>
-  You can specify whether the currently opened alignment window should show alignment annotations (e.g. Conservation, Quality, Consensus...) or not with either <code>--showannotations</code> or <code>--noshowannotations</code>.  If you don't specify then your saved preference will be used.
+  You can specify whether the currently opened alignment window should show alignment annotations (e.g. Conservation, Quality, Consensus...) or not with either <code>&#8209;&#8209;showannotations</code> or <code>&#8209;&#8209;noshowannotations</code>.  If you don't specify then your saved preference will be used.
   <pre>
   jalview --open examples/uniref50.fa --noshowannotations
   </pre>
   </p>
 
-  <h3><a name="title"></a><code>--title</code></h3>
+  <h3><a name="title"></a><code>&#8209;&#8209;title</code></h3>
 
   <p>
-  If you would like to give the alignment window a specific title you can do so with the <code>--title</code> option:
+  If you would like to give the alignment window a specific title you can do so with the <code>&#8209;&#8209;title</code> option:
   <pre>
   jalview --open examples/uniref50.fa --title "My example alignment"
   </pre>
 
 
 
-  <h2><a name="adding3dstructures"></a>Adding 3D structures (<code>--structure</code>, <code>--seqid</code>, <code>--structureviewer</code>, <code>--paematrix</code>, <code>--tempfac</code>, <code>--showssannotations</code>)</h2>
+  <h2><a name="adding3dstructures"></a>Adding 3D structures (<code>&#8209;&#8209;structure</code>, <code>&#8209;&#8209;seqid</code>, <code>&#8209;&#8209;structureviewer</code>, <code>&#8209;&#8209;paematrix</code>, <code>&#8209;&#8209;tempfac</code>, <code>&#8209;&#8209;showssannotations</code>)</h2>
 
   <p>
   </p>
 
-  <h3><a name="structure"></a><code>--structure</code></h3>
+  <h3><a name="structure"></a><code>&#8209;&#8209;structure</code></h3>
 
   <p>
-  You can add a 3D structure file to a sequence in the current alignment window with the <code>--structure</code> option:
+  You can add a 3D structure file to a sequence in the current alignment window with the <code>&#8209;&#8209;structure</code> option:
   <pre>
   jalview --open examples/uniref50.fa --structure examples/AlphaFold/AF-P00221-F1-model_v4.pdb
   </pre>
   By default this attaches to the first sequence in the alignment but most likely you will want to attach it to a specific sequence.
   </p>
 
-  <h3><a name="seqid"></a><code>--seqid</code></h3>
+  <h3><a name="seqid"></a><code>&#8209;&#8209;seqid</code></h3>
 
   <p>
-  The easiest way to specify a sequence ID for your structure is to follow the <code>--structure</code> argument with a <code>--seqid</code> argument with a value of a sequence ID in the alignment.  This does of course require some knowledge of the sequences in the alignment files
+  The easiest way to specify a sequence ID for your structure is to follow the <code>&#8209;&#8209;structure</code> argument with a <code>&#8209;&#8209;seqid</code> argument with a value of a sequence ID in the alignment.  This does of course require some knowledge of the sequences in the alignment files
   that have been opened.
   <br/>
-  Alternatively you can specify a <em>sub-value</em> with the <code>--structure</code> argument value.  You do this by preceding the value with square brackets and <code>seqid=SequenceId</code>,
+  Alternatively you can specify a <em>sub-value</em> with the <code>&#8209;&#8209;structure</code> argument value.  You do this by preceding the value with square brackets and <code>seqid=SequenceId</code>,
   like this:
   <pre>
   jalview --open examples/uniref50.fa --structure [seqid=FER1_SPIOL]examples/AlphaFold/AF-P00221-F1-model_v4.pdb
   </p>
 
   <p>
-  The sub-value <code>seqid=FER1_SPIOL</code> takes precedence over the following argument <code>--seqid FER1_SPIOL</code> if you accidentally specify both (in which case the argument will probably be completely unused).
+  The sub-value <code>seqid=FER1_SPIOL</code> takes precedence over the following argument <code>&#8209;&#8209;seqid FER1_SPIOL</code> if you accidentally specify both (in which case the argument will probably be completely unused).
   </p>
 
   <p>
   Remember that you might need to escape any spaces in the sequence ID or enclose the ID in quotation marks.
   </p>
 
-  <h3><a name="structureviewer"></a><code>--structureviewer</code></h3>
+  <h3><a name="structureviewer"></a><code>&#8209;&#8209;structureviewer</code></h3>
 
   <p>
-  You can specify which structure viewer (or none) to use to open the structure using either the <code>--structureviewer</code> argument or the <code>structureviewer</code> sub-value.  Multiple sub-values can be specified together, separated by a comma ','.  Possible values for the <code>structureviewer</code> are:
+  You can specify which structure viewer (or none) to use to open the structure using either the <code>&#8209;&#8209;structureviewer</code> argument or the <code>structureviewer</code> sub-value.  Multiple sub-values can be specified together, separated by a comma ','.  Possible values for the <code>structureviewer</code> are:
   <br/>
   <code>none</code>,
   <br/>
   </pre>
   </p>
 
-  <h3><a name="paematrix"></a><code>--paematrix</code></h3>
+  <h3><a name="paematrix"></a><code>&#8209;&#8209;paematrix</code></h3>
 
   <p>
-  If you are opening a structure file that has a PAE matrix (provided as a JSON file), such as from an AlphaFold model or an nf-core pipeline, you can add the PAE matrix as an annotation by following the <code>--structure</code> argument with a <code>--paematrix</code> argument with the filename.  You can also specify a <code>paematrix=filename</code> sub-value.
+  If you are opening a structure file that has a PAE matrix (provided as a JSON file), such as from an AlphaFold model or an nf-core pipeline, you can add the PAE matrix as an annotation by following the <code>&#8209;&#8209;structure</code> argument with a <code>&#8209;&#8209;paematrix</code> argument with the filename.  You can also specify a <code>paematrix=filename</code> sub-value.
   <pre>
   jalview --open examples/uniref50.fa --structure [seqid=FER1+SPIOL,structureviewer=pymol]examples/AlphaFold/AF-P00221-F1-model_v4.pdb --paematrix examples/AlphaFold/AF-P00221-F1-predicted_aligned_error_v4.json
   </pre>
   </p>
 
-  <h3><a name="tempfac"></a><code>--tempfac</code></h3>
+  <h3><a name="tempfac"></a><code>&#8209;&#8209;tempfac</code></h3>
 
   <p>
-  Structure files may have a temperature factor associated with the structure component positions.  If the temperature factor is a pLDDT confidence score, such as with an AlphaFold model, you can specify this by using a following argument of <code>--tempfac</code> with a value of <code>plddt</code>.  This will enable standard pLDDT colouring of the temperature factor annotation.  Valid values are:
+  Structure files may have a temperature factor associated with the structure component positions.  If the temperature factor is a pLDDT confidence score, such as with an AlphaFold model, you can specify this by using a following argument of <code>&#8209;&#8209;tempfac</code> with a value of <code>plddt</code>.  This will enable standard pLDDT colouring of the temperature factor annotation.  Valid values are:
   <code>default</code>,
   <code>plddt</code>.
   More types of temperature factor may be added in future releases of Jalview.
   <br/>
   The value can also be specified as a sub-value:
   <pre>
-  jalview --open examples/uniref50.fa --structure [seqid=FER1+SPIOL,structureviewer=jmol,tempfac=plddt]examples/AlphaFold/AF-P00221-F1-model_v4.pdb
+  jalview --open examples/uniref50.fa --structure [seqid=FER1_SPIOL,structureviewer=jmol,tempfac=plddt]examples/AlphaFold/AF-P00221-F1-model_v4.pdb
   </pre>
   which is equivalent to
   <pre>
-  jalview --open examples/uniref50.fa --structure examples/AlphaFold/AF-P00221-F1-model_v4.pdb --tempfac plddt --seqid FER1+SPIOL
+  jalview --open examples/uniref50.fa --structure examples/AlphaFold/AF-P00221-F1-model_v4.pdb --tempfac plddt --seqid FER1_SPIOL
    --structureviewer jmol
   </pre>
 
 
   <!-- notempfac not yet working. undocumented until then -->
 
-  <h3><a name="showssannotations"></a><code>--showssannotations</code> / <code>--noshowssannotations</code></h3>
+  <h3><a name="showssannotations"></a><code>&#8209;&#8209;showssannotations</code> / <code>&#8209;&#8209;noshowssannotations</code></h3>
 
   <p>
-  You can specify whether the currently opened alignment window should show secondary structure annotations or not with either <code>--showssannotations</code> or <code>--noshowssannotations</code>.  If you don't specify then your saved preference will be used.
+  You can specify whether the currently opened alignment window should show secondary structure annotations or not with either <code>&#8209;&#8209;showssannotations</code> or <code>&#8209;&#8209;noshowssannotations</code>.  If you don't specify then your saved preference will be used.
   <pre>
   jalview --open examples/uniref50.fa --structure examples/AlphaFold/AF-P00221-F1-model_v4.pdb --noshowssannotations
   </pre>
   </pre>
   </p>
 
-  <h2><a name="outputtingalignmentfiles"></a>Outputting/converting alignment files and images (<code>--output</code>, <code>--format</code>, <code>--image</code>, <code>--type</code>, <code>--textrenderer</code>, <code>--scale</code>, <code>--backups</code>, <code>--overwrite</code>)</h2>
+  <h2><a name="outputtingalignmentfiles"></a>Outputting/converting alignment files and images (<code>&#8209;&#8209;output</code>, <code>&#8209;&#8209;format</code>, <code>&#8209;&#8209;image</code>, <code>&#8209;&#8209;structureimage</code>, <code>&#8209;&#8209;type</code>, <code>&#8209;&#8209;scale</code>, <code>&#8209;&#8209;width</code>, <code>&#8209;&#8209;height</code>, <code>&#8209;&#8209;imagecolour</code>, <code>&#8209;&#8209;bgcolour</code>, <code>&#8209;&#8209;textrenderer</code>, <code>&#8209;&#8209;overwrite</code>, <code>&#8209;&#8209;backups</code>, <code>&#8209;&#8209;mkdirs</code>)</h2>
 
   <p>
   You can save an alignment as an alignment file, or exported as an image, in different formats.  Jalview's alignment output formats are:
   In bitmap formats (currently only PNG, but what else would you want?!) you can specify a scaling factor to improve the resolution of the output image.
   </p>
 
-  <h3><a name="output"></a><code>--output</code></h3>
+  <h3><a name="output"></a><code>&#8209;&#8209;output</code></h3>
 
   <p>
-  To save the open alignment in a new alignment file use <code>--output filename</code>.  The format for the file can be found from the extension of <code>filename</code>, or if you are using a non-standard extension you can use a following <code>--format</code> argument, or specify it as a sub-value modifier.
+  To save the open alignment in a new alignment file use <code>&#8209;&#8209;output filename</code>.  The format for the file can be found from the extension of <code>filename</code>, or if you are using a non-standard extension you can use a following <code>&#8209;&#8209;format</code> argument, or specify it as a sub-value modifier.
   </p>
   <p>
   Recognised formats and their recognised extensions are:
   <code>phylip</code> (<code>phy</code>),
   <br/>
   <code>jalview</code> (<code>jvp, jar</code>).
+  </p>
   <p>
   For example, to open a FASTA file, append another FASTA file and then save the concatenation as a Stockholm file, do
   <pre>
   </p>
 
   <p>
-  <em>Important!</em> If you use <code>--output</code> or any other argument that outputs a file, then it will be assumed you want to run Jalview in headless mode (as if you had specified <code>--headless</code>).  To use Jalview with <code>--output</code> and not assume headless mode, use the <code>--gui</code> or <code>--noheadless</code> argument (the order doesn't matter).
+  <em>Important!</em> If you use <code>&#8209;&#8209;output</code> or any other argument that outputs a file, then it will be assumed you want to run Jalview in headless mode (as if you had specified <code>&#8209;&#8209;headless</code>).  To use Jalview with <code>&#8209;&#8209;output</code> and not assume headless mode, use the <code>&#8209;&#8209;gui</code> argument (the order doesn't matter).
   </p>
 
-  <h3><a name="format"></a><code>--format</code></h3>
+  <p>
+  If you would like to output an alignment file directly to standard output (often referred to as STDOUT), then use the filename <code>-</code> (a single hyphen).  In this case any messages that would normally appear on STDOUT will be diverted to STDERR to avoid invalidating the output file.
+  </p>
+  <p>
+  For example, to open a Stockholm file and pipe it to another command as a Block file, do
+  <pre>
+  jalview --open alignment1.stk --output - --format blc | another_command
+  </pre>
+  or equivalently
+  <pre>
+  jalview alignment1.stk --output=[format=blc]- | another_command
+  </pre>
+  </p>
+
+  <h3><a name="format"></a><code>&#8209;&#8209;format</code></h3>
 
   <p>
-  To specify the format of the output file (if using an unrecognised file extension) use the <code>--format</code> argument to specify a value (see above).  A sub-value modifier on the <code>--output</code> value can also be used.
+  To specify the format of the output file (if using an unrecognised file extension) use the <code>&#8209;&#8209;format</code> argument to specify a value (see above).  A sub-value modifier on the <code>&#8209;&#8209;output</code> value can also be used.
+  </p>
+
+  <h3><a name="image"></a><code>&#8209;&#8209;image</code></h3>
+  <p>
+  To export the open alignment window as an image, use the <code>&#8209;&#8209;image</code> argument, which will give an image of the alignment and annotations as it appears (or would appear if not in <code>&#8209;&#8209;headless</code> mode) in the alignment window if it was large enough for the whole alignment, including colour scheme and features.
+  </p>
+  <p>
+  <pre>
+  jalview --open examples/plantfdx.fa --colour gecos-blossom --features examples/plantfdx.features --annotations examples/plantfdx.annotations --image plantfdx.png --headless
+  </pre>
   </p>
 
-  <h3><a name="image"></a><code>--image</code></h3>
-  To export the open alignment window as an image, use the <code>--image</code> argument, which will give an image of the alignment and annotations as it appears (or would appear if not in <code>--headless</code> mode) in the alignment window if it was large enough for the whole alignment, including colour choice and features.
+  <h3><a name="structureimage"></a><code>&#8209;&#8209;structureimage</code></h3>
+  <p>
+  To export an open structure as an image, use the <code>&#8209;&#8209;structureimage</code> argument, which will give an image of the structure as it appears (or would appear if not in <code>&#8209;&#8209;headless</code> mode) in a Jmol window including colour scheme. <code>&#8209;&#8209;structureimage</code> can currently only be used with structures opened with the <code>jmol</code> structureviewer (the default viewer).
+  </p>
   <p>
   <pre>
   jalview --open examples/plantfdx.fa --colour gecos-blossom --features examples/plantfdx.features --annotations examples/plantfdx.annotations --image plantfdx.png --headless
   </p>
 
   <p>
-  This by default produces a PNG image of screen or webpage resolution, which you may want to improve upon.  There are two ways of doing this with Jalview: increasing the scale of the PNG image, or using a vector based image format (EPS, SVG, HTML).
+  These by default produce a PNG image of screen or webpage resolution, which you will probably want to improve upon.  There are two ways of doing this with Jalview: increasing the scale of the PNG image, or using a vector based image format (EPS, SVG, HTML).
   <p>
 
+  <h3><a name="type"></a><code>&#8209;&#8209;type</code></h3>
+
+  <p>
+  To specify the type of image file to write (if using an unrecognised file extension) use the <code>&#8209;&#8209;type</code> argument to specify a value (see above).  A sub-value modifier on the <code>&#8209;&#8209;image</code> and <code>&#8209;&#8209;structureimage</code> value can also be used.  Valid values are:
+  <br/>
+  <code>png</code> - A Portable Network Graphics image (bitmap, default),
+  <br/>
+  <code>svg</code> - A Scalable Vector Graphics image (vector),
+  <br/>
+  <code>eps</code> - An Encapsulated PostScript file (vector),
+  <br/>
+  <code>html</code> - An HTML rendition of the alignment with embedded source data (vector/web browser),
+  <br/>
+  <code>biojs</code> - An HTML rendition of the alignment with interactive MSA viewer <a href="biojsmsa.html">BioJS-MSA</a> (vector).
+  </p>
+
   <h3><a name="bitmap"></a>Bitmap image types (<code>png</code>)</h3>
 
   <p>
   Let's increase the resolution of the PNG image:
   </p>
 
-  <h3><a name="scale"></a><code>--scale</code></h3>
+  <h3><a name="scale"></a><code>&#8209;&#8209;scale</code></h3>
 
   <p>
-  We can increase the size of the PNG image by a factor of <em>S</em> by following the <code>--image</code> argument with a <code>--scale <em>S</em></code> argument and value.  The value doesn't have to be an integer and should be given as an integer or floating point formatted number, e.g.
+  We can increase the size of the PNG image by a factor of <em>S</em> by following the <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> argument with a <code>&#8209;&#8209;scale <em>S</em></code> argument and value.  The value doesn't have to be an integer and should be given as an integer or floating point formatted number, e.g.
   <pre>
   jalview --open examples/uniref50.fa --colour gecos-ocean --image mypic.png --scale 5.5 --headless
   </pre>
-  which will produce a PNG image 5.5 times larger (and more detailed) than without the <code>--scale</code> argument.
+  which will produce a PNG image 5.5 times larger (and more detailed) than without the <code>&#8209;&#8209;scale</code> argument.
   </p>
   <p>
   However, since you won't necessarily already know the size of an alignment's exported image you can specify either an exact width or height (in pixels) with either one of the
-  <code>--width</code> and <code>--height</code> arguments:
+  <code>&#8209;&#8209;width</code> and <code>&#8209;&#8209;height</code> arguments:
 
-  <h3><a name="width"></a><code>--width</code></h3>
+  <h3><a name="width"></a><code>&#8209;&#8209;width</code></h3>
 
   <p>
-  Specify an exact width of an exported PNG image with <code>--width</code>:
+  Specify an exact width of an exported PNG image with <code>&#8209;&#8209;width</code>:
   <pre>
   jalview --headless --open https://www.ebi.ac.uk/interpro/api/entry/pfam/PF03760/?annotation=alignment%3Aseed --noshowannotations --colour gecos-sunset --image wallpaper.png --width 3840
   </pre>
   </p>
 
-  <h3><a name="height"></a><code>--height</code></h3>
+  <h3><a name="height"></a><code>&#8209;&#8209;height</code></h3>
 
   <p>
-  Alternatively specify an exact height with the <code>--height</code> argument:
+  Alternatively specify an exact height with the <code>&#8209;&#8209;height</code> argument:
   <pre>
   jalview --headless --open https://www.ebi.ac.uk/interpro/api/entry/pfam/PF03760/?annotation=alignment%3Aseed --noshowannotations --colour gecos-ocean --image wallpaper.png --height 2160
   </pre>
   </p>
 
   <p>
-  You can specify two or all of <code>--scale</code>, <code>--width</code> and <code>--height</code> as limits to the size of the image (think of one or two bounding boxes) and the one which produces the smallest scale of image is used.  You can also specify each of these as sub-value modifiers to the <code>--image</code> value:
+  You can specify two or all of <code>&#8209;&#8209;scale</code>, <code>&#8209;&#8209;width</code> and <code>&#8209;&#8209;height</code> as limits to the size of the image (think of one or two bounding boxes) and the one which produces the smallest scale of image is used.  You can also specify each of these as sub-value modifiers to the <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> value:
   <pre>
   jalview --headless --open https://www.ebi.ac.uk/interpro/api/entry/pfam/PF03760/?annotation=alignment%3Aseed --noshowannotations --colour gecos-flower --image [scale=0.25,width=320,height=240]thumbnail.png
   </pre>
   </p>
 
+  <h3><a name="imagecolour"></a><code>&#8209;&#8209;imagecolour</code></h3>
+
+  <p>
+  Specify a colour scheme to use just for this image using the <code>&#8209;&#8209;imagecolour</code> argument:
+  <pre>
+  jalview --open examples/uniref50.fa --colour gecos-flower --image uniref50-residues.png --height 2160 --image uniref50-helix.png --imagecolour helix-propensity --width 800 --image uniref50-turn.png --imagecolour turn-propensity --width 800
+  </pre>
+  </p>
+
+  <h3><a name="bgcolour"></a><code>&#8209;&#8209;bgcolour</code></h3>
+
+  <p>
+  <strong>Only applies to <code>&#8209;&#8209;structureimage</code>.</strong> Specify a background colour for a structure image.  The colour can be specified as a named colour recognised by Java (e.g. <code>"white"</code>, <code>"cyan"</code>) or as a RRGGBB 6 digit hex string (e.g. <code>ffffff</code>, <code>00ffff</code>).
+  </p>
+  <p>
+  E.g.
+  <pre>
+  jalview --open examples/uniref50.fa --colour gecos-sunset --structure examples/AF-P00221-F1-model_v4.pdb --seqid FER1_SPIOL --structureimage temp.png  --bgcolour magenta
+  </pre>
+  </p>
+
   <p>
   Next we look at vector image formats, which maintain detail at all resolutions.
   </p>
 
-  <h3><a name="vector"></a>Vector image export</h3>
+  <h3><a name="vector"></a>Vector image export (<code>svg</code>, <code>eps</code>, <code>html</code>, <code>biojs</code>)</h3>
 
   <p>
-  Jalview can export an alignment in Encapsulated PostScript (<code>eps</code>), Scalable Vector Graphics (<code>svg</code>), HTML (<code>html</code>) or BioJSON -- another HTML format (<code>biojs</code>), by using, e.g.
+  Jalview can export an alignment in Encapsulated PostScript (<code>eps</code>), Scalable Vector Graphics (<code>svg</code>), HTML (<code>html</code>) or <a href="biojsmsa.html">BioJSON</a> -- another HTML format with an interactive MSA viewer (<code>biojs</code>), by using, e.g.
   <pre>
   jalview --open examples/uniref50.fa --colour gecos-flower --image printable.eps
   </pre>
-  The image format can be specified with the <code>--type</code> argument or as a sub-value modifier on the <code>--image</code> value.  If neither is used the <code>type</code> will be guessed from the image file extension.  The following three examples should produce the same contents:
+  The image format can be specified with the <code>&#8209;&#8209;type</code> argument or as a sub-value modifier on the <code>&#8209;&#8209;image</code> value.  If neither is used the <code>type</code> will be guessed from the image file extension.  The following three examples should produce the same contents:
   <pre>
   jalview --open examples/uniref50.fa --colour gecos-flower --image printable.eps
   jalview --open examples/uniref50.fa --colour gecos-flower --image printable.postscript --type eps
   jalview --open examples/uniref50.fa --colour gecos-flower --image [type=eps]printable.postscript
+  jalview --open examples/uniref50.fa --colour gecos-flower --image [type=biojs]printable.html
   </pre>
   </p>
 
-  <h3><a name="textrenderer"></a><code>--textrenderer</code></h3>
+  <h3><a name="textrenderer"></a><code>&#8209;&#8209;textrenderer</code></h3>
 
   <p>
-  In a vector format any text that appears on the page (including residue/base labels) can be saved in the image file either as <code>text</code> or as <code>lineart</code> using the <code>--textrenderer</code> argument.  This is only available for <code>eps</code>, <code>svg</code> and <code>html</code> formats.
+  In a vector format any text that appears on the page (including residue/base labels) can be saved in the image file either as <code>text</code> or as <code>lineart</code> using the <code>&#8209;&#8209;textrenderer</code> argument.  This is only available for <code>eps</code>, <code>svg</code> and <code>html</code> formats.
   </p>
 
   <p>
   </p>
 
   <p>
-  The type of <code>--textrenderer</code> can be specified with an argument following <code>--image</code> or as a sub-value modifier:
+  The type of <code>&#8209;&#8209;textrenderer</code> can be specified with an argument following <code>&#8209;&#8209;image</code> or as a sub-value modifier:
   <pre>
   jalview --open examples/uniref50.fa --colour gecos-flower --image printable.html --type biojs
   jalview --open examples/uniref50.fa --colour gecos-flower --image [type=eps,textrenderer=lineart]printable.ps
   </pre>
   </p>
 
+  <h3><a name="outputbehaviour"></a>Output behaviour</h3>
 
-  <h2><a name="filenamesubstitutionsandbatchprocessing"></a>Filename substitutions and batch processing (<code>--substitutions</code>, <code>--close</code>, <code>--all</code>)</h2>
+  <h3><a name="overwrite"></a><code>&#8209;&#8209;overwrite</code></h3>
+
+  <p>
+  By default, Jalview will refuse to overwrite an output file (alignment or image) unless backups are in operation (alignment files only).  To force overwriting files, use the <code>&#8209;&#8209;overwrite</code> argument.
+  </p>
+
+  <h3><a name="backups"></a><code>&#8209;&#8209;backups / --nobackups</code></h3>
+
+  <p>
+  Jalview should honour your preferences for backup files of output alignment files.  Using <code>&#8209;&#8209;backups</code> or <code>&#8209;&#8209;nobackups</code> forces the behaviour.  With no backups set, you will need to use <code>&#8209;&#8209;overwrite</code> to overwrite an existing file.  Note that Jalview does not make backup files of exported images.
+  </p>
+
+  <h3><a name="mkdirs"></a><code>&#8209;&#8209;mkdirs</code></h3>
+
+  <p>
+  If you want to output a file into a folder that doesn't yet exist (this might happen particularly when using <code>{dirname}</code> substitutions -- see below), then Jalview will fail to write the file since the parent directory doesn't exist.  You can use <code>&#8209;&#8209;mkdirs</code> to tell Jalview to make the new directory (or directories, it will create several nested directories if necessary) before writing the file.  <code>&#8209;&#8209;mkdirs</code> is cautious and will generally refuse to make a new directory using a relative path with <code>..</code> in.
+  </p>
+
+  <h2><a name="filenamesubstitutionsandbatchprocessing"></a>Filename substitutions and batch processing (<code>&#8209;&#8209;substitutions</code>, <code>&#8209;&#8209;close</code>, <code>&#8209;&#8209;all</code>)</h2>
 
   <p>
   One of the more powerful aspects of Jalview's command line operations is that stores all of the different opened alignment arguments (before opening them) and can apply some arguments to <em>all</em> of the alignments as they are opened.  This includes display and output arguments.
   </p>
 
   <p>
+  Specifically for <code>&#8209;&#8209;structureimage</code> output, you can also use substitutions using parts of the structure filename:
+  <ul>
+  <li><code>{structuredirname}</code> -- is replaced by the directory path to the opened structure file.</li>
+  <li><code>{structurebasename}</code> -- is replaced by the base of the filename of the opened structure file. This is without the path or file extension (if there is one).</li>
+  <li><code>{structureextension}</code> -- is replaced by the extension of the filename of the opened structure file.</li>
+  </ul>
+  </p>
+
+  <p>
   These filename substitutions are on by default, but if for whatever reason you wish to disable the substitutions, they can be turned off (or back on again) through the list of arguments with:
   </p>
 
-  <h3><a name="substitutions"></a><code>--substitutions / --nosubstitutions</code></h3>
+  <h3><a name="substitutions"></a><code>&#8209;&#8209;substitutions / --nosubstitutions</code></h3>
 
   <p>
   Enable (or disable) filename substitutions in the following argument values and sub-value modifier values.
   </p>
 
   <p>
-  For opening single files this is less useful, since you could obviously just type the output filename, but for multiple opened alignments you can also use these substituted values and they will be replaced by the relevant part of the filename given for each opened alignment window.  Normally an <code>--output</code> or <code>--image</code> argument will only be applied to the latest opened alignment window, but you can tell Jalview to apply some arguments to all alignments that have been opened (so far) by using the <code>--all</code> argument.
+  For opening single files this is less useful, since you could obviously just type the output filename, but for multiple opened alignments you can also use these substituted values and they will be replaced by the relevant part of the filename given for each opened alignment window.  Normally an <code>&#8209;&#8209;output</code> or <code>&#8209;&#8209;image</code> argument will only be applied to the latest opened alignment window, but you can tell Jalview to apply some arguments to all alignments that have been opened (so far) by using the <code>&#8209;&#8209;all</code> argument.
   </p>
 
-  <h3><a name="all"></a><code>--all / -noall</code></h3>
+  <h3><a name="all"></a><code>&#8209;&#8209;all / -noall</code></h3>
 
   <p>
-  When using the <code>--all</code> argument, following arguments will apply to all of the previously opened alignment windows.  You can turn this behaviour off again for following arguments using the <code>--noall</code> argument.  The arguments that can apply to all previously opened alignments are:
+  When using the <code>&#8209;&#8209;all</code> argument, following arguments will apply to all of the previously opened alignment windows.  You can turn this behaviour off again for following arguments using the <code>&#8209;&#8209;noall</code> argument.  The arguments that can apply to all previously opened alignments are:
   <br/>
-  <code>--colour</code>
+  <code>&#8209;&#8209;colour</code>
   <br/>
-  <code>--sortbytree</code>
+  <code>&#8209;&#8209;sortbytree</code>
   <br/>
-  <code>--showannotations</code>
+  <code>&#8209;&#8209;showannotations</code>
   <br/>
-  <code>--wrap</code>
+  <code>&#8209;&#8209;wrap</code>
   <br/>
-  <code>--nostructure</code>
+  <code>&#8209;&#8209;nostructure</code>
   <br/>
-  <code>--notempfac</code>
+  <code>&#8209;&#8209;notempfac</code>
   <br/>
-  <code>--showssannotations</code>
+  <code>&#8209;&#8209;showssannotations</code>
   <br/>
-  <code>--image</code>
+  <code>&#8209;&#8209;image</code>
   <br/>
-  <code>--type</code>
+  <code>&#8209;&#8209;type</code>
   <br/>
-  <code>--textrenderer</code>
+  <code>&#8209;&#8209;textrenderer</code>
   <br/>
-  <code>--scale</code>
+  <code>&#8209;&#8209;scale</code>
   <br/>
-  <code>--width</code>
+  <code>&#8209;&#8209;width</code>
   <br/>
-  <code>--height</code>
+  <code>&#8209;&#8209;height</code>
   <br/>
-  <code>--output</code>
+  <code>&#8209;&#8209;output</code>
   <br/>
-  <code>--format</code>
+  <code>&#8209;&#8209;format</code>
   <br/>
-  <code>--groovy</code>
+  <code>&#8209;&#8209;groovy</code>
   <br/>
-  <code>--backups</code>
+  <code>&#8209;&#8209;backups</code>
   <br/>
-  <code>--overwrite</code>
+  <code>&#8209;&#8209;overwrite</code>
   <br/>
-  <code>--close</code>
+  <code>&#8209;&#8209;close</code>
   </p>
   <p>
-  In particular, for our example above, we can use <code>-all</code> and <code>--output</code> like this (<code>--close</code> will be explained in a moment):
+  In particular, for our example above, we can use <code>-all</code> and <code>&#8209;&#8209;output</code> like this (<code>&#8209;&#8209;close</code> will be explained in a moment):
   <pre>
   jalview --open all_my_fasta_files/*.fa --all --output all_my_converted_stockholm_files/{basename}.stk --close --headless
   </pre>
   </pre>
   </p>
 
-  <h3><a name="close"></a><code>--close</code></h3>
+  <h3><a name="close"></a><code>&#8209;&#8209;close</code></h3>
 
   <p>
-  The <code>--close</code> tag is used to close an alignment window after all output files or image exports are performed.  This reduces memory use, especially if an <code>--open</code> value is set to open many files.  These will be opened, formatted and output sequentially so since they are closed before the next one is opened memory use will not build up over a large number of alignments.
+  The <code>&#8209;&#8209;close</code> tag is used to close an alignment window after all output files or image exports are performed.  This reduces memory use, especially if an <code>&#8209;&#8209;open</code> value is set to open many files.  These will be opened, formatted and output sequentially so since they are closed before the next one is opened memory use will not build up over a large number of alignments.
   <pre>
   </pre>
   </p>
 
 
-  <h2><a name="alloutputwildcard"></a>The all output wildcard: <code>--output "*.ext"</code>,  <code>--image "*.ext"</code></h2>
+  <h2><a name="alloutputwildcard"></a>The all output wildcard: <code>&#8209;&#8209;output "*/*.ext"</code>,  <code>&#8209;&#8209;image "*/*.ext"</code></h2>
+
+  <p>
+  Purely as an intuitive syntactic sweetener, you can use the <code>&#8209;&#8209;output</code> wildcard <code>*</code> in two places as part of an output path and filename.
+  </p>
+
+  <p>
+  Using an asterisk (<code>*</code>) as a filename before an extension, e.g. <code>&#8209;&#8209;image "tmp/*.png"</code> will result in that asterisk being treated as a <code>{basename}</code> substitution.
+  </p>
+
+  <p>
+  Using an asterisk (<code>*</code>) before a file separator (usually </code>/</code>), e.g. <code>&#8209;&#8209;image "tmp/*/file1.png"</code> will result in that asterisk being treated as a <code>{dirname}</code> substitution.
+  </p>
+
+  <p>
+  You can combine these, using an asterisk (<code>*</code>) before and after the last file separator, e.g. <code>&#8209;&#8209;image "tmp/*/*.png"</code> will result in being substituted like <code>tmp/{dirname}/{basename}.png</code>.
+  </p>
 
   <p>
-  Purely as an intuitive syntactic sweetener, you can use the <code>--output</code> wildcard <code>*</code> <em>at the beginning of the output filename</em> as shorthand for <code>--all --output {dirname}/{basename}</code> followed by whatever you put after the '<code>*</code>'.  For example, to achieve the same as the thumbnails example above, you could use
+  For example, to achieve the same as the thumbnails example above, you could use
   <pre>
-  jalview --open */*.fa --image "*.png" --colour gecos-flower --width 256 --height 256 --close --headless
+  jalview --open */*.fa --image "*/*.png" --colour gecos-flower --width 256 --height 256 --close --headless
   </pre>
-  Here we move the <code>--colour</code> argument after the <code>--output</code> argument (it will still be applied before the image export or file output) so that it is included after the implied <code>--all</code> argument.  The thumbnails will be placed in the same directory as the alignment file with the same filename except for a different extension of <code>.png</code>.
+  Here we move the <code>&#8209;&#8209;colour</code> argument after the <code>&#8209;&#8209;output</code> argument (it will still be applied before the image export or file output) so that it is included after the implied <code>&#8209;&#8209;all</code> argument.  The thumbnails will be placed in the same directory as the alignment file with the same filename except for a different extension of <code>.png</code>.
   </p>
 
   <p>
   </p>
 
   <p>
-  An alternative is to use an equals sign ('=') with no spaces between the argument and the value, <code>--output=*.ext</code>, which Jalview will interpret the same, but the shell will not automatically expand before it is sent to Jalview, e.g.
+  An alternative is to use an equals sign ('=') with no spaces between the argument and the value, <code>&#8209;&#8209;output=*.ext</code>, which Jalview will interpret the same, but the shell will not automatically expand before it is sent to Jalview, e.g.
   <pre>
   jalview --open all_my_fasta_files/*.fa --output=*.stk --close --headless
   </pre>
index dd0bd52..b1588e5 100644 (file)
@@ -35,7 +35,6 @@
   <li><a href="#processingalignments">Processing alignments</a></li>
   <li><a href="#outputtingalignmentfiles">Outputting alignment files</a></li>
   <li><a href="#exportingimagefiles">Exporting image files</a></li>
-  <li><a href="#exporting3dstructureimagefiles">Exporting 3D structure image files</a></li>
   <li><a href="#controllingflowofarguments">Controlling flow of arguments</a></li>
   </ul>
 
     <tr valign="top"><td><code>&#8209;&#8209;help&#8209;all</code></td><td>Help for all arguments</td></tr>
 
     <tr valign="top">
-    <td><code>&#8209;&#8209;headless / &#8209;&#8209;noheadless</code></td>
-    <td>Run Jalview in headless (/ or not in headless) mode.  In headless mode, no GUI interface will be created and Jalview will quit after all arguments have been processed.
+    <td><code>&#8209;&#8209;headless</code></td>
+    <td>Run Jalview in headless mode.  In headless mode, no GUI interface will be created and Jalview will quit after all arguments have been processed.
     <br/>
-    If you use a command line argument to specify an output file of some kind (<code>--output</code>, <code>--image</code> or <code>--structureimage</code>) then <strong>headless mode will be assumed</strong>.  If you don't want this behaviour use <code>--noheadless</code> or <code>--gui</code>.
+    If you use a command line argument to specify an output file of some kind (<code>&#8209;&#8209;output</code>, <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code>) then <strong>headless mode will be assumed</strong>.  If you don't want this behaviour use <code>&#8209;&#8209;gui</code>.
     </td>
     </tr>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;gui</code></td>
-    <td>Force Jalview to run in graphical mode.  This can be used to counter the assumption of headless mode when an argument that creates an output file is used.  <code>--gui</code> takes precedence over <code>--headless</code>.</td>
+    <td>Force Jalview to run in graphical mode.  This can be used to counter the assumption of headless mode when an argument that creates an output file is used.  <code>&#8209;&#8209;gui</code> takes precedence over <code>&#8209;&#8209;headless</code>.</td>
     </tr>
 
     <tr valign="top">
     </tr>
 
     <tr valign="top">
+    <td><code>&#8209;&#8209;javaconsole / &#8209;&#8209;nojavaconsole</code></td>
+    <td>Show (/ or don't show) the Java Console.  Using one of these overrides any saved Preference.</td>
+    </tr>
+
+    <tr valign="top">
     <td><code>&#8209;&#8209;questionnaire / &#8209;&#8209;noquestionnaire</code></td>
     <td>Show (/ or don't show) the questionnaire if one is available.</td>
     </tr>
     <code>phylip</code> (<code>phy</code>),
     <br/>
     <code>jalview</code> (<code>jvp, jar</code>).
+    <br/>
+    To output directly to STDOUT (console output) use the filename <code>-</code> (a single hyphen).  In this case all STDOUT messages will instead go to STDERR.  If no <code>format</code> is supplied then Fasta will be assumed.
     </td>
     <td><code>format=<em>name</em></code></td>
     <td align="center">&#x2713;</td>
     <td align="center">&#x2713;</td>
     </tr>
 
+    <tr valign="top">
+    <td><code>&#8209;&#8209;mkdirs</code></td>
+    <td>Enable automatic creation of new directories and parent directories for filenames given, or created through substitutions, in <code>&#8209;&#8209;output</code>, <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> arguments.
+    <td></td>
+    <td align="center">&#x2713;</td>
+    </tr>
+
+
+
+Automatically create directories when outputting a file to a new directory
   </table>
 
 
     <code>biojs</code>.
     </td>
     <td>
-      <code>type=<em>name</em>,
-      <code>textrenderer=<em>name</em>,
-      <code>scale=<em>number</em>,
-      <code>width=<em>number</em>,
-      <code>height=<em>number</em>
+      <code>
+      type=<em>name</em>,
+      <br/>
+      textrenderer=<em>name</em>,
+      <br/>
+      scale=<em>number</em>,
+      <br/>
+      width=<em>number</em>,
+      <br/>
+      height=<em>number</em>,
+      <br/>
+      imagecolour=<em>name</em>
+      </code>
+    </td>
+    <td align="center">&#x2713;</td>
+    </tr>
+
+    <tr valign="top">
+    <td><code>&#8209;&#8209;structureimage&nbsp;<em>filename</em></code></td>
+    <td>Export an image of a 3D structure opened in JMOL (currently jmol only).  Each <code>&#8209;&#8209;structureimage</code> filename will output a file for each <code>&#8209;&#8209;structureimage</code> that has been applied to the open alignment window.  In this situation, to avoid overwriting the same file with each structure, additional substitutions <code>{structuredirname}</code>, <code>{structurebasename}</code> and <code>{structureextname}</code> are available being substituted with the directory path, file basename and file extension of each structure file.    Image formats can be:
+    <br/>
+    <code>svg</code>,
+    <br/>
+    <code>png</code>,
+    <br/>
+    <code>eps</code>.
+    </td>
+    <td>
+      <code>
+      type=<em>name</em>,
+      <br/>
+      textrenderer=<em>name</em>,
+      <br/>
+      scale=<em>number</em>,
+      <br/>
+      width=<em>number</em>,
+      <br/>
+      height=<em>number</em>,
+      <br/>
+      imagecolour=<em>name</em>
+      <br/>
+      bgcolour=<em>name</em>
+      </code>
     </td>
     <td align="center">&#x2713;</td>
     </tr>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;type&nbsp;<em>name</em></code></td>
-    <td>Set the image format for the preceding <code>&#8209;&#8209;image</code> to <em>name</em>.  Valid values for <em>name</em> are:
+    <td>Set the image format for the preceding <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> to <em>name</em>.  Valid values for <em>name</em> are:
     <br/>
     <code>svg</code>,
     <br/>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;textrenderer&nbsp;<em>name</em></code></td>
-    <td>Sets whether text in a vector image format (SVG, HTML, EPS) should be rendered as text or vector line-art.  Valid values for <em>name</em> are:
+    <td>Sets whether text in a vector image format (SVG, HTML, EPS) should be rendered as text or vector line-art.  Applies to the preceding <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code>.  Valid values for <em>name</em> are:
     <br/>
     <code>text</code>,
     <br/>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;scale&nbsp;<em>number</em></code></td>
-    <td>Sets a scaling for bitmap image format (PNG).  Should be given as a floating point number.  This can also be set as a sub-value modifier to the <code>--image</code> value.  If used in conjunction with <code>--width</code> and <code>--height</code> then the smallest scaling will be used (<code>scale</code>, <code>width</code> and <code>height</code> provide bounds for the image).
+    <td>Sets a scaling for bitmap image format (PNG).  Should be given as a floating point number.  Applies to the preceding <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code>.  This can also be set as a sub-value modifier to the <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> value.  If used in conjunction with <code>&#8209;&#8209;width</code> and <code>&#8209;&#8209;height</code> then the smallest size will be used (<code>scale</code>, <code>width</code> and <code>height</code> provide bounds for the image).
     </td>
     <td></td>
     <td align="center">&#x2713;</td>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;width&nbsp;<em>number</em></code></td>
-    <td>Sets a width for bitmap image format (PNG) with the height maintaining the aspect ratio.  Should be given as a positive integer.  This can also be set as a sub-value modifier to the <code>--image</code> value.  If used in conjunction with <code>--scale</code> and <code>--height</code> then the smallest scaling will be used (<code>scale</code>, <code>width</code> and <code>height</code> provide bounds for the image).
+    <td>Sets a width for bitmap image format (PNG) with the height maintaining the aspect ratio.  Applies to the preceding <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code>.  Should be given as a positive integer.  This can also be set as a sub-value modifier to the <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> value.  If used in conjunction with <code>&#8209;&#8209;scale</code> and <code>&#8209;&#8209;height</code> then the smallest size will be used (<code>scale</code>, <code>width</code> and <code>height</code> provide bounds for the image).
     </td>
     <td></td>
     <td align="center">&#x2713;</td>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;height&nbsp;<em>number</em></code></td>
-    <td>Sets a height for bitmap image format (PNG) with the width maintaining the aspect ratio.  Should be given as a positive integer.  This can also be set as a sub-value modifier to the <code>--image</code> value.  If used in conjunction with <code>--scale</code> and <code>--width</code> then the smallest scaling will be used (<code>scale</code>, <code>width</code> and <code>height</code> provide bounds for the image).</td>
+    <td>Sets a height for bitmap image format (PNG) with the width maintaining the aspect ratio.  Applies to the preceding <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code>.  Should be given as a positive integer.  This can also be set as a sub-value modifier to the <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code> value.  If used in conjunction with <code>&#8209;&#8209;scale</code> and <code>&#8209;&#8209;width</code> then the smallest size will be used (<code>scale</code>, <code>width</code> and <code>height</code> provide bounds for the image).</td>
     <td></td>
     <td align="center">&#x2713;</td>
     </tr>
 
     <tr valign="top">
-    <td><code>&#8209;&#8209;groovy&nbsp;<em>filename</em></code></td>
-    <td>Process a groovy script in the file for the open alignment.</td>
+    <td><code>&#8209;&#8209;bgcolour&nbsp;<em>name</em></code></td>
+    <td>Only applies to structure images (opened with <code>jmol</code> structure viewer).  Sets the background colour of the preceding <code>&#8209;&#8209;structureimage</code>.  <em>name</em> should be either a named colour (e.g. <code>white</code>, <code>cyan</code>) known to Jmol, or can be given as a six digit RGB hex string (e.g. <code>ffffff</code>, <code>00ffff</code>).  This can also be set as a sub-value modifier to the <code>&#8209;&#8209;structureimage</code> value.</td>
     <td></td>
     <td align="center">&#x2713;</td>
     </tr>
 
-  </table>
-
-
-  <h2><a name="exporting3dstructureimagefiles"></a>Exporting 3D structure image files (<code>jmol</code> only)</h2>
-
-  <table border="1" cellpadding="3">
-    <tr valign="top">
-    <td><strong>argument</strong></td>
-    <td><strong>action</strong></td>
-    <td><strong>sub-value modifiers</strong> (optional)</td>
-    <td><strong>linked</strong> (optional)</td>
-    </tr>
-
     <tr valign="top">
-    <td><code>&#8209;&#8209;structureimage&nbsp;<em>filename</em></code></td>
-    <td>Export an image of a 3D structure opened in JMOL.  Image formats can be:
-    <br/>
-    <code>svg</code>,
-    <br/>
-    <code>png</code>,
-    <br/>
-    <code>eps</code>.
-    </td>
-    <td>
-      <code>structureimagetype=<em>name</em>,
-      <code>structureimagetextrenderer=<em>name</em>,
-      <code>structureimagescale=<em>number</em>,
-      <code>structureimagewidth=<em>number</em>,
-      <code>structureimageheight=<em>number</em>
-    </td>
-    <td align="center">&#x2713;</td>
-    </tr>
-
-    <tr valign="top">
-    <td><code>&#8209;&#8209;structureimagetype&nbsp;<em>name</em></code></td>
-    <td>Set the structure image format for the preceding --structureimage. Valid values are:
-    <br/>
-    <code>svg</code>,
-    <br/>
-    <code>png</code>,
-    <br/>
-    <code>eps</code>.
-    </td>
-    <td></td>
-    <td align="center">&#x2713;</td>
-    </tr>
-
-    <tr valign="top">
-    <td><code>&#8209;&#8209;structureimagetextrenderer&nbsp;<em>name</em></code></td>
-    <td>Sets whether text in a vector structure image format (SVG, EPS) should be rendered as text or vector line-art. Possible values are:
-    <br/>
-    <code>text</code>,
-    <br/>
-    <code>lineart</code>.
-    </td>
-    <td></td>
-    <td align="center">&#x2713;</td>
-    </tr>
-
-    <tr valign="top">
-    <td><code>&#8209;&#8209;structureimagescale&nbsp;<em>number</em></code></td>
-    <td>Sets a scaling for bitmap structure image format (PNG). Should be given as a floating point number. If used in conjunction with --structureimagewidth and --structureimageheight then the smallest scaling will be used (structureimagescale, structureimagewidth and structureimageheight provide bounds for the structure image).
-    </td>
-    <td></td>
-    <td align="center">&#x2713;</td>
-    </tr>
-
-    <tr valign="top">
-    <td><code>&#8209;&#8209;structureimagewidth&nbsp;<em>number</em></code></td>
-    <td>Sets a width for bitmap structure image format (PNG) with the height maintaining the aspect ratio. Should be given as a positive integer. If used in conjunction with --structureimagescale and --structureimageheight then the smallest scaling will be used (structureimagescale, structureimagewidth and structureimageheight provide bounds for the structure image).
-    </td>
-    <td></td>
-    <td align="center">&#x2713;</td>
-    </tr>
-
-    <tr valign="top">
-    <td><code>&#8209;&#8209;structureimageheight&nbsp;<em>number</em></code></td>
-    <td>Sets a height for bitmap structure image format (PNG) with the width maintaining the aspect ratio. Should be given as a positive integer. If used in conjunction with --structureimagescale and --structureimagewidth then the smallest scaling will be used (structureimagescale, structureimagewidth and structureimageheight provide bounds for the structure image).
-    </td>
+    <td><code>&#8209;&#8209;groovy&nbsp;<em>filename</em></code></td>
+    <td>Process a groovy script in the file for the open alignment.</td>
     <td></td>
     <td align="center">&#x2713;</td>
     </tr>
     <td>
     Move on to a new alignment window.  This will ensure <code>&#8209;&#8209;append</code> will start a new alignment window and other linked arguments will apply to the new alignment window.
     <br/>
-    <em>Note</em> that <code>--open</code> already starts a new alignment window for each file it opens.
+    <em>Note</em> that <code>&#8209;&#8209;open</code> already starts a new alignment window for each file it opens.
     </td>
     </tr>
 
     <tr valign="top">
     <td><code>&#8209;&#8209;substitutions / &#8209;&#8209;nosubstitutions</code></td>
     <td>The following argument values allow (or don't allow) subsituting filename parts.  This is initially true.  Valid substitutions are
+    <br/>
     <code>{basename}</code> - the filename-without-extension of the currently <code>&#8209;&#8209;open</code>ed file (or first <code>&#8209;&#8209;append</code>ed file),
     <br/>
     <code>{dirname}</code>, - the directory (folder) name of the currently <code>&#8209;&#8209;open</code>ed file (or first <code>&#8209;&#8209;append</code>ed file),
+    <code>{extension}</code>, - the extension of the filename of the currently <code>&#8209;&#8209;open</code>ed file (or first <code>&#8209;&#8209;append</code>ed file),
     <br/>
     <code>{argfilebasename}</code> - the filename-without-extension of the current <code>&#8209;&#8209;argfile</code>,
     <br/>
     <code>{argfiledirname}</code> - the directory (folder) name of the current <code>&#8209;&#8209;argfile</code>,
     <br/>
+    <code>{structurebasename}</code> - the filename-without-extension of the <code>&#8209;&#8209;structure</code> file.  Only available to <code>&#8209;&#8209;structureimage</code> .
+    <br/>
+    <code>{structuredirname}</code>, - the directory (folder) name of the <code>&#8209;&#8209;structure</code> file.  Only available to <code>&#8209;&#8209;structureimage</code> .
+    <br/>
+    <code>{structureextension}</code>, - the extension of the filename of the <code>&#8209;&#8209;structure</code> file.  Only available to <code>&#8209;&#8209;structureimage</code> .
+    <br/>
     <code>{n}</code> - the value of the index counter (starting at 0).
     <br/>
-    <code>{++n}</code> - increase and substitute the value of the index counter,
+    <code>{++n}</code> - increase and substitute the value of the index counter.
+    <br/>
+    <code>{m}</code> - the value of the on-the-fly counter (starting at 0).  Only available to <code>&#8209;&#8209;structureimage</code> .
+    <br/>
+    <code>{++m}</code> - increase and substitute the (incremented) value of the on-the-fly counter.  Only available to <code>&#8209;&#8209;structureimage</code> .
     <br/>
     <code>{}</code> - the value of the current alignment window <em>default</em> index.
     </td>
     <tr valign="top">
     <td><code>&#8209;&#8209;allstructures / &#8209;&#8209;noallstructures</code></td>
     <td>
-        Apply (or stop applying) the following 3D structure formatting arguments to all structures <em>within the current open alignment</em>.  Whilst <code>--allstructures</code> will continue to operate for a <code>--new</code> alignment, the structure formatting arguments must be set again for each new alignment.
+        Apply (or stop applying) the following 3D structure formatting arguments to all structures <em>within the current open alignment</em>.  Whilst <code>&#8209;&#8209;allstructures</code> will continue to operate for a <code>&#8209;&#8209;new</code> alignment, the structure formatting arguments must be set again for each new alignment.
     </td>
     </tr>
 
index b763a81..6df40b5 100644 (file)
@@ -44,7 +44,7 @@
   </p>
 
   <p>
-  These new arguments are all accessed with a <code>--doubledash</code> form of
+  These new arguments are all accessed with a <code>&#8209;&#8209;doubledash</code> form of
   command line argument (with the one exception where simply opening one or more
   files can be performed without any arguments other than the filenames).
   </p>
@@ -60,7 +60,7 @@
   <p>
   However, you cannot mix old and new style arguments, so if you use any
   <code>-singledash</code> arguments (with the exception of <code>-help</code> or <code>-h</code>), they will all be interpreted as
-  old style arguments with the new <code>--doubledash</code>
+  old style arguments with the new <code>&#8209;&#8209;doubledash</code>
   arguments being ignored.  If you have a script
   that uses the old arguments without any dashes, and uses the bare-word
   <code>open</code> then these will also be interpreted as old style arguments.
     <li>
         For arguments that require a value, the value can be given after an equals-sign ('=') or a space (' ').
         <br/>
-        <code>--arg value</code>
+        <code>&#8209;&#8209;arg value</code>
         <br/>
-        <code>--arg=value</code>
+        <code>&#8209;&#8209;arg=value</code>
     </li>
     <li>
         For arguments that can take multiple values (these will be filenames), the multiple filenames should appear after a space. If you use a filename wildcard you can put this after a space (which will be expanded by the shell unto multiple filenames before they reach Jalview), or you can put it after an equals-sign, which will be used by Jalview to find a list of files.  You cannot use an equals-sign and value followed by further values.
         <br/>
-        <code>--arg file1.fa otherfile.stk</code>
+        <code>&#8209;&#8209;arg file1.fa otherfile.stk</code>
         <br/>
-        <code>--arg filename*.fa</code> <em>(filenames expanded by shell)</em>
+        <code>&#8209;&#8209;arg filename*.fa</code> <em>(filenames expanded by shell)</em>
         <br/>
-        <code>--arg=filename*.fa</code> <em>(filenames expanded by Jalview)</em>
+        <code>&#8209;&#8209;arg=filename*.fa</code> <em>(filenames expanded by Jalview)</em>
     </li>
     <li>
         For arguments that act as a switch, most can be negated by preceding the argument name with <code>no</code>.
         <br/>
-        <code>--switch</code>
+        <code>&#8209;&#8209;switch</code>
         <br/>
-        <code>--noswitch</code>
+        <code>&#8209;&#8209;noswitch</code>
     </li>
     <li>
-        Some values can be modified, or may need additional information (for instance an <code>--image</code> output can be modified with a <code>--scale=number</code> factor, or a <code>--structure</code> can refer to a sequence with a <code>--seqid=ID</code>).  This additional information can be added in a number of different ways.
+        Some values can be modified, or may need additional information (for instance an <code>&#8209;&#8209;image</code> output can be modified with a <code>&#8209;&#8209;scale=number</code> factor, or a <code>&#8209;&#8209;structure</code> can refer to a sequence with a <code>&#8209;&#8209;seqid=ID</code>).  This additional information can be added in a number of different ways.
         <ul>
           <li>
               An argument immediately following the main argument.
               <br/>
-              <code>--image output.png --scale 2.5</code>
+              <code>&#8209;&#8209;image output.png --scale 2.5</code>
           </li>
           <li>
               A <em>sub-value modifier</em>, which is where one or more (comma-separated) values are added to the start of the main value, placed in square brackets.
               <br/>
-              <code>--open=[nowrap,colour=gecos-blossom]uniref50.fa</code>
+              <code>&#8209;&#8209;open=[nowrap,colour=gecos-blossom]uniref50.fa</code>
               <br/>
               Sub-value modifiers with a value must use an equals-sign separator, and those that act as a switch can simply be included without an equals-sign or value, and can be preceded with <code>no</code> to negate the value, as with the argument name.
           </li>
           <li>
               Another argument with the same <em>linked ID</em>.  A linked ID is an optional identifier for a particular open alignment, placed in square brackets immediately following the argument name (before the equals-sign or space).  If linked IDs are specified they do not need to be near to each other.
               <br/>
-              <code>--image[MYID]=output.png --other --args --scale[MYID]=2.5</code>
+              <code>&#8209;&#8209;image[MYID]=output.png --other --args --scale[MYID]=2.5</code>
           </li>
           <li>
               An argument that is designated as applying to <em>all linked IDs</em>
               <br/>
-              <code>--image=output.png --other --args --all --scale=2.5</code>
+              <code>&#8209;&#8209;image=output.png --other --args --all --scale=2.5</code>
               <br/>
-              <code>--image=output.png --other --args --scale[*]=2.5</code>
+              <code>&#8209;&#8209;image=output.png --other --args --scale[*]=2.5</code>
           </li>
         </ul>
     </li>
   <h2><a name="headlessmode"></a>Headless mode</h2>
 
   <p>
-  Jalview can be run in headless mode, i.e. without the usual graphical user interface (GUI), by specifying the <code>--headless</code> argument.  With command line arguments you can specify operations for Jalview to perform on one or more files and then stop running.  Most likely you will want to output another file, either an alignment for image file.
+  Jalview can be run in headless mode, i.e. without the usual graphical user interface (GUI), by specifying the <code>&#8209;&#8209;headless</code> argument.  With command line arguments you can specify operations for Jalview to perform on one or more files and then stop running.  Most likely you will want to output another file, either an alignment for image file.
   </p>
   <p>
-  <strong>If you specify an argument for an output file</strong> (one or more of <code>--output</code>, <code>--image</code> or <code>--structureimage</code>) then it will be assumed that you wish to <strong>run in headless mode</strong>.
+  <strong>If you specify an argument for an output file</strong> (one or more of <code>&#8209;&#8209;output</code>, <code>&#8209;&#8209;image</code> or <code>&#8209;&#8209;structureimage</code>) then it will be assumed that you wish to <strong>run in headless mode</strong>.
   </p>
   <p>
-  You can force Jalview to run in graphical mode using the <code>--gui</code> or <code>--noheadless</code> arguments.
+  You can force Jalview to run in graphical mode using the <code>&#8209;&#8209;gui</code> argument.
   </p>
 
   <p>
index cb0b10c..6b5c4c0 100644 (file)
  * The Jalview Authors are detailed in the 'AUTHORS' file.
  -->
 <head>
-<title>Groovy Shell</title>
+<title>Groovy Console</title>
 </head>
 <body>
   <p>
-    <strong>The Groovy Shell</strong>
+    <strong>The Groovy Console</strong>
   </p>
   <p>
     Groovy (<a href="http://www.groovy-lang.org/">www.groovy-lang.org</a>)
@@ -41,8 +41,8 @@
     short pause, you should then see the <a
       href="https://groovy-lang.org/groovyconsole.html">Groovy
       Console</a> appear. This allows you to interactively execute Groovy
-    scripts whilst Jalview is running. We've also provided a <strong>Calculations&#8594;Execute
-      Groovy Script</strong> button so you can execute the currently loaded
+    scripts whilst Jalview is running. We've also provided a <strong>Calculations&#8594;Run
+      Groovy Console Script</strong> button so you can execute the currently loaded
     groovy script whilst viewing an alignment.
   </p>
   <p>
     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:
+  </p>
 
-
-  
   <ul>
-    <li><strong>Jalview</strong> - this is bound to <code>jalview.bin.Jalview</code>.<br />Useful
-      methods include:
+    <li><strong>Jalview</strong> - this is bound to <code>jalview.bin.groovy.JalviewObject</code> providing access to the following useful
+      methods:
       <ul>
         <li>Jalview.getAlignFrames() - returns a list of
           jalview.gui.AlignFrame objects</li>
         <li>Jalview.getCurrentAlignFrame() - returns the alignment
-          window which is currently being looked at by the user</li>
+          window which has most recently been in focus.  If you change focus to another alignment window then re-running <code>Jalview.getCurrentAlignFrame()</code> will return the new <code>AlignFrame</code>.</li>
       </ul></li>
-    <li><strong>currentAlFrame</strong> - 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.</li>
+    <li><strong>currentAlFrame</strong> When used on the command line this refers to the current opened alignment.
+    <br/>
+    When used from the Groovy Console, it refers to the alignment that was in focus when the Groovy Console was opened.
+    <br/>
+    When a Groovy Console script is run from <em>Calculate</em>-&gt;<em>Run Groovy Console Script</em>, <code>currentAlFrame</code> us updated to that alignment.</li>
   </ul>
   <p>
+    If you specify a <code>--groovy</code> argument before an <code>--open</code> argument
+    then you should ensure your script doesn't refer to <code>currentAlFrame</code>.
+  <p>
+
+  <p>
     <em>A simple script</em><br />
   <ul>
     <li>Getting the title, alignment and first sequence from the
       current alignFrame<br> <pre>
-def alf = Jalview.getAlignFrames();
-print alf[0].getTitle();
-def alignment = alf[0].viewport.alignment;
+def al = Jalview.getCurrentAlignFrame();
+print al.getTitle();
+def alignment = al.viewport.alignment;
 def seq = alignment.getSequenceAt(0);
 </pre>
     </li>
index ac2489b..491a03f 100644 (file)
         <li><strong>Show Chains<br>
         </strong><em>Select which of the PDB file's chains are to be
             displayed.</em></li>
-        <li><strong>Colour by ..<br></strong><em>Submenu
+                               <li><strong>Ligands<br>
+                               </strong><em>When available, allows the display of all, none or specific
+                                               ligands (also known as HETATM groups) in the Jmol view, using CPK
+                                               spacefilling.</em></li>
+                               <li><strong>Colour by ..<br></strong><em>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/local-pdb-import.png b/help/help/html/features/local-pdb-import.png
new file mode 100644 (file)
index 0000000..561a10f
Binary files /dev/null and b/help/help/html/features/local-pdb-import.png differ
diff --git a/help/help/html/features/paematrices.html b/help/help/html/features/paematrices.html
new file mode 100644 (file)
index 0000000..2f00e19
--- /dev/null
@@ -0,0 +1,188 @@
+<html>
+<!--
+ * 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 
+ * 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 
+ * 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 <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
+ -->
+<head>
+<title>Working with PAE Matrices in Jalview</title>
+</head>
+
+<body>
+       <p>
+               <strong>Working with Predicted Alignment Error Matrices in
+                       Jalview</strong>
+       </p>
+
+       <p>Predicted Alignment Error (PAE) matrices are produced by
+               deep-learning based 3D-structure prediction pipelines such as
+               AlphaFold. They reflect how reliably two parts of a model have been
+               positioned in space, by giving for each residue the likely error (in
+               &Aring;ngstroms) between that residue and every other modelled
+               position the pair of residues' real relative position, if the model
+               and real 3D structure were superimposed at that residue.</p>
+       <p>
+               Jalview visualises PAE matrices as an alignment annotation track,
+               shaded from dark green to white, similar to the encoding used on the
+               EBI-AlphaFold website (see <a
+                       href="https://alphafold.ebi.ac.uk/entry/O04090">O04090 3D model</a>
+               at EBI-AlphaFoldDB).
+       </p>
+       <div style="display: flex; flex-wrap: wrap;" align="center"
+               width="100%">
+               <figure>
+                       <img src="../structures/epas1_annotdetail.png" height="300" />
+                       <figcaption>
+                               Alignment of EPAS1 homologs from Human, Rat and Cow<br />with
+                               predicted alignment error shown for Human
+                       </figcaption>
+               </figure>
+               <figure>
+                       <img src="../structures/epas1_pae_ebiaf.png" height="300" />
+                       <figcaption>
+                               Predicted Alignment Error for Human EPAS1<br />from <a
+                                       href="https://alphafold.ebi.ac.uk/entry/Q99814">https://alphafold.ebi.ac.uk/entry/Q99814</a>
+                       </figcaption>
+               </figure>
+       </div>
+       <p>
+               <strong>Importing PAE Matrices</strong>
+       </p>
+       <p>
+               Jalview retrieves PAE matrices when importing predicted 3D structures
+               from the EBI-AlphaFold database via <a
+                       href="../features/structurechooser.html">Jalview's structure
+                       chooser</a> GUI. If you have produced your own models and accompanying
+               PAE matrices using a pipeline such as ColabFold, then you can load
+               them both together via the <a
+                       href="../features/structurechooser.html#loadpdbfile">Load PDB
+                       File</a> dropdown menu in the 3D structure chooser, providing it is in a
+               <a href="../io/paematrixformat.html">supported PAE format</a>.
+       </p>
+       <p>
+               The <a href="../features/clarguments-basic.html">Command Line
+                       Interface</a> also provides a options for importing PAE matrices along
+               side models, enabling the automated production of alignment figures
+               annotated with PAE matrices and PLDDT scores.
+       </p>
+       <p>
+               <strong>Showing PAE Matrix Annotations </strong>
+       </p>
+       <p>
+               When viewing 3D structures from the EBI-AlphaFold database or local 3D
+               structures with an associated PAE file, the PAE is imported as <i>Reference
+                       Annotation</i>, which is not always automatically added to the alignment
+               view.
+       </p>
+       <p>To show the PAE, right click the sequence and locate the 'Add
+               Reference Annotation' entry in the Sequence ID submenu, or select all
+               sequences and locate the option in the Selection submenu. You can do
+               this in any alignment window (or view) where a sequence with
+               associated PAE data appears.</p>
+       <p>
+               <strong>Adjusting the height of PAE matrix annotations</strong>
+       </p>
+       <p>
+               PAE annotations behave in the same way as Jalview's line graph and
+               histogram tracks. Click+dragging up and down with the left (select)
+               mouse button held down will increase or decrease the height of the
+               annotation. You can also hold down <strong><em>SHIFT</em></strong>
+               whilst doing this to adjust the height of all PAE rows at once.
+       </p>
+       <p>PAE matrix annotation rows behave like any other sequence
+               associated annotation, with the following additional features:</p>
+       <ul>
+               <li>The vertical axis of the PAE heatmap is mapped to positions
+                       on the linked 3D structure.
+                       <ul>
+                               <li>Mousing over the matrix shows a tooltip giving information
+                                       on the range of values under the mouse.<br />Positions in the
+                                       associated 3D structure are also highlighted in any linked views.
+                               </li>
+                               <li>Clicking on positions in the matrix selects columns of the
+                                       alignment corresponding to the row and column in the matrix.</li>
+                       </ul>
+               </li>
+               <li>Rectangular selections (created by Cmd (or Alt)+Click
+                       dragging on the matrix) can be created to select multiple ranges of
+                       columns at once.</li>
+               <li>Columns corresponding to adjacent regions with similarly low
+                       levels of predicted alignment error can be selected by Ctrl+Clicking
+                       on a region in the matrix.</li>
+               <li>Columns of an alignment showing a PAE matrix can be grouped
+                       and selected by clustering the matrix.</li>
+       </ul>
+       <p>
+               <strong><a name="clustering">Clustering PAE Matrices</a></strong>
+       </p>
+       <p>PAE matrices are useful for identifying regions of 3D structure
+               predictions that are likely to be positioned in space in the same or
+               similar way as shown in the predicted structure data. Regions of low
+               PAE often correlate with high alphafold reliability (PLDDT) scores,
+               but also complement them since they highlight well-folded regions such
+               as domains, and how well those regions have been predicted to be
+               positioned relative to eachother, which is important when evaluating
+               whether domain-domain interactions or other contacts can be trusted.</p>
+       <p>To make it more easy to identify regions of low PAE, Jalview can
+               cluster the PAE matrix, allowing columns of the matrix to be grouped
+               according to their similarity, using an Average Distance (UPGMA) tree
+               algorithm and the sum of differences between each column's PAE values.</p>
+       <p>
+               <strong><em>dist<sub>ij</sub></em> = &#8741; <em><u>p</u><sub>i</sub>-<u>p</u><sub>j</sub></em>
+                       &#8741;</strong>
+       </p>
+       <p>
+               To create a PAE matrix tree, right click on a PAE annotation's label
+               to open the annotation popup menu, and select <strong><em>Cluster
+                               Matrix</em></strong>. Once the calculation has finished, a tree viewer will open,
+               and columns of the matrix are then partitioned into groups such that
+               the third left-most node from the root is placed in its own group.
+               Colours are randomly assigned to each group, and by default these will
+               also be overlaid on the matrix annotation row.
+       <p>
+       <ul>
+               <li>The PAE matrix tree viewer behaves like other tree views in
+                       Jalview, except selecting nodes or groups of nodes in the tree select
+                       columns in the alignment rather than sequences, and clicking adjust
+                       the matrix's partition.</li>
+               <li>Only one tree and clustering can be defined for a PAE matrix,
+                       regardless of whether it is displayed in different views or
+                       alignments.</li>
+               <li>Double clicking on a position in the PAE annotation where a
+                       clustering has been defined will select both the row and column
+                       clusters for the clicked position. This makes it easy to select
+                       clusters corresponding to pairs of interacting regions.</li>
+               <li>Cluster colours for a PAE matrix can be used to colour
+                       sequences or columns of the alignment via the <strong><em><a
+                                       href="../colourSchemes/annotationColouring.html">Colour by
+                                               Annotation.. dialog</a></em></strong>
+                                               (opened by right-clicking the annotation label
+                       and selecting from the popup menu).
+               </li>
+       </ul>
+       <p>
+               <strong>PAE matrices and Jalview Projects</strong>
+       </p>
+       <p>Any PAE matrices imported to Jalview are saved along side any
+               trees and clustering defined on them in Jalview Projects.</p>
+       <p>
+               <em>Support for visualision and analysis of predicted alignment
+                       error matrices was added in Jalview 2.11.3. </em>
+       </p>
+</body>
+</html>
index d559db8..6889d84 100755 (executable)
@@ -36,7 +36,7 @@ td {
   </p>
   <p>The search box is displayed by pressing Control and F or
     selecting &quot;Find...&quot; from the &quot;Search&quot; menu.</p>
-  <img src="search.png" width="400" height="152">
+  <img src="search.png"  height="152">
   <p>&quot;Find next&quot; will find the next occurrence of the
     query and adjust the alignment window view to show it, and
     &quot;Find all&quot; highlights all matches for a query. The
@@ -46,18 +46,24 @@ td {
   <ul>
     <li>The search uses regular expressions. (understands a mixture
       of posix and perl style regex - see below for a summary)</li>
-    <li>Gaps are ignored when matching the query to the sequences
-      in the alignment.</li>
-    <li>Hidden columns can optionally be ignored (<em>since Jalview 2.11</em>)</li>
-    <li>The search is applied to both sequences and their IDs. It can
-      optionally also be applied to the description string (<em>since Jalview
-        2.10</em>), and sequence feature descriptions (<em>since Jalview 2.11.2.5</em>).
-    </li>
-    <li>If a region is selected, then search will <strong>only</strong>
+               <li>If a region is selected, then search will <strong>only</strong>
       be performed on that region.<br />
     <em>Tip: to quickly clear the current selection, click the
         alignment view you wish to search, then press 'Escape'.</em>
     </li>
+    <li>Gaps are ignored when matching the query to the sequences
+      in the alignment.</li>
+    <li>Hidden columns can optionally be ignored (<em>since Jalview 2.11</em>)</li>
+               <li>The search is applied to both sequences and their IDs. <br />
+                       Check boxes also enable searching of:
+                       <ul>
+                               <li><strong>Sequence description</strong> (<em>since Jalview 2.10</em>)
+                               </li>
+                               <li><strong>Sequence Feature</strong> type and description for currently displayed features (<em>since Jalview
+                                               2.11.3.0</em>)
+                               </li>
+                       </ul>
+               </li>
     <li>Tick the &quot;Match Case&quot; box to perform a case
       sensitive search.</li>
     <li>To access a <a href="#queryhistory">previously used
@@ -87,9 +93,11 @@ td {
   <strong>Copying highlighted regions to a new alignment</strong>
   </p>
   <p>
-    You can copy the currently highlighted matching regions of sequences to the clipboard with alt-Command-C.    
+       Press <strong>Copy</strong> button or type Ctrl (Cmd on OSX) + Shift +
+       C to copy highlighted search results to the clipboard, enabling them
+       to be pasted to a new alignment (via Shift+Ctrl (or Cmd) + V).
   </p>
-  <p>
+       <p>
 
     <strong>A quick Regular Expression Guide</strong>
   </p>
index 47c18f4..9178b9a 100644 (file)
Binary files a/help/help/html/features/search.png and b/help/help/html/features/search.png differ
index 2c77049..f91b1dd 100644 (file)
       style="width: 464px; height: 173px;"> <br /> <strong>Manual
       selection/association of PDB files with Sequences</strong>
   </p>
-  <p>To manually associate PDB files with a sequence, select 'From
-    File', or 'Enter PDB Id' from the drop-down menu:
-  <ul>
-    <li><strong>From File</strong> - allows you to load a PDB file
-      from the local machine or network and associate it with the
-      selected sequence. PDB files associated in this way will also be
-      saved in the <a href="jalarchive.html">Jalview Archive file</a>.<br></li>
-    <li><strong>Enter PDB Id</strong> - allows you specify a PDB ID
-      for your sequence. The PDB Rest API, provided by EMBL-EBI, is used
-      to validate and fetch structure data.<br></li>
-  </ul>
-
-  <p>
-    <em>The Structure Chooser interface was introduced in Jalview
-      2.9. </em>
-  </p>
+       <p>
+               <strong>Manual Association of PDBe accessions with sequences</strong>
+       </p>
+       <p>If for some reason the PDBe and 3D beacons search fail to
+               automatically the PDB structure or model you wish to import, you can
+               select 'Enter PDB Id' from the drop-down menu to manually specify PDB
+               identifiers for one or more selected sequences. The PDB Rest API,
+               provided by EMBL-EBI, is used to validate accessions exist, and fetch
+               structure data.</p>
+       <p>
+               <strong><a name="loadpdbfile">Import structure models
+                               and metadata from file</a></strong>
+       </p>
+       <p>
+               Selecting the <strong>From File</strong> option from the drop down
+               menu allows 3D structure data to be imported from your own computer.
+               PDB or mmCIF files associated in this way are also saved in <a
+                       href="jalarchive.html">Jalview Projects</a>. <br /> <img
+                       src="local-pdb-import.png" style="width: 330px; height: 321px;"><br />
+               The 'From File' dialog provides a drop down menu which allows you to
+               specify how the Temperature Factor metadata for each residue in the 3D
+               structure data file is interpreted:
+       
+       <ul>
+               <li>Default - Jalview will try to automatically determine whether
+                       to show as 'Temperature Factor', 'AlphaFold Reliability' or 'Model
+                       Quality'</li>
+               <li>PLDDT - Model has PLDDT scores in the temperature factor
+                       column.</li>
+       </ul>
+       <p>
+               An additional <em>Predicted Alignment Error</em> file can also be
+               provided when importing 3D structure data. Jalview supports import of
+               PAE Matrices provided as <a href="../io/paematrixformat.html">AlphaFold
+                       format JSON files</a> - which are also produced by ColabFold. See <a
+                       href="paematrices.html">Working with PAE Matrices</a> for details on
+               what Jalview allows you to do with associated PAE matrix data.
+       </p>
+       <p>
+               <em>The Structure Chooser interface was introduced in Jalview
+                       2.9. </em>
+       </p>
 </body>
 </html>
index 947b96b..df76f89 100755 (executable)
@@ -87,7 +87,7 @@
     <strong>Structure Viewers in the Jalview Desktop</strong><br /> The
     <a href="jmol.html">Jmol viewer</a> has been included since Jalview
     2.3. Jalview 2.8.2 included support for <a href="chimera.html">Chimera</a>,
-    provided it is installed and can be launched by Jalview. ChimeraX and PyMOL
+    provided it is installed and can be launched by Jalview. ChimeraX and <a href="pymol.html">PyMOL</a>
     support is included from Jalview 2.11.2. The default
     viewer can be configured in the <a href="preferences.html#structure">Structure
       tab</a> in the <strong>Tools&rarr;Preferences</strong> dialog box.
     un-tick the <strong>Superpose Structures</strong> checkbox.
 
   </p>
-  <p>
-    <em>Superposing structures</em><br/>Jalview superposes structures using
-    the visible portions of any associated sequence alignments. A
-    message in the structure viewer's status bar will be shown if not
-    enough aligned columns were available to perform a superposition.
-  </p>
-  <p>
-  See the <a href="jmol.html">Jmol
-    </a> and <a href="chimera.html">Chimera</a> help pages for
-      more information about their capabilities.</p>
-  
-
-  <p>
+       <p>
+               <em>Superposing structures</em><br />Jalview superposes structures
+               using the currently selected columns (if more than 3 columns are
+               selected), or the visible portions of any associated sequence
+               alignments. Depending on the viewer, Root Mean Squared Deviation (RMS
+               or RMSD) for each pair of superpositions may be output in the
+               structure viewer's console.
+       </p>
+       <p>A message in the structure viewer's status bar will be shown if
+               not enough aligned columns were available to perform a superposition.
+       </p>
+       <p>
+               See the <a href="jmol.html">Jmol</a>, <a href="chimera.html">Chimera/X</a>
+               and <a href="pymol.html">Pymol</a> help pages for more information
+               about their individual capabilities.
+       </p>
+       <p>
     <strong>Retrieving sequences from the PDB</strong><br>You can
     retrieve sequences from the PDB using the <a
       href="pdbsequencefetcher.html">Sequence Fetcher</a>. The sequences
index 870b005..5f33dfe 100644 (file)
@@ -29,8 +29,9 @@
   <p>
     Jalview can process PDB data associated with sequences to display
     values extracted from the <em>Temperature Factor</em> 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 <em>AlphaFold Reliability</em> (PLDDT) or <em>Model
+      Quality</em> as appropriate.
   </p>
   <p>
     <strong>Extracting data from PDB files<br /></strong>Annotation is
     the <strong>Add Reference Annotation</strong> in the <strong>Selection</strong>
     and <strong>Sequence ID</strong> sub-menus of the Sequence ID
     Panel's popup menu.<br /> <em>Please note:</em>Protein structures
-    are analysed <em>in situ</em>, but Jalview employs a web service to
-    process RNA structures which can cause long delays if your internet
-    connection is slow.
+    are analysed <em>in situ</em>. 
   </p>
   <p>
     The <a href="../menus/alwannotation.html"><em>Annotations</em>
       alignment menu</a> provides settings useful for controlling the
-    display of secondary structure annotation.
-  </p>
+    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.
+    </p>
   <p>
     <strong>Shading sequences by associated structure
       annotation<br />
     </strong>The annotation colouring dialog (opened by the <strong>Colour&rarr;By
-      Annotation</strong> option) allows sequences with associated secondary
+      Annotation</strong> 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 <em>Per Sequence</em> option
     and then choose <em>Secondary structure</em> from the dropdown menu.<br />When
index bd7144e..494dd3e 100644 (file)
@@ -36,7 +36,7 @@
     <li>Copy and paste it into the groovy script console</li>
     <li>Load the example Feredoxin project (the one that opens by
       default when you first launched Jalview)</li>
-    <li>Select <strong>Calculations&#8594;Execute Groovy
+    <li>Select <strong>Calculations&#8594;Run Groovy Console
         Script</strong> from the alignment window's menu bar to run the script on
       the current view.
     </li>
index 04216da..c940373 100755 (executable)
     </li>
 
   </ul>
-  <a name="htmlexport" />
   <p>
+    <strong>PNG Export Options</strong>
+  
+  <p>
+    <em>Since Jalview 2.11.3</em> it is possible to specify options when <a
+      href="../features/clarguments-reference.html#exportingimagefiles">exporting
+      figures via the command line</a> to increase the resolution of the
+    exported PNG, and configure maximum width and height settings.
+  
+  <p>You can also configure default export settings by adding the
+    following lines to
+  
+  <pre>.jalview_properties</pre>
+  <pre>BITMAP_SCALE=&lt;Scale factor multiplied by 10&gt;
+  BITMAP_WIDTH=Width of export in pixels
+  BITMAP_HEIGHT=Height of figure export in pixels
+  </pre>
+  When scale is not set, the figure will be scaled to fit in the smallest
+  specified dimension. Scale will be ignored if it results in an image
+  dimension greater than the smallest specified dimension.
+  <p>
+  <a name="htmlexport" /><p>
     <strong>Exporting alignments as Web Pages</strong>
   <p>
     In Jalview 2.9, new HTML exporting options were introduced. The
diff --git a/help/help/html/io/paematrixformat.html b/help/help/html/io/paematrixformat.html
new file mode 100644 (file)
index 0000000..9cf57d9
--- /dev/null
@@ -0,0 +1,71 @@
+<html>
+<!--
+ * 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 
+ * 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 
+ * 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 <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
+ -->
+<head>
+<title>Supported Formats for Predicted Alignment Error Matrices</title>
+</head>
+
+<body>
+       <p>
+               <strong>Supported Formats for Predicted Alignment Error
+                       Matrices</strong>
+       </p>
+       <p>
+               Predicted Alignment Error matrices are square matrices produced as
+               part of deep-learning based 3D-structure prediction pipelines such as
+               AlphaFold. They can be imported via <a
+                       href="../features/structurechooser.html">Jalview's structure
+                       chooser</a> GUI and the <a href="../features/clarguments-basic.html">Command
+                       Line Interface</a>. See <a href="../features/paematrices.html">Working
+                       with PAE Matrices</a> for information on how they are visualised and
+               analysed in Jalview.
+       </p>
+       <p>
+               <strong>Supported Formats</strong>
+       </p>
+       <p>Jalview supports import of PAE matrix data as provided by the
+               EBI-AlphaFold database. This resource provides PAE matrices as a JSON
+               files structured in one of the following ways:</p>
+       <pre>
+       # Version 1 format PAE file - deprecated 28th July 2022
+       {
+               residue1:[1,1,... total number of residues]
+               residue2:[1,2,... total number of residues]
+               distance:[0.1,0.3,... list of PAE matrix elements as doubles]
+       }
+  </pre>
+  <pre>
+       # Version 2 format PAE file - see https://alphafold.ebi.ac.uk/faq
+       {
+               max_predicted_alignment_error: 4.0, # may also be max_pae
+               predicted_alignment_error: [[1,2,0,0,3,...],...] # may also be pae
+       }
+  </pre>
+       <p>
+               Variants of the version 2 format include using 'pae' instead of
+               'predicted_alignment_error' in the names of keys. Jalview copes both.<br />
+               Once imported, Jalview stores PAE matrices as float arrays along with
+               any associated tree and partition set resultant from clustering the
+               matrix. <br/><br/><em>PAE Matrix import support was added in Jalview 2.11.3
+               </em>
+       </p>
+</body>
+</html>
index cd09693..ff53d0b 100755 (executable)
@@ -86,6 +86,7 @@
             highly variable regions.</em></li>
 
         <li>
+       </li>
         <li><strong>Copy Consensus Sequence</strong><br>
           Copies the consensus sequence to the clipboard in Fasta
           format, to allow the consensus sequence to be added to an
diff --git a/help/help/html/structures/epas1_annotdetail.png b/help/help/html/structures/epas1_annotdetail.png
new file mode 100644 (file)
index 0000000..45118a0
Binary files /dev/null and b/help/help/html/structures/epas1_annotdetail.png differ
diff --git a/help/help/html/structures/epas1_pae_ebiaf.png b/help/help/html/structures/epas1_pae_ebiaf.png
new file mode 100644 (file)
index 0000000..b7b4bf6
Binary files /dev/null and b/help/help/html/structures/epas1_pae_ebiaf.png differ
diff --git a/help/help/icons/jalview_docs_logo.png b/help/help/icons/jalview_docs_logo.png
new file mode 100644 (file)
index 0000000..21f5386
Binary files /dev/null and b/help/help/icons/jalview_docs_logo.png differ
index a433bc6..e527792 100644 (file)
@@ -1,86 +1,79 @@
 ---
 version: 2.11.3.0
-date: 2023-07-19
+date: 2023-11-03
 channel: "release"
 ---
 
 ## New Features
 - <!-- JAL-4064 --> Native M1 build for macOS using Adoptium JRE 11 macos-aarch64
-- <!-- JAL-4054 --> Installers built with install4j10
-- <!-- JAL-3676 --> Allow log level configuration via Jalview's Java Console, and a Copy to Clipboard button
-- <!-- JAL-3416 --> FlatLAF default look and feel on Linux, OSX and everywhere else ?
-
+- <!-- JAL-3416 --> Jalview now uses a standard 'look and feel' (FlatLaf) on Linux, OSX and everywhere else
 - <!-- JAL-4019 --> Ambiguous Base Colourscheme
 - <!-- JAL-4061 --> Find can search sequence features' type and description
 - <!-- JAL-4062 --> Hold down Shift + CMD/CTRL C to copy highlighted regions as new sequences
-- <!-- JAL-1556 --> Quickly enable select and/or colour by for displayed annotation row via its popup menu
+- <!-- JAL-1556 --> Quickly enable select and/or colour by for displayed annotation row via annotation panel popup menu
 - <!-- JAL-4094 --> Shift+Click+Drag to adjust height of all annotation tracks of same type
 - <!-- JAL-4190 --> Pressing escape in tree panel clears any current selection
-
 - <!-- JAL-4089 --> Use selected columns for superposition
 - <!-- JAL-4086 --> Highlight aligned positions on all associated structures when mousing over a column
-
 - <!-- JAL-4221 --> sequence descriptions are updated from database reference sources if not already defined
+- <!-- JAL-4273 --> Visible adjuster marks to grab and adjust annotation panel height and id width
+- <!-- JAL-4260 --> Adjustable ID margin when alignment is wrapped
+- <!-- JAL-4274 --> Command line options and configurable bitmap export (via preferences file) for height, width and scale factor
+- <!-- JAL-4307 --> Show or hide ligands in a Jmol structure view via View Ligands submenu
+- <!-- JAL-4252 --> 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
 - <!-- JAL-3895 --> Alphafold red/orange/yellow/green colourscheme for structures
 - <!-- JAL-4095 --> Interactive picking of low pAE score regions
-- <!-- JAL-4027 --> contact matrix datatype in Jalview
+- <!-- JAL-4027, JAL-3858, JAL-2292 --> Predicted Alignment Error annotation tracks for structures from AlphaFold DB
 - <!-- JAL-4033 --> Selections with visual feedback via contact matrix annotation
-
 - <!-- JAL-3855 --> Discover and import alphafold2 models and metadata from https://alphafold.ebi.ac.uk/
-
 - <!-- JAL-4091 --> Visual indication of relationship with associated sequence to distinguish different sequence associated annotation rows
 - <!-- JAL-4123 --> GUI and command line allows configuration of how temperature factor in imported 3D structure data should be interpreted
 - <!-- JAL-3914 --> Import model reliability scores encoded as temperature factor annotation with their correct name and semantics
 - <!-- JAL-3858 --> Import and display alphafold alignment uncertainty matrices from JSON
 - <!-- JAL-4134,JAL-4158 --> Column-wise alignment groups and selections and interactive tree viewer for PAE matrices
 - <!-- JAL-4124 --> Store/Restore PAE data and visualisation settings from Jalview Project
+- <!-- JAL-4281 --> Store and restore adjustable ID margin and annotation panel height in Jalview projects
 - <!-- JAL-4083 --> Multiple residue sidechain highlighting in structure viewers from PAE mouseovers
+- <!-- JAL-4147 --> 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.
 
 
 ### Jalview on the command line
-
-- <!-- JAL-4160,JAL-629 --> New command line argument framework allowing flexible batch processing, figure generation, and import of structures, pae matrices and other sequence associated data
+- <!-- JAL-4160,JAL-629,JAL-4262,JAL-4265, --> 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.
+- <!-- JAL-3830 --> Command-line wrapper script for macOS bundle, linux and Windows installations (bash, powershell and .bat wrappers)
 - <!-- JAL-4121 --> Assume --headless when jalview is run with a command line argument that generates output
+- <!-- JAL-244 --> Automatically adjust Left margin on import to avoid cropping of annotation labels & sequence IDs
+- <!-- JAL-901 --> Specify alignment title on import via --title argument
+- <!-- JAL-4195,JAL-4194,JAL-4193 --> 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
-
-
 - <!-- JAL-4250 --> Secondary structure annotation glyphs are rendered anti-aliasing when enabled
 - <!-- JAL-325 --> Helix and Sheet glyphs vertically centered with respect to grey coil secondary structure annotation track
-- <!-- JAL-4253 --> Lower line of the sequence group border does not align with vertical and background residue box
+- <!-- JAL-4317 --> feature should be displayed when its rendering and filtering settings are adjusted
 - <!-- JAL-4250 --> Updated JFreeSVG (https://www.jfree.org/jfreesvg) from 2.1 to 3.4.3
 - <!-- JAL-3119 --> Name of alignment and view included in overview window's title
 - <!-- JAL-4213 --> "add reference annotation" add all positions in reference annotation tracks, not just positions in the currently highlighted columns/selection range
 - <!-- JAL-4119 --> EMBL-EBI SIFTS file downloads now use split directories
-
-- <!-- JAL-4195,JAL-4194,JAL-4193 --> 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
-
-
-JAL-4187        Powershell launcher script fails when given no arguments with the old ArgsParser
-
-known issue ? <!-- JAL-4127    --> 'Reload' for a jalview project results in all windows being duplicated
-
-
-- <!-- JAL-3830 --> Command-line wrapper script for macOS bundle, linux and Windows installations (bash, powershell and .bat wrappers)
 - <!-- JAL-3820 --> In Linux desktops' task-managers, the grouped Jalview windows get a generic name
-
-## Still in progress (delete on release)
-
-- <!-- JAL-2382 --> Import and display sequence-associated contact predictions in CASP-RR format
-- <!-- JAL-2349 --> Contact prediction visualisation
-- <!-- JAL-2348 --> modularise annotation renderer
+- <!-- JAL-4206 --> Improved file chooser's 'recent files' view and added filter for 'All known alignment files'
+- <!-- JAL-4206 --> Relative files added to recent files list via import from command line are selected when Jalview opened from same location
+- <!-- JAL-4308 --> Reduce number of database crossreferences shown in tooltip
+- <!-- JAL-4315 --> Drag and drop feature colours file on an alignment to quickly apply feature settings
+- <!-- JAL-3676 --> Allow log level configuration via Jalview's Java Console, and a Copy to Clipboard button
+- <!-- JAL-4304,JAL-4305 --> Upgrade bundled groovy to v4.0.15 and regularised interface for groovy scripts run from CLI, interactively and headlessly.
 
 ### Development and Deployment
-
+- <!-- JAL-4054 --> Installers built with install4j10
 - <!-- JAL-4167 --> Create separate gradle test task for some tests
+- <!-- JAL-4212 --> Prevent gradle test on macOS continuously grabbing focus
 - <!-- JAL-4111 --> Allow gradle build to create suffixed DEVELOP-... builds with channel appbase
+- <!-- JAL-4288 --> Update .jvl generation in build.gradle for jalview branch builds
 - <!-- JAL-4243 --> Jalview bio.tools description maintained under jalview's git repo and bundled with source release
+- <!-- JAL-4110 --> Output stderr and stdout when running tests via gradle
+- <!-- JAL-3599 --> New gradle task providing runtime acceptance test for JalviewJS  based on Chromium for Tests (still work in progress)
 
 ## Issues Resolved
 - <!-- JAL-2961 --> Jmol view not always centred on structures when multiple structures are viewed
@@ -96,17 +89,36 @@ known issue ? <!-- JAL-4127 --> 'Reload' for a jalview project results in all wi
 - <!-- JAL-4075 --> Don't add string label version of DSSP secondary structure codes in secondary structure annotation rows
 - <!-- JAL-4182 --> reference annotation not correctly transferred to alignment containing a sub-sequence when a selection is active
 - <!-- JAL-4177 --> Can press 'Add' or 'New View' multiple times when manually adding and viewing a 3D structure via structure chooser
+- <!-- JAL-4311 --> 3D beacons sources providing models scored with PLDDT and pTM not sorted against alphaFoldDB models
 - <!-- JAL-4133 --> Jalview project does not preserve font aspect ratio when Viewport is zoomed with mouse
+- <!-- JAL-4253,JAL-4293 --> Lower line of the sequence group border does not align with vertical and background residue box
 - <!-- JAL-4128 --> Resizing overview quickly with solid-drags enabled causes exception
 - <!-- JAL-4150 --> Sequences copied to clipboard from within Jalview cannot be pasted via the desktop's popup menu to a new alignment window
 - <!-- JAL-2528, JAL-1713 --> Overview window is saved in project file, and state of 'show hidden regions' is preserved.
 - <!-- JAL-4153 --> JvCacheableInputBoxTest flaky on build server
+- <!-- JAL-4255 --> SLF4J produces an error to STDERR at Jalview startup due to missing class
+- <!-- JAL-4189 --> macOS Dock and KDE taskbar names Jalview icon "java" when running
+- <!-- JAL-2910 --> HeadlessException in console in headless mode (actually fixed in 2.11.{0,1,2))
+- <!-- JAL-3783 --> Groovy console does not open when Jalview launched from jalview's Java 11 executable jar (available via conda) for recent versions of groovy
+- <!-- JAL-4310 --> Don't offer View model page for sources that do not have model pages
+- <!-- JAL-4298 --> Java Console opening at startup with the exampleFile_v2_7.jvp opening (nearly always) causes Jalview to hang
+- <!-- JAL-4282 --> 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)
+- <!-- JAL-4223 --> RNAML import missing terminal residue
+- <!-- JAL-4218 --> Jalview source distribution unnecessarily includes dist directory with built jalview jar and dependencies
 
 ## New Known defects
+- <!-- JAL-4303 --> 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.
+- <!-- JAL-4302 --> Tree renderer doesn't show bottom-most leaves of tree when Fit-To-Window is enabled.
 - <!-- JAL-4178 --> Cannot cancel structure view open action once it has been started via the structure chooser dialog
 - <!-- JAL-4142 --> Example project's multiple views do not open in distinct locations when eXpand views is used to show them all separately
+- <!-- JAL-4127 --> 'Reload' for a jalview project results in all windows being duplicated
+- <!-- JAL-4325 --> Overview shown and then closed when importing legacy jalview projects without overview store/restore information
 - <!-- JAL-4165 --> Missing last letter when copying consensus sequence from alignment if first column is hidden
-
-
+- <!-- JAL-4261 --> Last sequence ID in alignment not shown and annotation labels are misaligned in HTML export
+- <!-- JAL-3024 --> Files opened via command line with a relative path are added as relative paths to Recent files list (since 2.0.x)
+- <!-- JAL-4291 --> Test coverage for ID width adjustment disabled pending fix for new annotation label geometry and width calculation
+- <!-- JAL-4323 --> scripts adding new fileformats or colourschemes do not work when run via command line
+- <!-- JAL-4290 --> Headless alignment export with structure annotations doesn't include secondary structure and temperature factor
+- <!-- JAL-4151 --> Copy sequences from one alignment and Pasting as new window in another alignment doesn't propagate title from original alignment's window
 
 
index ec82f83..b6c1b0d 100644 (file)
@@ -1,7 +1,24 @@
-The 2.11.3 series includes support for in-depth exploration of predicted alignment error matrices from AlphaFold in the context of multiple alignments, along with support for standard colourschemes for shading models according to their pLDDT.
+The 2.11.3 Jalview release features a new and more powerful command line interface, support for in-depth exploration of predicted alignment error (PAE) matrices from AlphaFold in the context of multiple alignments, AlphaFold's standard Blue-Orange-Red confidence colourscheme, and a host of [minor improvements and bug fixes](releases.html#Jalview.2.11.3.0)
 
-We're launching this release at ISMB 2023 - come find us !
+**Interactive exploration of AlphaFold Predicted Alignment Error Matrices**
 
-It also introduces new support for native ARM-based OSX architectures, and a few other goodies!
+Predicted alignment error (PAE) matrices are JSON files produced by AlphaFold and other 3D structure prediction tools, which reflect how well any two positions in a predicted structure are positioned correctly relative to each other. Jalview automatically imports PAE matrices when retrieving protein structures from the EBI-AlphaFold database. A PAE matrix file can also be provided when manually importing 3D structure data.
 
+Once imported, PAE matrices are shown in annotation tracks as a heat map shaded pale to dark green, where darker shades indicate higher confidence in relative positioning. Right-clicking a PAE Matrix's annotation label provides the option to cluster the columns of the matrix, producing a tree where regions of well arranged structure are grouped together, allowing columns containing those regions to be selected and manipulated further.
 
+
+**Jalview's Next Generation Command Line Interface**
+
+Jalview 2's original command line interface (CLI) allowed alignments to be imported, annotated and overlaid with sequence features, coloured, associated with trees, and exported either as figures (EPS, PNG, SVG, HTML SVG or an interactive BioJS page) or with one of Jalview's supported alignment export file formats. The new command line interface provides all this, as well as a range of additional functionality previously only available via the GUI:
+
+  * 3D structures can be associated with sequences in alignments and shown in Jmol or external viewers
+  * Secondary structure, Model Reliability and Temperature factor can be shown and used to colour alignments
+  * PAE Matrices can be imported and shown as annotation
+  * 3D structure data shown in Jmol can be exported as PNG
+  * Scale factors and dimensions can be specified, allowing high resolution image exports
+
+In addition to these new functionality, next generation CLI operations can be applied to a range of files and directories through the use of wild-cards. This allows faster and more efficient processing of large numbers of alignments. It also facilitates modularisation of operations through the use of ['command-line argument files'](features/clarguments-argfiles.html). 
+
+All new CLI parameters are preceded by '--', as opposed to an optional single '-' which was used in Jalview's old CLI. Old style arguments can still be used, so existing scripts will still work as before, but old-style operations cannot be mixed with new operations in the same CLI call. Use of old command line operations will also raise a warning, and we plan to completely remove support in Jalview's next major release (2.12).
+
+As usual, please let us via [Jalview's Discussion forum](https://discourse.jalview.org) of any issues you encounter using the new CLI, and of course any requests for improvement or new functionality !
index 70deea4..301ea4b 100755 (executable)
     <strong>Welcome to Jalview Version __VERSION__ (released __DISPLAY_DATE__)!!</strong><br/>
   </p>
 __WHATS_NEW__
-  <p>
-    The 2.11.2 release series provides support for two popular 3D
-    structure visualisation tools, new features for discovery of 3D
-    structures, improved platform integration and a new command line
-    tool allowing Jalview to be more easily called from scripts.</p>
-
-  <p>
-    <strong>View predicted protein structures via 3D-Beacons</strong> <br>
-    Jalview 2.11.2's <a href="features/structurechooser.html">Structure
-      Chooser includes a client for the 3D-Beacons Network</a>. Launched in
-    2021, the 3D-Beacons network (<a
-      href="https://www.ebi.ac.uk/pdbe/pdbe-kb/3dbeacons/">www.ebi.ac.uk/pdbe/pdbe-kb/3dbeacons/</a>)
-    provides a central point for the retrieval of predicted and observed
-    3D structures for sequences in Uniprot, including homology models
-    from Swiss-model and deep learning based predictions from the EBI's
-    Alphafold database (Orengo et al. 2020, <a
-      href="https://doi.org/10.12688/f1000research.20559.1">doi:10.12688/f1000research.20559.1</a>).<br>
-  </p>
-
-  <p>
-    <strong>Support for viewing structures with ChimeraX and
-      Pymol</strong><br> Jalview's 3D structure viewer system has been
-    re-architected to allow easier integration of external structure
-    viewers, and takes advantage of the strucViz2 Chimera communications
-    library developed by Scooter Morris (<a
-      href="https://doi.org/10.1093/bioinformatics/btm329">doi:10.1093/bioinformatics/btm329</a>).<br /> <br />
-    The <a href="features/preferences.html#structure">Structures
-      Preferences tab</a> provides new options allowing ChimeraX and
-    Pymol to be used for visualising external 3D structures. Views
-    from all structure viewers are saved in Jalview Projects, allowing
-    them to be shared with others using Jalview 2.11.2 or later,
-    providing they have the same viewer installed and configured to be
-    used with Jalview.<br/><br/>Jalview
-    2.11.2 has been tested with <strong>Pymol 2.5.0 (community)</strong> and <strong>2.5.2
-    (incentive)</strong>. For <strong>ChimeraX, we recommend using v1.3 or later</strong>.
-  </p>
-  <p>Other highlights include:</p>
-  <ul>
-    <li>Import of annotated DNA and RNA loci via GenBank and EMBL
-      style flatfile</li>
-    <li><strong>Easier configuration of <a
-        href="features/preferences.html#startup">Jalview's memory
-          allocation</a></strong></li>
-    <li>Scripts for <a href="features/commandline.html">running
-        Jalview via the command line</a> on macOS, Linux/Unix and Windows.
-    </li>
-  </ul>
-
-
-  <p>
-      For the full details, see <a
-        href="releases.html#Jalview.2.11.2">the Jalview 2.11.2 series
-        release notes</a>.
-    </p>
-  <p>
-    <strong>Known Issues</strong> <br />The following known issues will
-    be addressed in a minor patch release.
-  
-  <ul>
-    <li>Display of RESNUM sequence features are not suppressed when
-      structures associated with a sequence are viewed with an external
-      viewer (Regression from 2.11.1 series)</li>
-  </ul>
-    <p></p>
 </body>
 </html>
diff --git a/j11lib/flatlaf-3.0.jar b/j11lib/flatlaf-3.0.jar
deleted file mode 100644 (file)
index 75d90d3..0000000
Binary files a/j11lib/flatlaf-3.0.jar and /dev/null differ
diff --git a/j11lib/flatlaf-3.1.1.jar b/j11lib/flatlaf-3.1.1.jar
deleted file mode 100644 (file)
index 2b13cdd..0000000
Binary files a/j11lib/flatlaf-3.1.1.jar and /dev/null differ
diff --git a/j11lib/flatlaf-3.2.jar b/j11lib/flatlaf-3.2.jar
new file mode 100644 (file)
index 0000000..450c1e8
Binary files /dev/null and b/j11lib/flatlaf-3.2.jar differ
diff --git a/j11lib/flatlaf-extras-3.0.jar b/j11lib/flatlaf-extras-3.0.jar
deleted file mode 100644 (file)
index 1f6bbc3..0000000
Binary files a/j11lib/flatlaf-extras-3.0.jar and /dev/null differ
similarity index 52%
rename from j8lib/flatlaf-extras-3.1.1.jar
rename to j11lib/flatlaf-extras-3.2.jar
index 9d91bd0..ccdbf94 100644 (file)
Binary files a/j8lib/flatlaf-extras-3.1.1.jar and b/j11lib/flatlaf-extras-3.2.jar differ
index 7c99c93..3fc97b5 100644 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
index 0000000..92eed53
Binary files /dev/null and b/j11lib/javaparser-core-3.25.5.jar differ
diff --git a/j11lib/slf4j-api-1.7.32.jar b/j11lib/slf4j-api-1.7.32.jar
deleted file mode 100644 (file)
index b16a078..0000000
Binary files a/j11lib/slf4j-api-1.7.32.jar and /dev/null differ
diff --git a/j11lib/slf4j-api-1.7.36.jar b/j11lib/slf4j-api-1.7.36.jar
new file mode 100644 (file)
index 0000000..7d3ce68
Binary files /dev/null and b/j11lib/slf4j-api-1.7.36.jar differ
diff --git a/j11lib/slf4j-nop-1.7.36.jar b/j11lib/slf4j-nop-1.7.36.jar
new file mode 100644 (file)
index 0000000..734ad96
Binary files /dev/null and b/j11lib/slf4j-nop-1.7.36.jar differ
diff --git a/j8lib/flatlaf-3.1.1.jar b/j8lib/flatlaf-3.1.1.jar
deleted file mode 100644 (file)
index 2b13cdd..0000000
Binary files a/j8lib/flatlaf-3.1.1.jar and /dev/null differ
diff --git a/j8lib/flatlaf-3.2.jar b/j8lib/flatlaf-3.2.jar
new file mode 100644 (file)
index 0000000..450c1e8
Binary files /dev/null and b/j8lib/flatlaf-3.2.jar differ
similarity index 52%
rename from j11lib/flatlaf-extras-3.1.1.jar
rename to j8lib/flatlaf-extras-3.2.jar
index 9d91bd0..ccdbf94 100644 (file)
Binary files a/j11lib/flatlaf-extras-3.1.1.jar and b/j8lib/flatlaf-extras-3.2.jar differ
index 7c99c93..3fc97b5 100644 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
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 (file)
index 0000000..92eed53
Binary files /dev/null and b/j8lib/javaparser-core-3.25.5.jar differ
diff --git a/j8lib/slf4j-api-1.7.32.jar b/j8lib/slf4j-api-1.7.32.jar
deleted file mode 100644 (file)
index b16a078..0000000
Binary files a/j8lib/slf4j-api-1.7.32.jar and /dev/null differ
diff --git a/j8lib/slf4j-api-1.7.36.jar b/j8lib/slf4j-api-1.7.36.jar
new file mode 100644 (file)
index 0000000..7d3ce68
Binary files /dev/null and b/j8lib/slf4j-api-1.7.36.jar differ
diff --git a/j8lib/slf4j-nop-1.7.36.jar b/j8lib/slf4j-nop-1.7.36.jar
new file mode 100644 (file)
index 0000000..734ad96
Binary files /dev/null and b/j8lib/slf4j-nop-1.7.36.jar differ
index 924b9cb..c3c8589 100644 (file)
@@ -363,6 +363,7 @@ label.sequences_from = Sequences from {0}
 label.successfully_loaded_file  = Successfully loaded file {0}
 label.successfully_loaded_matrix  = Successfully loaded score matrix {0}
 label.successfully_saved_to_file_in_format = Successfully saved to file: {0} in {1} format.
+label.successfully_printed_to_stdout_in_format = Successfully printed to STDOUT in {0} format.
 label.copied_sequences_to_clipboard = Copied {0} sequences to clipboard.
 label.check_file_matches_sequence_ids_alignment = Check that the file matches sequence IDs in the alignment.
 label.problem_reading_tcoffee_score_file = Problem reading T-COFFEE score file
@@ -1245,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= >> 
@@ -1462,4 +1463,9 @@ action.show_tree_for_matrix_tooltip = Opens a tree viewer to display the average
 action.cluster_matrix = Cluster matrix
 action.clustering_matrix_for = Calculating tree for matrix {0} and clustering at {1}
 action.cluster_matrix_tooltip = Computes an average distance tree for the matrix and displays it
-
+label.all_known_alignment_files = All known alignment files
+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)
index 150a407..a0b9292 100644 (file)
@@ -326,6 +326,7 @@ label.sequences_from = Secuencias de {0}
 label.successfully_loaded_file  = Fichero cargado exitosamente {0}
 label.successfully_loaded_matrix  = Matriz cargada exitosamente {0}
 label.successfully_saved_to_file_in_format = Guardado exitosamente en el fichero: {0} en formato {1}.
+label.successfully_printed_to_stdout_in_format = Impresso exitosamente al STDOUT en formato {0}.
 label.copied_sequences_to_clipboard = Copiadas {0} secuencias en el portapapeles.
 label.check_file_matches_sequence_ids_alignment = Comprobar que el fichero coincide con el ID de la secuencia en el alineamiento.
 label.problem_reading_tcoffee_score_file = Problema de lectura del fichero de puntuaciones T-COFFEE
@@ -1436,3 +1437,8 @@ label.add_pae_matrix_file = A
 label.nothing_selected = Nada seleccionado
 prompt.analytics_title = Jalview Estadísticas de Uso
 prompt.analytics = Â¿Quiere ayudar a mejorar Jalview habilitando la recopilación de estadísticas de uso con análisis Plausible?\nPuede habilitar o deshabilitar el seguimiento de uso en las preferencias.
+label.all_known_alignment_files = Todos los archivos de alineación conocidos
+label.command_line_arguments = Argumentos de línea de comando
+warning.using_old_command_line_arguments = Parece que estás utilizando argumentos antiguos de línea de comando. Estos ahora están en desuso y se eliminarán en una versión futura de Jalview.\nObtenga más información sobre los nuevos argumentos de la línea de comando en\n
+warning.using_mixed_command_line_arguments = Jalview no puede utilizar argumentos de línea de comando antiguos (-arg) y nuevos (--arg). Verifique los argumentos de su línea de comando.\ne.g. {0} y {1}
+warning.the_following_errors = Se produjeron los siguientes errores y advertencias al procesar archivos:
index adaa3ee..c5d35fb 100755 (executable)
                                                <xs:attribute name="fontName" type="xs:string" />
                                                <xs:attribute name="fontSize" type="xs:int" />
                                                <xs:attribute name="fontStyle" type="xs:int" />
+                                               <xs:attribute name="idWidth" type="xs:int" />
+                                               <xs:attribute name="idWidthManuallyAdjusted" type="xs:boolean" />
                                                <xs:attribute name="scaleProteinAsCdna" type="xs:boolean" use="optional" default="true" />
                                                <xs:attribute name="viewName" type="xs:string" />
                                                <xs:attribute name="sequenceSetId" type="xs:string" />
index fedbae3..364bfbe 100755 (executable)
            xjc schemas/jalview.xsd -d src -p jalview.xml.binding.jalview
        Note this also generates code for included schemas
 -->
-<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:vamsas="www.vamsas.ac.uk/jalview/version2" targetNamespace="www.vamsas.ac.uk/jalview/version2" elementFormDefault="qualified" attributeFormDefault="unqualified">
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
+       xmlns:vamsas="www.vamsas.ac.uk/jalview/version2"
+       targetNamespace="www.vamsas.ac.uk/jalview/version2"
+       elementFormDefault="qualified" attributeFormDefault="unqualified">
        <xs:complexType name="VAMSAS">
                <xs:sequence>
-                       <xs:element name="Tree" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
-                       <xs:element ref="vamsas:SequenceSet" minOccurs="0" maxOccurs="unbounded"/>
+                       <xs:element name="Tree" type="xs:string" minOccurs="0"
+                               maxOccurs="unbounded" />
+                       <xs:element ref="vamsas:SequenceSet" minOccurs="0"
+                               maxOccurs="unbounded" />
                </xs:sequence>
        </xs:complexType>
        <xs:complexType name="mapListType">
                <xs:annotation>
-                       <xs:documentation> 
-                               developed after mapRangeType from http://www.vamsas.ac.uk/schemas/1.0/vamsasTypes
+                       <xs:documentation>
+                               developed after mapRangeType from
+                               http://www.vamsas.ac.uk/schemas/1.0/vamsasTypes
                        </xs:documentation>
                        <xs:documentation>
-                               This effectively represents a java.util.MapList object
+                               This effectively represents a java.util.MapList
+                               object
                        </xs:documentation>
                </xs:annotation>
                <xs:sequence>
-                       <xs:element name="mapListFrom" minOccurs="0" maxOccurs="unbounded">
+                       <xs:element name="mapListFrom" minOccurs="0"
+                               maxOccurs="unbounded">
                                <xs:annotation>
-                                       <xs:documentation> a region from start to end inclusive</xs:documentation>
+                                       <xs:documentation> a region from start to end inclusive
+                                       </xs:documentation>
                                </xs:annotation>
                                <xs:complexType>
-                                       <xs:attribute name="start" type="xs:int" use="required"/>
-                                       <xs:attribute name="end" type="xs:int" use="required"/>
+                                       <xs:attribute name="start" type="xs:int"
+                                               use="required" />
+                                       <xs:attribute name="end" type="xs:int" use="required" />
                                </xs:complexType>
-                       </xs:element>                                   
-                       <xs:element name="mapListTo" minOccurs="0" maxOccurs="unbounded">
+                       </xs:element>
+                       <xs:element name="mapListTo" minOccurs="0"
+                               maxOccurs="unbounded">
                                <xs:annotation>
-                                       <xs:documentation> a region from start to end inclusive</xs:documentation>
+                                       <xs:documentation> a region from start to end inclusive
+                                       </xs:documentation>
                                </xs:annotation>
                                <xs:complexType>
-                                       <xs:attribute name="start" type="xs:int" use="required"/>
-                                       <xs:attribute name="end" type="xs:int" use="required"/>
+                                       <xs:attribute name="start" type="xs:int"
+                                               use="required" />
+                                       <xs:attribute name="end" type="xs:int" use="required" />
                                </xs:complexType>
-                       </xs:element>                                   
+                       </xs:element>
                </xs:sequence>
-               <xs:attribute name="mapFromUnit" type="xs:positiveInteger" use="required">
+               <xs:attribute name="mapFromUnit"
+                       type="xs:positiveInteger" use="required">
                        <xs:annotation>
-                               <xs:documentation>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. </xs:documentation>
+                               <xs:documentation>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.
+                               </xs:documentation>
                        </xs:annotation>
                </xs:attribute>
-               <xs:attribute name="mapToUnit" type="xs:positiveInteger" use="required">
+               <xs:attribute name="mapToUnit" type="xs:positiveInteger"
+                       use="required">
                        <xs:annotation>
-                               <xs:documentation>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. </xs:documentation>
+                               <xs:documentation>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.
+                               </xs:documentation>
                        </xs:annotation>
                </xs:attribute>
        </xs:complexType>
                <xs:complexType>
                        <xs:annotation>
                                <xs:documentation>
-                                       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).
                                </xs:documentation>
                        </xs:annotation>
                        <xs:complexContent>
                                <xs:extension base="vamsas:mapListType">
                                        <xs:sequence>
                                                <xs:choice minOccurs="0" maxOccurs="1">
-                                                       <xs:element ref="vamsas:Sequence"/>
+                                                       <xs:element ref="vamsas:Sequence" />
                                                        <xs:element name="dseqFor">
                                                                <xs:simpleType>
                                                                        <xs:restriction base="xs:string">
                                                                                <xs:annotation>
-                                                                                       <xs:documentation>The sequence whose dataset sequence is to be referenced here</xs:documentation>
+                                                                                       <xs:documentation>The sequence whose dataset sequence is to
+                                                                                               be referenced here
+                                                                                       </xs:documentation>
                                                                                </xs:annotation>
                                                                        </xs:restriction>
                                                                </xs:simpleType>
                                                        </xs:element>
                                                </xs:choice>
                                        </xs:sequence>
-                                       <xs:attribute name="mappingType" type="xs:string" use="optional">
+                                       <xs:attribute name="mappingType" type="xs:string"
+                                               use="optional">
                                                <xs:annotation>
-                                                       <xs:documentation>Biotype of the mapping e.g. CdsToPeptide</xs:documentation>
+                                                       <xs:documentation>Biotype of the mapping e.g. CdsToPeptide
+                                                       </xs:documentation>
                                                </xs:annotation>
                                        </xs:attribute>
                                </xs:extension>
-                       </xs:complexContent>    
+                       </xs:complexContent>
                </xs:complexType>
        </xs:element>
        <xs:element name="AlcodonFrame">
                <xs:complexType>
                        <xs:sequence>
-                               <xs:element name="alcodon" minOccurs="0" maxOccurs="unbounded">
+                               <xs:element name="alcodon" minOccurs="0"
+                                       maxOccurs="unbounded">
                                        <xs:complexType>
                                                <xs:annotation>
                                                        <xs:documentation>
-                                                               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).
                                                        </xs:documentation>
                                                </xs:annotation>
-                                               <xs:attribute name="pos1" type="xs:integer" use="optional"/>
-                                               <xs:attribute name="pos2" type="xs:integer" use="optional"/>
-                                               <xs:attribute name="pos3" type="xs:integer" use="optional"/>
+                                               <xs:attribute name="pos1" type="xs:integer"
+                                                       use="optional" />
+                                               <xs:attribute name="pos2" type="xs:integer"
+                                                       use="optional" />
+                                               <xs:attribute name="pos3" type="xs:integer"
+                                                       use="optional" />
                                        </xs:complexType>
                                </xs:element>
-                               <xs:element name="alcodMap" minOccurs="0" maxOccurs="unbounded">
+                               <xs:element name="alcodMap" minOccurs="0"
+                                       maxOccurs="unbounded">
                                        <xs:complexType>
                                                <xs:sequence>
-                                                       <xs:element ref="vamsas:Mapping" maxOccurs="1" minOccurs="1">
+                                                       <xs:element ref="vamsas:Mapping" maxOccurs="1"
+                                                               minOccurs="1">
                                                                <xs:annotation>
                                                                        <xs:documentation>
-                                                                               a Mapping entry and an associated protein sequence
+                                                                               a Mapping entry and an associated protein
+                                                                               sequence
                                                                        </xs:documentation>
                                                                </xs:annotation>
                                                        </xs:element>
                                                </xs:sequence>
-                                               <xs:attribute name="dnasq" type="xs:string" use="required">
+                                               <xs:attribute name="dnasq" type="xs:string"
+                                                       use="required">
                                                        <xs:annotation>
                                                                <xs:documentation>
-                                                                       internal jalview id for the dnasq for this mapping.
+                                                                       internal jalview id for the dnasq for this
+                                                                       mapping.
                                                                </xs:documentation>
                                                        </xs:annotation>
                                                </xs:attribute>
                                        </xs:complexType>
-                                       
+
                                </xs:element>
-                               
+
                        </xs:sequence>
                </xs:complexType>
        </xs:element>
                        <xs:complexContent>
                                <xs:extension base="vamsas:SequenceType">
                                        <xs:sequence>
-                                               <xs:element name="DBRef" minOccurs="0" maxOccurs="unbounded">
+                                               <xs:element name="DBRef" minOccurs="0"
+                                                       maxOccurs="unbounded">
                                                        <xs:complexType>
                                                                <xs:sequence>
-                                                                       <xs:element ref="vamsas:Mapping" minOccurs="0" maxOccurs="1"/>
-                                                               </xs:sequence>                                                                                                  
-                                                               <xs:attribute name="source" type="xs:string"/>
-                                                               <xs:attribute name="version" type="xs:string"/>
-                                                               <xs:attribute name="accessionId" type="xs:string"/>
-                                                               <xs:attribute name="locus" type="xs:boolean" default="false">
+                                                                       <xs:element ref="vamsas:Mapping" minOccurs="0"
+                                                                               maxOccurs="1" />
+                                                               </xs:sequence>
+                                                               <xs:attribute name="source" type="xs:string" />
+                                                               <xs:attribute name="version" type="xs:string" />
+                                                               <xs:attribute name="accessionId" type="xs:string" />
+                                                               <xs:attribute name="locus" type="xs:boolean"
+                                                                       default="false">
                                                                        <xs:annotation>
                                                                                <xs:documentation>
-                                                                                       true for gene locus mapping, source=species, version=assembly, accession=chromosome
+                                                                                       true for gene locus mapping, source=species,
+                                                                                       version=assembly, accession=chromosome
                                                                                </xs:documentation>
                                                                        </xs:annotation>
                                                                </xs:attribute>
-                                                               <xs:attribute name="canonical" type="xs:boolean" default="false">
+                                                               <xs:attribute name="canonical" type="xs:boolean"
+                                                                       default="false">
                                                                        <xs:annotation>
                                                                                <xs:documentation>
-                                                                                       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)
                                                                                </xs:documentation>
                                                                        </xs:annotation>
                                                                </xs:attribute>
                                                        </xs:complexType>
                                                </xs:element>
                                        </xs:sequence>
-                                       <xs:attribute name="dsseqid" type="xs:string" use="optional">
+                                       <xs:attribute name="dsseqid" type="xs:string"
+                                               use="optional">
                                                <xs:annotation>
                                                        <xs:documentation>
-                                                               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.
                                                        </xs:documentation>
                                                </xs:annotation>
                                        </xs:attribute>
-                                       <xs:attribute name="biotype" type="xs:string" use="optional">
+                                       <xs:attribute name="biotype" type="xs:string"
+                                               use="optional">
                                                <xs:annotation>
                                                        <xs:documentation>
                                                                Biotype of the sequence (if known)
                                                <xs:attribute name="colour" type="xs:int" />
                                        </xs:complexType>
                                </xs:element>
-                               <xs:element name="contactmatrix" type="vamsas:MatrixType"
-                                       maxOccurs="unbounded" minOccurs="0">
+                               <xs:element name="contactmatrix"
+                                       type="vamsas:MapOnAMatrixType" maxOccurs="unbounded" minOccurs="0">
                                </xs:element>
-                               <xs:element name="property" type="vamsas:property" minOccurs="0" maxOccurs="unbounded"/>
+                               <xs:element name="property" type="vamsas:property"
+                                       minOccurs="0" maxOccurs="unbounded" />
                        </xs:sequence>
-                       <xs:attribute name="graph" type="xs:boolean" use="required" />
-                       <xs:attribute name="graphType" type="xs:int" use="optional" />
+                       <xs:attribute name="graph" type="xs:boolean"
+                               use="required" />
+                       <xs:attribute name="graphType" type="xs:int"
+                               use="optional" />
                        <xs:attribute name="sequenceRef" type="xs:string"
                                use="optional" />
                        <xs:attribute name="groupRef" type="xs:string"
                                use="optional" />
                        <xs:attribute name="graphGroup" type="xs:int"
                                use="optional" />
-                       <xs:attribute name="graphHeight" type="xs:int" use="optional">
-                       <xs:annotation><xs:documentation>height in pixels for the graph if this is a graph-type annotation.</xs:documentation></xs:annotation></xs:attribute>
+                       <xs:attribute name="graphHeight" type="xs:int"
+                               use="optional">
+                               <xs:annotation>
+                                       <xs:documentation>height in pixels for the graph if this is a
+                                               graph-type annotation.
+                                       </xs:documentation>
+                               </xs:annotation>
+                       </xs:attribute>
                        <xs:attribute name="id" type="xs:string" use="optional" />
                        <xs:attribute name="scoreOnly" type="xs:boolean"
                                use="optional" default="false" />
-                       <xs:attribute name="score" type="xs:double" use="optional" />
+                       <xs:attribute name="score" type="xs:double"
+                               use="optional" />
                        <xs:attribute name="visible" type="xs:boolean"
                                use="optional" />
                        <xs:attribute name="centreColLabels" type="xs:boolean"
                                use="optional" />
 
 
-                       <xs:attribute name="autoCalculated" type="xs:boolean" use="optional" default="false">
-                       <xs:annotation><xs:documentation>is an autocalculated annotation row</xs:documentation>
-                       </xs:annotation></xs:attribute>
-                       <xs:attribute name="belowAlignment" type="xs:boolean" use="optional" default="true">
-                       <xs:annotation><xs:documentation>is to be shown below the alignment - introduced in Jalview 2.8 for visualizing T-COFFEE alignment scores</xs:documentation></xs:annotation></xs:attribute>
-                       <xs:attribute name="calcId" type="xs:string" use="optional">
-                       <xs:annotation><xs:documentation>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.</xs:documentation></xs:annotation>
+                       <xs:attribute name="autoCalculated" type="xs:boolean"
+                               use="optional" default="false">
+                               <xs:annotation>
+                                       <xs:documentation>is an autocalculated annotation row
+                                       </xs:documentation>
+                               </xs:annotation>
+                       </xs:attribute>
+                       <xs:attribute name="belowAlignment" type="xs:boolean"
+                               use="optional" default="true">
+                               <xs:annotation>
+                                       <xs:documentation>is to be shown below the alignment - introduced
+                                               in Jalview 2.8 for visualizing T-COFFEE alignment scores
+                                       </xs:documentation>
+                               </xs:annotation>
+                       </xs:attribute>
+                       <xs:attribute name="calcId" type="xs:string"
+                               use="optional">
+                               <xs:annotation>
+                                       <xs:documentation>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.
+                                       </xs:documentation>
+                               </xs:annotation>
                        </xs:attribute>
                </xs:complexType>
-       </xs:element>   
+       </xs:element>
        <xs:element name="SequenceSet">
                <xs:complexType>
                        <xs:sequence>
-                               <xs:element ref="vamsas:Sequence" minOccurs="0" maxOccurs="unbounded"/>
-                               <xs:element ref="vamsas:Annotation" minOccurs="0" maxOccurs="unbounded"/>
-                               <xs:element name="sequenceSetProperties" minOccurs="0" maxOccurs="unbounded">
+                               <xs:element ref="vamsas:Sequence" minOccurs="0"
+                                       maxOccurs="unbounded" />
+                               <xs:element ref="vamsas:Annotation" minOccurs="0"
+                                       maxOccurs="unbounded" />
+                               <xs:element name="sequenceSetProperties" minOccurs="0"
+                                       maxOccurs="unbounded">
                                        <xs:complexType>
-                                               <xs:attribute name="key" type="xs:string"/>
-                                               <xs:attribute name="value" type="xs:string"/>
+                                               <xs:attribute name="key" type="xs:string" />
+                                               <xs:attribute name="value" type="xs:string" />
                                        </xs:complexType>
                                </xs:element>
-                               <xs:element ref="vamsas:AlcodonFrame" minOccurs="0" maxOccurs="unbounded"/>
+                               <xs:element ref="vamsas:AlcodonFrame" minOccurs="0"
+                                       maxOccurs="unbounded" />
+                               <xs:element name="Matrix" type="vamsas:MatrixType"
+                                       minOccurs="0" maxOccurs="unbounded">
+                                       <xs:annotation>
+                                               <xs:documentation>Matrices referred to by this set of sequences.
+                                               </xs:documentation>
+                                       </xs:annotation>
+                               </xs:element>
                        </xs:sequence>
-                       <xs:attribute name="gapChar" type="xs:string" use="required"/>
-                       <xs:attribute name="datasetId" type="xs:string" use="optional">
+                       <xs:attribute name="gapChar" type="xs:string"
+                               use="required" />
+                       <xs:attribute name="datasetId" type="xs:string"
+                               use="optional">
                                <xs:annotation>
                                        <xs:documentation>
-                                               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.
                                        </xs:documentation>
                                </xs:annotation>
                        </xs:attribute>
        <xs:element name="annotationElement">
                <xs:complexType>
                        <xs:sequence>
-                               <xs:element name="displayCharacter" type="xs:string" minOccurs="0"/>
-                               <xs:element name="description" type="xs:string" minOccurs="0"/>
+                               <xs:element name="displayCharacter" type="xs:string"
+                                       minOccurs="0" />
+                               <xs:element name="description" type="xs:string"
+                                       minOccurs="0" />
                                <xs:element name="secondaryStructure" minOccurs="0">
                                        <xs:simpleType>
                                                <xs:restriction base="xs:string">
-                                                       <xs:length value="1"/>
+                                                       <xs:length value="1" />
                                                </xs:restriction>
                                        </xs:simpleType>
                                </xs:element>
-                               <xs:element name="value" type="xs:float" minOccurs="0"/>
+                               <xs:element name="value" type="xs:float" minOccurs="0" />
                        </xs:sequence>
-                       <xs:attribute name="position" type="xs:int" use="required"/>
-                       <xs:attribute name="colour" type="xs:int" use="optional"/>
+                       <xs:attribute name="position" type="xs:int"
+                               use="required" />
+                       <xs:attribute name="colour" type="xs:int" use="optional" />
                </xs:complexType>
        </xs:element>
        <xs:complexType name="SequenceType">
                <xs:sequence>
-                       <xs:element name="sequence" type="xs:string" minOccurs="0"/>
-                       <xs:element name="name" type="xs:string" minOccurs="0"/>
+                       <xs:element name="sequence" type="xs:string" minOccurs="0" />
+                       <xs:element name="name" type="xs:string" minOccurs="0" />
                </xs:sequence>
-               <xs:attribute name="id" type="xs:string"/>
-               <xs:attribute name="description" type="xs:string"/>
+               <xs:attribute name="id" type="xs:string" />
+               <xs:attribute name="description" type="xs:string" />
        </xs:complexType>
        <xs:complexType name="MatrixType">
+               <xs:annotation>
+                       <xs:documentation>Represents matrix data imported to Jalview, and the
+                               results of any derived calculations (independent of a particular
+                               view
+                               on the matrix).
+                       </xs:documentation>
+               </xs:annotation>
                <xs:sequence>
                        <xs:element name="elements" type="xs:string" minOccurs="1"
                                maxOccurs="1">
                                <xs:annotation>
                                        <xs:documentation>serialised representation of matrix as one or
-                                               more sets of comma separated values</xs:documentation>
+                                               more sets of comma separated values
+                                       </xs:documentation>
                                </xs:annotation>
                        </xs:element>
                        <xs:element name="groups" type="xs:string" minOccurs="0"
                        </xs:element>
                        <xs:element name="property" type="vamsas:property"
                                minOccurs="0" maxOccurs="unbounded" />
-                       <xs:element name="mapping" type="vamsas:mapListType"
-                               minOccurs="0" maxOccurs="1">
-                       <xs:annotation>
-                               <xs:documentation>mapping from the matrix row and column positions to
-                                       associated reference frame</xs:documentation>
-                               </xs:annotation>
-                       </xs:element>
                </xs:sequence>
 
                <xs:attribute name="type" type="xs:string" use="required" />
                        use="optional" />
                <xs:attribute name="cutHeight" type="xs:double"
                        use="optional" />
-               <xs:attribute name="id" type="xs:string" use="optional" />
+               <xs:attribute name="id" type="xs:string" use="required" />
 
        </xs:complexType>
+       <xs:complexType name="MapOnAMatrixType">
+               <xs:annotation>
+                       <xs:documentation>Defines a mapping from the local frame to a matrix
+                               and its associated data specified by MatrixType
+                       </xs:documentation>
+               </xs:annotation>
+               <xs:sequence>
+                       <xs:element name="property" type="vamsas:property"
+                               minOccurs="0" maxOccurs="unbounded" />
+                       <xs:element name="mapping" type="vamsas:mapListType"
+                               minOccurs="0" maxOccurs="1">
+                               <xs:annotation>
+                                       <xs:documentation>mapping from the matrix row and column positions
+                                               to
+                                               associated reference frame
+                                       </xs:documentation>
+                               </xs:annotation>
+                       </xs:element>
+               </xs:sequence>
+
+               <xs:attribute name="matrix" type="xs:string"
+                       use="required">
+
+                       <xs:annotation>
+                               <xs:documentation>reference to the matrix type this Map refers to
+                               </xs:documentation>
+                       </xs:annotation>
+               </xs:attribute>
+               <xs:attribute name="id" type="xs:string" use="optional" />
+       </xs:complexType>
        <xs:complexType name="property">
                <xs:attribute name="name" type="xs:string" />
                <xs:attribute name="value" type="xs:string" />
        </xs:complexType>
-                               
-       
+
+
 </xs:schema>
index b1505d6..6967885 100755 (executable)
@@ -147,7 +147,7 @@ public class AAFrequency
       {
         if (sequences[row] == null)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "WARNING: Consensus skipping null sequence - possible race condition.");
           continue;
         }
@@ -188,7 +188,7 @@ public class AAFrequency
     }
     return new Profiles(result);
     // long elapsed = System.currentTimeMillis() - now;
-    // System.out.println(elapsed);
+    // jalview.bin.Console.outPrintln(elapsed);
   }
 
   /**
@@ -285,7 +285,7 @@ public class AAFrequency
               ' ', value);
     }
     // long elapsed = System.currentTimeMillis() - now;
-    // System.out.println(-elapsed);
+    // jalview.bin.Console.outPrintln(-elapsed);
   }
 
   /**
index 02b3f41..e1d5669 100755 (executable)
@@ -826,7 +826,7 @@ public class AlignSeq
       }
     }
 
-    System.out.println(max + " " + min);
+    jalview.bin.Console.outPrintln(max + " " + min);
 
     for (int i = 0; i < n; i++)
     {
@@ -835,12 +835,12 @@ public class AlignSeq
         int x = psize * i;
         int y = psize * j;
 
-        // System.out.println(mat[i][j]);
+        // jalview.bin.Console.outPrintln(mat[i][j]);
         float score = (float) (mat[i][j] - min) / (float) (max - min);
         g.setColor(new Color(score, 0, 0));
         g.fillRect(x, y, psize, psize);
 
-        // System.out.println(x + " " + y + " " + score);
+        // jalview.bin.Console.outPrintln(x + " " + y + " " + score);
       }
     }
   }
@@ -983,7 +983,7 @@ public class AlignSeq
             bestm = msq;
           }
         }
-        // System.out.println("Best Score for " + (matches.size() + 1) + " :"
+        // jalview.bin.Console.outPrintln("Best Score for " + (matches.size() + 1) + " :"
         // + bestscore);
         matches.add(bestm);
         aligns.add(bestaseq);
index b02d49c..b037336 100755 (executable)
@@ -453,7 +453,7 @@ public class AlignmentSorter
 
       if (tmp.size() != nSeq)
       {
-        System.err.println("WARNING: tmp.size()=" + tmp.size() + " != nseq="
+        jalview.bin.Console.errPrintln("WARNING: tmp.size()=" + tmp.size() + " != nseq="
                 + nSeq
                 + " in getOrderByTree - tree contains sequences not in alignment");
       }
@@ -714,7 +714,7 @@ public class AlignmentSorter
       String msg = String.format(
               "Implementation Error - sortByFeature method must be either '%s' or '%s'",
               FEATURE_SCORE, FEATURE_DENSITY);
-      System.err.println(msg);
+      jalview.bin.Console.errPrintln(msg);
       return;
     }
 
@@ -832,7 +832,7 @@ public class AlignmentSorter
           {
             // int nf = (feats[i] == null) ? 0
             // : ((SequenceFeature[]) feats[i]).length;
-            // // System.err.println("Sorting on Score: seq " +
+            // // jalview.bin.Console.errPrintln("Sorting on Score: seq " +
             // seqs[i].getName()
             // + " Feats: " + nf + " Score : " + scores[i]);
           }
@@ -847,7 +847,7 @@ public class AlignmentSorter
         int featureCount = feats[i] == null ? 0
                 : ((SequenceFeature[]) feats[i]).length;
         scores[i] = featureCount;
-        // System.err.println("Sorting on Density: seq "+seqs[i].getName()+
+        // jalview.bin.Console.errPrintln("Sorting on Density: seq "+seqs[i].getName()+
         // " Feats: "+featureCount+" Score : "+scores[i]);
       }
       QuickSort.sortByDouble(scores, seqs, sortByFeatureAscending);
index 6ab49b2..f470dc6 100644 (file)
@@ -547,7 +547,7 @@ public class AlignmentUtils
       if (translated == null || !(aaRes == translated.charAt(0)))
       {
         // debug
-        // System.out.println(("Mismatch at " + i + "/" + aaResidue + ": "
+        // jalview.bin.Console.outPrintln(("Mismatch at " + i + "/" + aaResidue + ": "
         // + codon + "(" + translated + ") != " + aaRes));
         return false;
       }
@@ -698,7 +698,7 @@ public class AlignmentUtils
          * unmapped position; treat like a gap
          */
         sourceGapMappedLength += ratio;
-        // System.err.println("Can't align: no codon mapping to residue "
+        // jalview.bin.Console.errPrintln("Can't align: no codon mapping to residue "
         // + sourceDsPos + "(" + sourceChar + ")");
         // return;
         continue;
@@ -883,7 +883,7 @@ public class AlignmentUtils
   {
     if (protein.isNucleotide() || !dna.isNucleotide())
     {
-      System.err.println("Wrong alignment type in alignProteinAsDna");
+      jalview.bin.Console.errPrintln("Wrong alignment type in alignProteinAsDna");
       return 0;
     }
     List<SequenceI> unmappedProtein = new ArrayList<>();
@@ -908,7 +908,7 @@ public class AlignmentUtils
   {
     if (protein.isNucleotide() || !dna.isNucleotide())
     {
-      System.err.println("Wrong alignment type in alignProteinAsDna");
+      jalview.bin.Console.errPrintln("Wrong alignment type in alignProteinAsDna");
       return 0;
     }
     // todo: implement this
@@ -988,7 +988,7 @@ public class AlignmentUtils
                           .getLength() == mappedFromLength - 1);
           if (cdsLength != mappedToLength && !addStopCodon)
           {
-            System.err.println(String.format(
+            jalview.bin.Console.errPrintln(String.format(
                     "Can't align cds as protein (length mismatch %d/%d): %s",
                     cdsLength, mappedToLength, cdsSeq.getName()));
           }
@@ -1162,7 +1162,7 @@ public class AlignmentUtils
         AlignedCodon codon = sequenceCodon.getValue();
         if (codon.peptideCol > 1)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Problem mapping protein with >1 unmapped start positions: "
                           + seq.getName());
         }
@@ -2770,7 +2770,7 @@ public class AlignmentUtils
                 fromRange[i + 1]);
         if (range == null)
         {
-          System.err.println("Error in mapping " + seqMap + " from "
+          jalview.bin.Console.errPrintln("Error in mapping " + seqMap + " from "
                   + fromSeq.getName());
           return false;
         }
index cbc4dca..5bb0b09 100755 (executable)
@@ -243,13 +243,13 @@ public class Conservation
       }
       else
       {
-        System.out.println("SEQUENCE HAS BEEN DELETED!!!");
+        jalview.bin.Console.outPrintln("SEQUENCE HAS BEEN DELETED!!!");
       }
     }
     else
     {
       // JBPNote INFO level debug
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "ERROR: calcSeqNum called with out of range sequence index for Alignment\n");
     }
   }
@@ -711,7 +711,7 @@ public class Conservation
       // tmp = ((max - tmp) * (size - cons2[j][23])) / size;
       tmp = ((max - tmp) * (size - cons2GapCounts[j])) / size;
 
-      // System.out.println(tmp+ " " + j);
+      // jalview.bin.Console.outPrintln(tmp+ " " + j);
       quality.setElementAt(Double.valueOf(tmp), j);
 
       if (tmp > newmax)
index 9b90ca5..41582b4 100644 (file)
@@ -293,7 +293,7 @@ public class CrossRef
             if (matchInDataset != null && xref.getMap().getTo() != null
                     && matchInDataset != xref.getMap().getTo())
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Implementation problem (reopen JAL-2154): CrossRef.findInDataset seems to have recovered a different sequence than the one explicitly mapped for xref."
                               + "Found:" + matchInDataset + "\nExpected:"
                               + xref.getMap().getTo() + "\nFor xref:"
@@ -424,7 +424,7 @@ public class CrossRef
       retrieved = sftch.getSequences(sourceRefs, !fromDna);
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Problem whilst retrieving cross references for Sequence : "
                       + seq.getName());
       e.printStackTrace();
@@ -607,7 +607,7 @@ public class CrossRef
                 String msg = "Mapping updated from " + ms.getName()
                         + " to retrieved crossreference "
                         + matched.getName();
-                System.out.println(msg);
+                jalview.bin.Console.outPrintln(msg);
 
                 List<DBRefEntry> toRefs = map.getTo().getDBRefs();
                 if (toRefs != null)
@@ -662,7 +662,7 @@ public class CrossRef
               cf.addMap(retrievedSequence, map.getTo(), map.getMap());
             } catch (Exception e)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Exception when consolidating Mapped sequence set...");
               e.printStackTrace(System.err);
             }
@@ -1029,7 +1029,7 @@ public class CrossRef
     }
     if (dataset.getSequences() == null)
     {
-      System.err.println("Empty dataset sequence set - NO VECTOR");
+      jalview.bin.Console.errPrintln("Empty dataset sequence set - NO VECTOR");
       return false;
     }
     List<SequenceI> ds = dataset.getSequences();
@@ -1041,7 +1041,7 @@ public class CrossRef
         {
           if (nxt.getDatasetSequence() != null)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Implementation warning: CrossRef initialised with a dataset alignment with non-dataset sequences in it! ("
                             + nxt.getDisplayId(true) + " has ds reference "
                             + nxt.getDatasetSequence().getDisplayId(true)
index 5dcf212..aa71eb7 100644 (file)
@@ -653,7 +653,7 @@ public class Dna
       if (rf != 0)
       {
         final String errMsg = "trimming contigs for incomplete terminal codon.";
-        System.err.println(errMsg);
+        jalview.bin.Console.errPrintln(errMsg);
         // map and trim contigs to ORF region
         vc = scontigs.length - 1;
         lastnpos = vismapping.shift(lastnpos); // place npos in context of
index 133cb3a..4c826b2 100644 (file)
@@ -140,7 +140,7 @@ public final class GeneticCodes
       InputStream is = getClass().getResourceAsStream(fileName);
       if (is == null)
       {
-        System.err.println("Resource file not found: " + fileName);
+        jalview.bin.Console.errPrintln("Resource file not found: " + fileName);
         return;
       }
       BufferedReader dataIn = new BufferedReader(new InputStreamReader(is));
@@ -166,7 +166,7 @@ public final class GeneticCodes
     }
     if (codeTables.isEmpty())
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "No genetic code tables loaded, check format of file "
                       + fileName);
     }
@@ -190,7 +190,7 @@ public final class GeneticCodes
       InputStream is = getClass().getResourceAsStream(fileName);
       if (is == null)
       {
-        System.err.println("Resource file not found: " + fileName);
+        jalview.bin.Console.errPrintln("Resource file not found: " + fileName);
         return;
       }
       BufferedReader dataIn = new BufferedReader(new InputStreamReader(is));
@@ -208,7 +208,7 @@ public final class GeneticCodes
           }
           else
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Unexpected data in " + fileName + ": " + line);
           }
         }
index 066814e..def5d5a 100644 (file)
@@ -269,7 +269,7 @@ public class Grouping
      * seqs.length) { for (int i = 0; i < seqs.length; i++) { if (!hasScore[i])
      * { scores[i] = (max + i); } else { int nf=(feats[i]==null) ? 0
      * :((SequenceFeature[]) feats[i]).length;
-     * System.err.println("Sorting on Score: seq "+seqs[i].getName()+
+     * jalview.bin.Console.errPrintln("Sorting on Score: seq "+seqs[i].getName()+
      * " Feats: "+nf+" Score : "+scores[i]); } } }
      * 
      * jalview.util.QuickSort.sort(scores, seqs); } else if
@@ -280,7 +280,7 @@ public class Grouping
      * (int i=0;i<seqs.length; i++) { double nf; scores[i] =
      * (0.05+fr*i)+(nf=((feats[i]==null) ? 0.0 :1.0*((SequenceFeature[])
      * feats[i]).length));
-     * System.err.println("Sorting on Density: seq "+seqs[i].getName()+
+     * jalview.bin.Console.errPrintln("Sorting on Density: seq "+seqs[i].getName()+
      * " Feats: "+nf+" Score : "+scores[i]); }
      * jalview.util.QuickSort.sort(scores, seqs); } else { if
      * (method==FEATURE_LABEL) { throw new Error("Not yet implemented."); } } if
index 4b68d93..94b7b99 100644 (file)
@@ -145,7 +145,7 @@ public class ParseProperties
                   ScoreNames[cols] + ((reps > 0) ? "_" + reps : ""),
                   ScoreDescriptions[cols], null);
           an.setScore(score);
-          System.out.println(seqs[i].getName() + " score: '"
+          jalview.bin.Console.outPrintln(seqs[i].getName() + " score: '"
                   + ScoreNames[cols] + "' = " + score); // DEBUG
           an.setSequenceRef(seqs[i]);
           seqs[i].addAlignmentAnnotation(an);
index 9649240..911ee04 100644 (file)
@@ -421,8 +421,8 @@ public class Rna
       final int open = basePair.getBP5();
       final int close = basePair.getBP3();
 
-      // System.out.println("open " + open + " close " + close);
-      // System.out.println("lastclose " + lastclose + " lastopen " + lastopen);
+      // jalview.bin.Console.outPrintln("open " + open + " close " + close);
+      // jalview.bin.Console.outPrintln("lastclose " + lastclose + " lastopen " + lastopen);
 
       // we're moving from right to left based on closing pair
       /*
@@ -441,7 +441,7 @@ public class Rna
       {
         int popen = bps.get(j).getBP5();
 
-        // System.out.println("j " + j + " popen " + popen + " lastopen "
+        // jalview.bin.Console.outPrintln("j " + j + " popen " + popen + " lastopen "
         // +lastopen + " open " + open);
         if ((popen < lastopen) && (popen > open))
         {
index fdca89d..837462f 100755 (executable)
@@ -129,7 +129,7 @@ public class SeqsetUtils
     {
       if (sfeatures != null)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Implementation error: setting dataset sequence for a sequence which has sequence features.\n\tDataset sequence features will not be visible.");
       }
       sq.setDatasetSequence(seqds);
@@ -244,7 +244,7 @@ public class SeqsetUtils
         {
           if (!quiet)
           {
-            System.err.println("Can't find '" + ((String) key)
+            jalview.bin.Console.errPrintln("Can't find '" + ((String) key)
                     + "' in uniquified alignment");
           }
         }
@@ -252,7 +252,7 @@ public class SeqsetUtils
     }
     if (unmatched.size() > 0 && !quiet)
     {
-      System.err.println("Did not find matches for :");
+      jalview.bin.Console.errPrintln("Did not find matches for :");
       for (Enumeration i = unmatched.elements(); i
               .hasMoreElements(); System.out
                       .println(((SequenceI) i.nextElement()).getName()))
index c04df6c..3f5099b 100644 (file)
@@ -148,7 +148,7 @@ public class StructureFrequency
           {
             if (sequences[j] == null)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "WARNING: Consensus skipping null sequence - possible race condition.");
               continue;
             }
index daf7836..a7cbc25 100644 (file)
@@ -214,7 +214,7 @@ public abstract class TreeEngine
   {
     // if (_lycount<_lylimit)
     // {
-    // System.err.println("Warning: depth of _recount greater than number of
+    // jalview.bin.Console.errPrintln("Warning: depth of _recount greater than number of
     // nodes.");
     // }
     if (nd == null)
index 0e57a58..ce79a65 100644 (file)
@@ -353,13 +353,14 @@ public class TreeModel
 
     if ((nd.left() == null) && (nd.right() == null))
     {
-      System.out.println("Leaf = " + ((SequenceI) nd.element()).getName());
-      System.out.println("Dist " + nd.dist);
-      System.out.println("Boot " + nd.getBootstrap());
+       // TODO FIX FOR COLUMN TREES
+      jalview.bin.Console.outPrintln("Leaf = " + ((SequenceI) nd.element()).getName());
+      jalview.bin.Console.outPrintln("Dist " + nd.dist);
+      jalview.bin.Console.outPrintln("Boot " + nd.getBootstrap());
     }
     else
     {
-      System.out.println("Dist " + nd.dist);
+      jalview.bin.Console.outPrintln("Dist " + nd.dist);
       printNode((BinaryNode) nd.left());
       printNode((BinaryNode) nd.right());
     }
@@ -430,7 +431,7 @@ public class TreeModel
 
     if ((nd.left() == null) && (nd.right() == null))
     {
-      nd.height = ((BinaryNode) nd.parent()).height + nd.dist;
+      nd.height = nd.parent().height + nd.dist;
 
       if (nd.height > maxheight)
       {
@@ -445,7 +446,7 @@ public class TreeModel
     {
       if (nd.parent() != null)
       {
-        nd.height = ((BinaryNode) nd.parent()).height + nd.dist;
+        nd.height = nd.parent().height + nd.dist;
       }
       else
       {
@@ -480,10 +481,10 @@ public class TreeModel
     }
     else
     {
-      System.out.println(" name = " + ((SequenceI) nd.element()).getName());
+      jalview.bin.Console.outPrintln(" name = " + ((SequenceI) nd.element()).getName());
     }
 
-    System.out.println(
+    jalview.bin.Console.outPrintln(
             " dist = " + nd.dist + " " + nd.count + " " + nd.height);
   }
 
@@ -513,7 +514,7 @@ public class TreeModel
   {
     // if (_lycount<_lylimit)
     // {
-    // System.err.println("Warning: depth of _recount greater than number of
+    // jalview.bin.Console.errPrintln("Warning: depth of _recount greater than number of
     // nodes.");
     // }
     if (nd == null)
index 9c2f6d1..bcc0855 100644 (file)
@@ -63,7 +63,7 @@ public class FeatureDistanceModel extends DistanceScoreModel
       return instance;
     } catch (InstantiationException | IllegalAccessException e)
     {
-      System.err.println("Error in " + getClass().getName()
+      jalview.bin.Console.errPrintln("Error in " + getClass().getName()
               + ".getInstance(): " + e.getMessage());
       return null;
     } catch (ReflectiveOperationException roe)
index b206339..aa841ac 100644 (file)
@@ -331,12 +331,12 @@ public class ScoreMatrix extends SimilarityScoreModel
   {
     if (c >= symbolIndex.length)
     {
-      System.err.println(String.format(BAD_ASCII_ERROR, c));
+      jalview.bin.Console.errPrintln(String.format(BAD_ASCII_ERROR, c));
       return 0;
     }
     if (d >= symbolIndex.length)
     {
-      System.err.println(String.format(BAD_ASCII_ERROR, d));
+      jalview.bin.Console.errPrintln(String.format(BAD_ASCII_ERROR, d));
       return 0;
     }
 
index ebc9a26..d0f21bd 100644 (file)
@@ -105,7 +105,7 @@ public class ScoreModels
       return sm;
     } catch (IOException e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error reading " + resourcePath + ": " + e.getMessage());
     }
     return null;
@@ -143,7 +143,7 @@ public class ScoreModels
     ScoreModelI sm2 = models.get(sm.getName());
     if (sm2 != null)
     {
-      System.err.println("Warning: replacing score model " + sm2.getName());
+      jalview.bin.Console.errPrintln("Warning: replacing score model " + sm2.getName());
     }
     models.put(sm.getName(), sm);
   }
index 54f7fb6..d5d07ef 100644 (file)
  */
 package jalview.api;
 
+import jalview.datamodel.SequenceGroup;
 import jalview.datamodel.SequenceI;
 import jalview.renderer.seqfeatures.FeatureColourFinder;
 
 import java.awt.Color;
+import java.awt.Graphics;
 
 public interface SequenceRenderer
 {
@@ -31,4 +33,19 @@ public interface SequenceRenderer
   Color getResidueColour(SequenceI seq, int position,
           FeatureColourFinder finder);
 
+  /**
+   * Configure the Graphics canvas and render options for the renderer
+   * @param g - the canvas to render to
+   * @param renderGaps - when true, gap characters will be included when rendered
+   *          
+   */
+  void prepare(Graphics g, boolean renderGaps);
+
+  void drawSequence(SequenceI nextSeq, SequenceGroup[] findAllGroups,
+          int startRes, int endRes, int i);
+
+  void drawHighlightedText(SequenceI nextSeq, int i, int j, int k, int l);
+
+  void drawCursor(Graphics g, char s, int i, int j);
+
 }
index a1b92df..77f2b6d 100644 (file)
  */
 package jalview.api.structures;
 
+import java.io.File;
+import java.util.Collections;
+import java.util.List;
+
 import jalview.api.AlignmentViewPanel;
 import jalview.datamodel.PDBEntry;
 import jalview.datamodel.SequenceI;
+import jalview.gui.AlignmentPanel;
+import jalview.gui.StructureViewer;
 import jalview.structures.models.AAStructureBindingModel;
 
 public interface JalviewStructureDisplayI
@@ -172,4 +178,28 @@ public interface JalviewStructureDisplayI
    */
   boolean hasViewerActionsMenu();
 
+  String getViewId();
+
+  StructureViewer.ViewerType getViewerType();
+
+  boolean isUsedforaligment(AlignmentViewPanel ap);
+
+  boolean isColouredByViewer();
+
+  int getHeight();
+
+  int getWidth();
+
+  int getY();
+
+  File saveSession();
+
+  /**
+   * 
+   * @return heteroatoms in a form suitable for display and passing to command generator to display hetatms
+   */
+  default List<String> getHetatms() {
+    return Collections.EMPTY_LIST;
+  }
+
 }
index b860a36..413b0d4 100644 (file)
@@ -393,14 +393,14 @@ public class APopupMenu extends java.awt.PopupMenu
         urlLink = new UrlLink(link);
       } catch (Exception foo)
       {
-        System.err.println("Exception for URLLink '" + link + "': "
+        jalview.bin.Console.errPrintln("Exception for URLLink '" + link + "': "
                 + foo.getMessage());
         continue;
       }
 
       if (!urlLink.isValid())
       {
-        System.err.println(urlLink.getInvalidMessage());
+        jalview.bin.Console.errPrintln(urlLink.getInvalidMessage());
         continue;
       }
 
index 0159bc7..4b858e1 100644 (file)
@@ -1577,7 +1577,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     /*
      * When we finally deprecate 1.1 compatibility, we can start to use
      * URLEncoder.encode(url,"UTF-8") and then we'll need this catch: catch
-     * (UnsupportedEncodingException ex) { System.err.println("WARNING -
+     * (UnsupportedEncodingException ex) { jalview.bin.Console.errPrintln("WARNING -
      * IMPLEMENTATION ERROR - UNSUPPORTED ENCODING EXCEPTION FOR "+url);
      * ex.printStackTrace(); }
      */
@@ -1586,7 +1586,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
       url = viewport.applet.getCodeBase() + url;
     } catch (UnsupportedEncodingException ex)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "WARNING = IMPLEMENTATION ERROR - UNSUPPORTED ENCODING EXCEPTION FOR "
                       + url);
       ex.printStackTrace();
@@ -2975,7 +2975,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     SequenceI[] oldOrder = viewport.getAlignment().getSequencesArray();
     if (viewport.applet.debug)
     {
-      System.err.println("Sorting " + alorder.getOrder().size()
+      jalview.bin.Console.errPrintln("Sorting " + alorder.getOrder().size()
               + " in alignment '" + getTitle() + "'");
     }
     AlignmentSorter.sortBy(viewport.getAlignment(), alorder);
@@ -3061,7 +3061,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
   {
     if (viewport.applet == null)
     {
-      System.out.println("Not running as applet - no browser available.");
+      jalview.bin.Console.outPrintln("Not running as applet - no browser available.");
     }
     else
     {
@@ -3977,12 +3977,12 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
       viewer = (Viewer) jmolviewer;
     } catch (ClassCastException ex)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Unsupported viewer object :" + jmolviewer.getClass());
     }
     if (viewer == null)
     {
-      System.err.println("Can't use this object as a structure viewer:"
+      jalview.bin.Console.errPrintln("Can't use this object as a structure viewer:"
               + jmolviewer.getClass());
       return null;
     }
@@ -4127,7 +4127,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     chains = (String[]) sqch[1];
     if (seqs == null || seqs.length == 0)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "JalviewLite.AlignFrame:newStructureView: No sequence to bind structure to.");
     }
     if (protocol == null)
@@ -4142,7 +4142,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
       }
       if (protocol == null)
       {
-        System.err.println("Couldn't work out protocol to open structure: "
+        jalview.bin.Console.errPrintln("Couldn't work out protocol to open structure: "
                 + pdb.getId());
         return;
       }
@@ -4154,7 +4154,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
               .setMapping(seqs, chains, pdb.getFile(), protocol,
                       null) == null)
       {
-        System.err.println("Failed to map " + pdb.getFile() + " ("
+        jalview.bin.Console.errPrintln("Failed to map " + pdb.getFile() + " ("
                 + protocol + ") to any sequences");
       }
       return;
@@ -4176,7 +4176,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
       }
       if (ajm != null)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Incremental adding and aligning structure to existing Jmol view not yet implemented.");
         // try and add the pdb structure
         // ajm.addS
@@ -4201,7 +4201,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
           SequenceI[][] seqs, String[][] chains, String[] protocols)
   {
     // TODO Auto-generated method stub
-    System.err.println("Aligned Structure View: Not yet implemented.");
+    jalview.bin.Console.errPrintln("Aligned Structure View: Not yet implemented.");
   }
 
   /**
@@ -4258,9 +4258,9 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     if (!file.isValid())
     {
       // TODO: raise dialog for gui
-      System.err.println("Problems parsing T-Coffee scores: "
+      jalview.bin.Console.errPrintln("Problems parsing T-Coffee scores: "
               + file.getWarningMessage());
-      System.err.println("Origin was:\n" + source);
+      jalview.bin.Console.errPrintln("Origin was:\n" + source);
       return false;
     }
 
@@ -4273,7 +4273,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
                     || aln.getWidth() != file.getWidth()))
     {
       // TODO: raise a dialog box here rather than bomb out.
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "The scores matrix does not match the alignment dimensions");
 
     }
@@ -4289,10 +4289,10 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     }
     else
     {
-      System.err.println("Problems resolving T-Coffee scores:");
+      jalview.bin.Console.errPrintln("Problems resolving T-Coffee scores:");
       if (file.getWarningMessage() != null)
       {
-        System.err.println(file.getWarningMessage());
+        jalview.bin.Console.errPrintln(file.getWarningMessage());
       }
     }
     return false;
index d64cd75..c1de259 100644 (file)
@@ -77,14 +77,14 @@ public class AlignViewport extends AlignmentViewport
         }
         if (widthScale <= 1.0)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Invalid alignment character width scaling factor ("
                           + widthScale + "). Ignoring.");
           widthScale = 1;
         }
         if (JalviewLite.debug)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Alignment character width scaling factor is now "
                           + widthScale);
         }
@@ -100,14 +100,14 @@ public class AlignViewport extends AlignmentViewport
         }
         if (heightScale <= 1.0)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Invalid alignment character height scaling factor ("
                           + heightScale + "). Ignoring.");
           heightScale = 1;
         }
         if (JalviewLite.debug)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Alignment character height scaling factor is now "
                           + heightScale);
         }
index fd75296..71ddcef 100644 (file)
@@ -363,7 +363,7 @@ public class AlignmentPanel extends Panel
       {
         if (JalviewLite.debug)
         {// DEBUG
-          System.out.println(
+          jalview.bin.Console.outPrintln(
                   "DEBUG: scroll didn't happen - results not within alignment : "
                           + seq.getStart() + "," + seq.getEnd());
         }
@@ -373,7 +373,7 @@ public class AlignmentPanel extends Panel
       {
         // DEBUG
         /*
-         * System.out.println("DEBUG: scroll: start=" + r[0] +
+         * jalview.bin.Console.outPrintln("DEBUG: scroll: start=" + r[0] +
          * " av.getStartRes()=" + av.getStartRes() + " end=" + r[1] +
          * " seq.end=" + seq.getEnd() + " av.getEndRes()=" + av.getEndRes() +
          * " hextent=" + hextent);
@@ -555,7 +555,7 @@ public class AlignmentPanel extends Panel
     // this is called after loading new annotation onto alignment
     if (alignFrame.getSize().height == 0)
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "adjustAnnotationHeight frame size zero NEEDS FIXING");
     }
     fontChanged();
@@ -693,7 +693,7 @@ public class AlignmentPanel extends Panel
 
       if ((hextent + x) > width)
       {
-        System.err.println("hextent was " + hextent + " and x was " + x);
+        jalview.bin.Console.errPrintln("hextent was " + hextent + " and x was " + x);
 
         x = width - hextent;
       }
@@ -710,7 +710,7 @@ public class AlignmentPanel extends Panel
 
       if (x < 0)
       {
-        System.err.println("x was " + x);
+        jalview.bin.Console.errPrintln("x was " + x);
         x = 0;
       }
 
@@ -1111,7 +1111,7 @@ public class AlignmentPanel extends Panel
   public void raiseOOMWarning(String string, OutOfMemoryError error)
   {
     // TODO: JAL-960
-    System.err.println("Out of memory whilst '" + string + "'");
+    jalview.bin.Console.errPrintln("Out of memory whilst '" + string + "'");
     error.printStackTrace();
   }
 
index b0722c0..cca9aff 100644 (file)
@@ -275,7 +275,7 @@ public class AppletJmol extends EmbmenuFrame implements
               "-applet", scriptWindow, null);
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Couldn't create a jmol viewer. Args to allocate viewer were:\nDocumentBase="
                       + ap.av.applet.getDocumentBase() + "\nCodebase="
                       + ap.av.applet.getCodeBase());
@@ -320,7 +320,7 @@ public class AppletJmol extends EmbmenuFrame implements
           {
             if (jalview.bin.JalviewLite.debug)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "AppletJmol:Trying to reuse existing PDBfile IO parser.");
             }
             // re-use the one we opened earlier
@@ -330,7 +330,7 @@ public class AppletJmol extends EmbmenuFrame implements
           {
             if (jalview.bin.JalviewLite.debug)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "AppletJmol:Creating new PDBfile IO parser.");
             }
             FileParse fp = new FileParse(pdbentry.getFile(), protocol);
@@ -355,7 +355,7 @@ public class AppletJmol extends EmbmenuFrame implements
         } catch (Exception e)
         {
           // give up!
-          System.err.println("Couldn't access pdbentry id="
+          jalview.bin.Console.errPrintln("Couldn't access pdbentry id="
                   + pdbentry.getId() + " and file=" + pdbentry.getFile()
                   + " using protocol=" + protocol);
           e.printStackTrace();
@@ -433,7 +433,7 @@ public class AppletJmol extends EmbmenuFrame implements
       } catch (OutOfMemoryError ex)
       {
         frame.dispose();
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Out of memory when trying to create dialog box with sequence-structure mapping.");
         return;
       }
index 47f9df0..e2b8f23 100644 (file)
@@ -154,7 +154,7 @@ public class ExtJmol extends JalviewJmolBinding
   {
     // This never gets called because we haven't overriden the associated Jmol's
     // console
-    System.err.println(
+    jalview.bin.Console.errPrintln(
             "WARNING: unexpected call to ExtJmol's showConsole method. (showConsole="
                     + show);
   }
index 7c0dfa9..7730210 100644 (file)
@@ -145,7 +145,7 @@ public class PCAPanel extends EmbmenuFrame
       top = pcaModel.getTop();
     } catch (OutOfMemoryError x)
     {
-      System.err.println("Out of memory when calculating PCA.");
+      jalview.bin.Console.errPrintln("Out of memory when calculating PCA.");
       return;
     }
     calcSettings.setEnabled(true);
index bc775c6..566aad9 100644 (file)
@@ -102,7 +102,7 @@ public class PairwiseAlignPanel extends Panel implements ActionListener
 
     if (count > 2)
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "Pairwise alignment scaled similarity score matrix\n");
 
       for (int i = 0; i < count; i++)
@@ -111,7 +111,7 @@ public class PairwiseAlignPanel extends Panel implements ActionListener
                 ("" + i) + " " + seqs[i].getName());
       }
 
-      System.out.println("\n");
+      jalview.bin.Console.outPrintln("\n");
 
       for (int i = 0; i < count; i++)
       {
@@ -122,7 +122,7 @@ public class PairwiseAlignPanel extends Panel implements ActionListener
         }
       }
 
-      System.out.println("\n");
+      jalview.bin.Console.outPrintln("\n");
     }
   }
 
index bd36b0d..a5b652f 100644 (file)
@@ -148,7 +148,7 @@ public class RedundancyPanel extends SliderPanel
 
     validate();
     sliderValueChanged();
-    // System.out.println("blob done "+ (System.currentTimeMillis()-start));
+    // jalview.bin.Console.outPrintln("blob done "+ (System.currentTimeMillis()-start));
   }
 
   void sliderValueChanged()
index a870ca4..87266b4 100755 (executable)
@@ -145,7 +145,7 @@ public class RotatableCanvas extends Panel implements MouseListener,
 
     scale = findScale();
 
-    // System.out.println("Scale factor = " + scale);
+    // jalview.bin.Console.outPrintln("Scale factor = " + scale);
 
     addMouseListener(this);
     addKeyListener(this);
@@ -301,7 +301,7 @@ public class RotatableCanvas extends Panel implements MouseListener,
 
         scale = findScale();
 
-        // System.out.println("New scale = " + scale);
+        // jalview.bin.Console.outPrintln("New scale = " + scale);
         img = createImage(getSize().width, getSize().height);
         ig = img.getGraphics();
 
@@ -427,7 +427,7 @@ public class RotatableCanvas extends Panel implements MouseListener,
     }
     else if (evt.getKeyChar() == 's')
     {
-      System.err.println("DEBUG: Rectangle selection"); // log.debug
+      jalview.bin.Console.errPrintln("DEBUG: Rectangle selection"); // log.debug
       if (rectx2 != -1 && recty2 != -1)
       {
         rectSelect(rectx1, recty1, rectx2, recty2);
index 3b79f12..735046e 100755 (executable)
@@ -644,7 +644,9 @@ public class SeqCanvas extends Panel implements ViewportListenerI
       if (av.cursorMode && cursorY == i && cursorX >= startRes
               && cursorX <= endRes)
       {
-        sr.drawCursor(nextSeq, cursorX, (cursorX - startRes) * avcharWidth,
+        char s = nextSeq.getCharAt(cursorX);
+
+        sr.drawCursor(g,s, (cursorX - startRes) * avcharWidth,
                 offset + ((i - startSeq) * avcharHeight));
       }
     }
index 70366e4..c573612 100644 (file)
@@ -772,7 +772,7 @@ public class SeqPanel extends Panel implements MouseMotionListener,
   @Override
   public void updateColours(SequenceI seq, int index)
   {
-    System.out.println("update the seqPanel colours");
+    jalview.bin.Console.outPrintln("update the seqPanel colours");
     // repaint();
   }
 
@@ -1817,7 +1817,7 @@ public class SeqPanel extends Panel implements MouseMotionListener,
       {
         if (av.getAlignment() == null)
         {
-          System.out.println("Selection message: alignviewport av SeqSetId="
+          jalview.bin.Console.outPrintln("Selection message: alignviewport av SeqSetId="
                   + av.getSequenceSetId() + " ViewId=" + av.getViewId()
                   + " 's alignment is NULL! returning immediatly.");
           return;
@@ -1869,7 +1869,7 @@ public class SeqPanel extends Panel implements MouseMotionListener,
     if (copycolsel && av.hasHiddenColumns()
             && (av.getColumnSelection() == null))
     {
-      System.err.println("Bad things");
+      jalview.bin.Console.errPrintln("Bad things");
     }
     if (repaint)
     {
index eab6e39..34ad217 100755 (executable)
@@ -353,7 +353,7 @@ public class SequenceRenderer implements jalview.api.SequenceRenderer
     }
   }
 
-  public void drawCursor(SequenceI seq, int res, int x1, int y1)
+  public void drawCursor(Graphics graphics, char s, int x1, int y1)
   {
     int pady = av.getCharHeight() / 5;
     int charOffset = 0;
@@ -363,7 +363,6 @@ public class SequenceRenderer implements jalview.api.SequenceRenderer
 
     graphics.setColor(Color.white);
 
-    char s = seq.getCharAt(res);
     if (av.validCharWidth)
     {
 
index 671fee1..0316e0b 100644 (file)
@@ -166,7 +166,7 @@ public class TreePanel extends EmbmenuFrame
     }
     else
     {
-      System.out.println("Original Tree Data not available");
+      jalview.bin.Console.outPrintln("Original Tree Data not available");
     }
   }
 
index 5741908..483b1fc 100755 (executable)
@@ -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;
@@ -141,6 +143,10 @@ import jalview.ws.sifts.SiftsSettings;
  * <li>WRAP_ALIGNMENT</li>
  * <li>EPS_RENDERING (Prompt each time|Lineart|Text) default for EPS rendering
  * style check</li>
+ * <li>BITMAP_SCALE - scale factor for PNG export - default 0.0 - native
+ * resolution</li>
+ * <li>BITMAP_HEIGHT - height bound for PNG export or 0 for unbound</li>
+ * <li>BITMAP_WIDTH - width bound for PNG export or 0 for unbound</li>
  * <li>SORT_ALIGNMENT (No sort|Id|Pairwise Identity)</li>
  * <li>SEQUENCE_LINKS list of name|URL pairs for opening a url with
  * $SEQUENCE_ID$</li>
@@ -407,9 +413,9 @@ public class Cache
           fis = new URL(propertiesFile).openStream();
           if (!Jalview.quiet())
           {
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     "Loading jalview properties from : " + propertiesFile);
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     "Disabling Jalview writing to user's local properties file.");
           }
           propsAreReadOnly = true;
@@ -440,7 +446,8 @@ public class Cache
       } catch (Exception ex)
       {
         if (!Jalview.quiet())
-          System.out.println("Error reading properties file: " + ex);
+          jalview.bin.Console
+                  .outPrintln("Error reading properties file: " + ex);
       }
     }
 
@@ -497,7 +504,8 @@ public class Cache
     } catch (Exception ex)
     {
       if (!Jalview.quiet())
-        System.out.println("Error reading author details: " + ex);
+        jalview.bin.Console
+                .outPrintln("Error reading author details: " + ex);
       authorDetails = null;
     }
     if (authorDetails == null)
@@ -583,10 +591,10 @@ public class Cache
             {
               if (!Jalview.quiet())
               {
-                System.out.println(
+                jalview.bin.Console.errPrintln(
                         "Non-fatal exception when checking version at "
                                 + remoteBuildPropertiesUrl + ":");
-                System.out.println(ex);
+                jalview.bin.Console.printStackTrace(ex);
               }
               remoteVersion = getProperty("VERSION");
             }
@@ -636,8 +644,8 @@ public class Cache
         url = Cache.class.getResource(resourcePath).toString();
       } catch (Exception ex)
       {
-        System.err.println("Failed to resolve resource " + resourcePath
-                + ": " + ex.getMessage());
+        jalview.bin.Console.errPrintln("Failed to resolve resource "
+                + resourcePath + ": " + ex.getMessage());
       }
     }
     else
@@ -687,7 +695,8 @@ public class Cache
     } catch (Exception ex)
     {
       if (!Jalview.quiet())
-        System.out.println("Error reading build details: " + ex);
+        jalview.bin.Console
+                .outPrintln("Error reading build details: " + ex);
       applicationProperties.remove("VERSION");
     }
     String codeVersion = getProperty("VERSION");
@@ -707,8 +716,9 @@ public class Cache
     new BuildDetails(codeVersion, null, codeInstallation);
     if (printVersion && reportVersion)
     {
-      System.out.println(ChannelProperties.getProperty("app_name")
-              + " version: " + codeVersion + codeInstallation);
+      jalview.bin.Console
+              .outPrintln(ChannelProperties.getProperty("app_name")
+                      + " version: " + codeVersion + codeInstallation);
     }
   }
 
@@ -784,8 +794,27 @@ public class Cache
       } catch (NumberFormatException e)
       {
         if (!Jalview.quiet())
-          System.out.println("Error parsing int property '" + property
-                  + "' with value '" + string + "'");
+          jalview.bin.Console.errPrintln("Error parsing int property '"
+                  + property + "' with value '" + string + "'");
+      }
+    }
+
+    return def;
+  }
+
+  public static float getDefault(String property, float def)
+  {
+    String string = getProperty(property);
+    if (string != null)
+    {
+      try
+      {
+        def = Float.parseFloat(string);
+      } catch (NumberFormatException e)
+      {
+        if (!Jalview.quiet())
+          jalview.bin.Console.errPrintln("Error parsing float property '"
+                  + property + "' with value '" + string + "'");
       }
     }
 
@@ -835,7 +864,7 @@ public class Cache
     } catch (Exception ex)
     {
       if (!Jalview.quiet())
-        System.out.println(
+        jalview.bin.Console.errPrintln(
                 "Error setting property: " + key + " " + obj + "\n" + ex);
     }
     return oldValue;
@@ -867,7 +896,7 @@ public class Cache
       } catch (Exception ex)
       {
         if (!Jalview.quiet())
-          System.out.println("Error saving properties: " + ex);
+          jalview.bin.Console.errPrintln("Error saving properties: " + ex);
       }
     }
   }
@@ -1057,8 +1086,9 @@ public class Cache
         return date_format.parse(val);
       } catch (Exception ex)
       {
-        System.err.println("Invalid or corrupt date in property '"
-                + propertyName + "' : value was '" + val + "'");
+        jalview.bin.Console
+                .errPrintln("Invalid or corrupt date in property '"
+                        + propertyName + "' : value was '" + val + "'");
       }
     }
     return null;
@@ -1081,8 +1111,8 @@ public class Cache
         return Integer.valueOf(val);
       } catch (NumberFormatException x)
       {
-        System.err.println("Invalid integer in property '" + property
-                + "' (value was '" + val + "')");
+        jalview.bin.Console.errPrintln("Invalid integer in property '"
+                + property + "' (value was '" + val + "')");
       }
     }
     return null;
@@ -1146,7 +1176,8 @@ public class Cache
       } catch (Exception ex)
       {
         if (!Jalview.quiet())
-          System.out.println("Error loading User ColourFile\n" + ex);
+          jalview.bin.Console
+                  .outPrintln("Error loading User ColourFile\n" + ex);
       }
     }
     if (!files.equals(coloursFound.toString()))
@@ -1634,26 +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())
     {
-      System.err.println("Could not load bootstrap preferences file '"
-              + filename + "'");
+      jalview.bin.Console
+              .errPrintln("Could not load bootstrap preferences file '"
+                      + file.getPath() + "'");
       return null;
     }
 
@@ -1669,11 +1710,12 @@ public class Cache
       }
     } catch (FileNotFoundException e)
     {
-      System.err.println("Could not find bootstrap preferences file '"
-              + file.getAbsolutePath() + "'");
+      jalview.bin.Console
+              .errPrintln("Could not find bootstrap preferences file '"
+                      + file.getAbsolutePath() + "'");
     } catch (IOException e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "IOException when loading bootstrap preferences file '"
                       + file.getAbsolutePath() + "'");
     }
@@ -1692,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);
+  }
 }
index dbc4953..a092cd6 100644 (file)
@@ -1,23 +1,25 @@
 package jalview.bin;
 
+import java.awt.Color;
 import java.io.File;
 import java.io.IOException;
 import java.net.URISyntaxException;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collections;
-import java.util.EnumSet;
 import java.util.HashMap;
 import java.util.Iterator;
 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;
 import jalview.bin.argparser.Arg;
 import jalview.bin.argparser.ArgParser;
-import jalview.bin.argparser.ArgParser.Position;
 import jalview.bin.argparser.ArgValue;
 import jalview.bin.argparser.ArgValuesMap;
 import jalview.bin.argparser.SubVals;
@@ -47,14 +49,17 @@ import jalview.io.NewickFile;
 import jalview.io.exceptions.ImageOutputException;
 import jalview.schemes.ColourSchemeI;
 import jalview.schemes.ColourSchemeProperty;
+import jalview.structure.StructureCommandI;
 import jalview.structure.StructureImportSettings.TFType;
 import jalview.structure.StructureSelectionManager;
+import jalview.util.ColorUtils;
 import jalview.util.FileUtils;
 import jalview.util.HttpUtils;
 import jalview.util.ImageMaker;
 import jalview.util.ImageMaker.TYPE;
 import jalview.util.MessageManager;
 import jalview.util.Platform;
+import jalview.util.StringUtils;
 import jalview.util.imagemaker.BitmapImageSizing;
 
 public class Commands
@@ -67,10 +72,14 @@ public class Commands
 
   private Map<String, AlignFrame> afMap;
 
+  private Map<String, List<StructureViewer>> svMap;
+
   private boolean commandArgsProvided = false;
 
   private boolean argsWereParsed = false;
 
+  private List<String> errors = new ArrayList<>();
+
   public Commands(ArgParser argparser, boolean headless)
   {
     this(Desktop.instance, argparser, headless);
@@ -82,16 +91,15 @@ public class Commands
     headless = h;
     desktop = d;
     afMap = new HashMap<>();
-    if (argparser != null)
-    {
-      processArgs(argparser, headless);
-    }
   }
 
-  private boolean processArgs(ArgParser argparser, boolean h)
+  protected boolean processArgs()
   {
-    argParser = argparser;
-    headless = h;
+    if (argParser == null)
+    {
+      return true;
+    }
+
     boolean theseArgsWereParsed = false;
 
     if (argParser != null && argParser.getLinkedIds() != null)
@@ -100,9 +108,10 @@ public class Commands
       {
         ArgValuesMap avm = argParser.getLinkedArgs(id);
         theseArgsWereParsed = true;
-        theseArgsWereParsed &= processLinked(id);
+        boolean processLinkedOkay = processLinked(id);
+        theseArgsWereParsed &= processLinkedOkay;
+
         processGroovyScript(id);
-        boolean processLinkedOkay = theseArgsWereParsed;
 
         // wait around until alignFrame isn't busy
         AlignFrame af = afMap.get(id);
@@ -118,8 +127,11 @@ public class Commands
         }
 
         theseArgsWereParsed &= processImages(id);
+
         if (processLinkedOkay)
+        {
           theseArgsWereParsed &= processOutput(id);
+        }
 
         // close ap
         if (avm.getBoolean(Arg.CLOSE))
@@ -134,9 +146,22 @@ public class Commands
       }
 
     }
+
+    // report errors - if any
+    String errorsRaised = errorsToString();
+    if (errorsRaised.trim().length() > 0)
+    {
+      Console.warn(
+              "The following errors and warnings occurred whilst processing files:\n"
+                      + errorsRaised);
+    }
+    // gui errors reported in Jalview
+
     if (argParser.getBoolean(Arg.QUIT))
     {
-      Jalview.getInstance().quit();
+      Jalview.getInstance().exit(
+              "Exiting due to " + Arg.QUIT.argString() + " argument.",
+              ExitCode.OK);
       return true;
     }
     // carry on with jalview.bin.Jalview
@@ -154,25 +179,20 @@ public class Commands
     return argsWereParsed;
   }
 
-  protected boolean processUnlinked(String id)
-  {
-    return processLinked(id);
-  }
-
   protected boolean processLinked(String id)
   {
     boolean theseArgsWereParsed = false;
     ArgValuesMap avm = argParser.getLinkedArgs(id);
     if (avm == null)
+    {
       return true;
+    }
+
+    Boolean isError = Boolean.valueOf(false);
+
+    // set wrap scope here so it can be applied after structures are opened
+    boolean wrap = false;
 
-    /*
-     * // script to execute after all loading is completed one way or another String
-     * groovyscript = m.get(Arg.GROOVY) == null ? null :
-     * m.get(Arg.GROOVY).getValue(); String file = m.get(Arg.OPEN) == null ? null :
-     * m.get(Arg.OPEN).getValue(); String data = null; FileFormatI format = null;
-     * DataSourceType protocol = null;
-     */
     if (avm.containsArg(Arg.APPEND) || avm.containsArg(Arg.OPEN))
     {
       commandArgsProvided = true;
@@ -221,7 +241,9 @@ public class Commands
           {
             if (!(new File(openFile)).exists())
             {
-              Console.warn("Can't find file '" + openFile + "'");
+              addError("Can't find file '" + openFile + "'");
+              isError = true;
+              continue;
             }
           }
         }
@@ -235,7 +257,9 @@ public class Commands
           format = new IdentifyFile().identify(openFile, protocol);
         } catch (FileFormatException e1)
         {
-          Console.error("Unknown file format for '" + openFile + "'");
+          addError("Unknown file format for '" + openFile + "'");
+          isError = true;
+          continue;
         }
 
         af = afMap.get(id);
@@ -252,39 +276,37 @@ public class Commands
           Console.debug(
                   "Opening '" + openFile + "' in new alignment frame");
           FileLoader fileLoader = new FileLoader(!headless);
-
-          af = fileLoader.LoadFileWaitTillLoaded(openFile, protocol,
-                  format);
-
-          // wrap alignment?
-          boolean wrap = ArgParser.getFromSubValArgOrPref(avm, Arg.WRAP, sv,
-                  null, "WRAP_ALIGNMENT", false);
-          af.getCurrentView().setWrapAlignment(wrap);
-
-          // colour alignment?
-          String colour = ArgParser.getFromSubValArgOrPref(avm, av,
-                  Arg.COLOUR, sv, null, "DEFAULT_COLOUR_PROT", "");
-          if ("" != colour)
+          boolean xception = false;
+          try
           {
-            ColourSchemeI cs = ColourSchemeProperty.getColourScheme(
-                    af.getViewport(), af.getViewport().getAlignment(),
-                    colour);
-
-            if (cs == null && !"None".equals(colour))
-            {
-              Console.warn(
-                      "Couldn't parse '" + colour + "' as a colourscheme.");
-            }
-            else
+            af = fileLoader.LoadFileWaitTillLoaded(openFile, protocol,
+                    format);
+          } catch (Throwable thr)
+          {
+            xception = true;
+            addError("Couldn't open '" + openFile + "' as " + format + " "
+                    + thr.getLocalizedMessage()
+                    + " (Enable debug for full stack trace)");
+            isError = true;
+            Console.debug("Exception when opening '" + openFile + "'", thr);
+          } finally
+          {
+            if (af == null && !xception)
             {
-              af.changeColour(cs);
+              addInfo("Ignoring '" + openFile
+                      + "' - no alignment data found.");
+              continue;
             }
-            Jalview.testoutput(argParser, Arg.COLOUR, "zappo", colour);
           }
 
+          // colour alignment
+          String colour = avm.getFromSubValArgOrPref(av, Arg.COLOUR, sv,
+                  null, "DEFAULT_COLOUR_PROT", "");
+          this.colourAlignFrame(af, colour);
+
           // Change alignment frame title
-          String title = ArgParser.getFromSubValArgOrPref(avm, av,
-                  Arg.TITLE, sv, null, null, null);
+          String title = avm.getFromSubValArgOrPref(av, Arg.TITLE, sv, null,
+                  null, null);
           if (title != null)
           {
             af.setTitle(title);
@@ -292,7 +314,7 @@ public class Commands
           }
 
           // Add features
-          String featuresfile = ArgParser.getValueFromSubValOrArg(avm, av,
+          String featuresfile = avm.getValueFromSubValOrArg(av,
                   Arg.FEATURES, sv);
           if (featuresfile != null)
           {
@@ -303,8 +325,8 @@ public class Commands
           }
 
           // Add annotations from file
-          String annotationsfile = ArgParser.getValueFromSubValOrArg(avm,
-                  av, Arg.ANNOTATIONS, sv);
+          String annotationsfile = avm.getValueFromSubValOrArg(av,
+                  Arg.ANNOTATIONS, sv);
           if (annotationsfile != null)
           {
             af.loadJalviewDataFile(annotationsfile, null, null, null);
@@ -314,8 +336,8 @@ public class Commands
           }
 
           // Set or clear the sortbytree flag
-          boolean sortbytree = ArgParser.getBoolFromSubValOrArg(avm,
-                  Arg.SORTBYTREE, sv);
+          boolean sortbytree = avm.getBoolFromSubValOrArg(Arg.SORTBYTREE,
+                  sv);
           if (sortbytree)
           {
             af.getViewport().setSortByTree(true);
@@ -323,8 +345,7 @@ public class Commands
           }
 
           // Load tree from file
-          String treefile = ArgParser.getValueFromSubValOrArg(avm, av,
-                  Arg.TREE, sv);
+          String treefile = avm.getValueFromSubValOrArg(av, Arg.TREE, sv);
           if (treefile != null)
           {
             try
@@ -337,34 +358,64 @@ public class Commands
                       "examples/testdata/uniref50_test_tree", treefile);
             } catch (IOException e)
             {
-              Console.warn("Couldn't add tree " + treefile, e);
+              addError("Couldn't add tree " + treefile, e);
+              isError = true;
             }
           }
 
+          
           // Show secondary structure annotations?
-          boolean showSSAnnotations = ArgParser.getFromSubValArgOrPref(avm,
+          boolean showSSAnnotations = avm.getFromSubValArgOrPref(
                   Arg.SHOWSSANNOTATIONS, av.getSubVals(), null,
                   "STRUCT_FROM_PDB", true);
-          af.setAnnotationsVisibility(showSSAnnotations, true, false);
-
+          
           // Show sequence annotations?
-          boolean showAnnotations = ArgParser.getFromSubValArgOrPref(avm,
+          boolean showAnnotations = avm.getFromSubValArgOrPref(
                   Arg.SHOWANNOTATIONS, av.getSubVals(), null,
                   "SHOW_ANNOTATIONS", true);
-          af.setAnnotationsVisibility(showAnnotations, false, true);
+          
+          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
+          {
+            SwingUtilities.invokeAndWait(new Runnable()
+            {
+              @Override
+              public void run()
+              {
+                _af.setAnnotationsVisibility(showSSAnnotations, true,
+                        false);
+
+                _af.setAnnotationsVisibility(showAnnotations, false, true);
 
-          // show temperature factor annotations?
-          if (avm.getBoolean(Arg.NOTEMPFAC))
+                // show temperature factor annotations?
+                if (hideTFrows)
+                {
+                  // do this better (annotation types?)
+                  List<String> hideThese = new ArrayList<>();
+                  hideThese.add("Temperature Factor");
+                  hideThese.add(AlphaFoldAnnotationRowBuilder.LABEL);
+                  AlignmentUtils.showOrHideSequenceAnnotations(
+                          _af.getCurrentView().getAlignment(), hideThese,
+                          null, false, false);
+                }
+              }
+            });
+          } catch (Exception x)
           {
-            // do this better (annotation types?)
-            List<String> hideThese = new ArrayList<>();
-            hideThese.add("Temperature Factor");
-            hideThese.add(AlphaFoldAnnotationRowBuilder.LABEL);
-            AlignmentUtils.showOrHideSequenceAnnotations(
-                    af.getCurrentView().getAlignment(), hideThese, null,
-                    false, false);
+            Console.warn(
+                    "Unexpected exception adjusting annotation row visibility.",
+                    x);
           }
 
+          // wrap alignment? do this last for formatting reasons
+          wrap = avm.getFromSubValArgOrPref(Arg.WRAP, sv, null,
+                  "WRAP_ALIGNMENT", false);
+          // af.setWrapFormat(wrap) is applied after structures are opened for
+          // annotation reasons
+
           // store the AlignFrame for this id
           afMap.put(id, af);
 
@@ -397,11 +448,12 @@ public class Commands
       {
         if (headless)
         {
-          Jalview.exit("Could not open any files in headless mode", 1);
+          Jalview.exit("Could not open any files in headless mode",
+                  ExitCode.NO_FILES);
         }
         else
         {
-          Console.warn("No more files to open");
+          Console.info("No more files to open");
         }
       }
       if (progressBarSet && desktop != null)
@@ -418,8 +470,10 @@ public class Commands
         commandArgsProvided = true;
         for (ArgValue av : avm.getArgValueList(Arg.STRUCTURE))
         {
+          argParser.setStructureFilename(null);
           String val = av.getValue();
           SubVals subVals = av.getSubVals();
+          int argIndex = av.getArgIndex();
           SequenceI seq = getSpecifiedSequence(af, avm, av);
           if (seq == null)
           {
@@ -431,56 +485,52 @@ public class Commands
 
           if (seq == null)
           {
-            Console.warn("Could not find sequence for argument "
+            addWarn("Could not find sequence for argument "
                     + Arg.STRUCTURE.argString() + "=" + val);
-            // you probably want to continue here, not break
-            // break;
             continue;
           }
+          String structureFilename = null;
           File structureFile = null;
           if (subVals.getContent() != null
                   && subVals.getContent().length() != 0)
           {
-            structureFile = new File(subVals.getContent());
+            structureFilename = subVals.getContent();
             Console.debug("Using structure file (from argument) '"
-                    + structureFile.getAbsolutePath() + "'");
-          }
-          // TRY THIS
-          /*
-           * PDBEntry fileEntry = new AssociatePdbFileWithSeq()
-           * .associatePdbWithSeq(selectedPdbFileName, DataSourceType.FILE,
-           * selectedSequence, true, Desktop.instance);
-           * 
-           * sViewer = launchStructureViewer(ssm, new PDBEntry[] { fileEntry }, ap, new
-           * SequenceI[] { selectedSequence });
-           * 
-           */
+                    + structureFilename + "'");
+            structureFile = new File(structureFilename);
+          }
           /* THIS DOESN'T WORK */
           else if (seq.getAllPDBEntries() != null
                   && seq.getAllPDBEntries().size() > 0)
           {
             structureFile = new File(
                     seq.getAllPDBEntries().elementAt(0).getFile());
-            Console.debug("Using structure file (from sequence) '"
-                    + structureFile.getAbsolutePath() + "'");
+            if (structureFile != null)
+            {
+              Console.debug("Using structure file (from sequence) '"
+                      + structureFile.getAbsolutePath() + "'");
+            }
+            structureFilename = structureFile.getAbsolutePath();
           }
 
-          if (structureFile == null)
+          if (structureFilename == null || structureFile == null)
           {
-            Console.warn("Not provided structure file with '" + val + "'");
+            addWarn("Not provided structure file with '" + val + "'");
             continue;
           }
 
           if (!structureFile.exists())
           {
-            Console.warn("Structure file '"
-                    + structureFile.getAbsoluteFile() + "' not found.");
+            addWarn("Structure file '" + structureFile.getAbsoluteFile()
+                    + "' not found.");
             continue;
           }
 
           Console.debug("Using structure file "
                   + structureFile.getAbsolutePath());
 
+          argParser.setStructureFilename(structureFilename);
+
           // open structure view
           AlignmentPanel ap = af.alignPanel;
           if (headless)
@@ -492,10 +542,9 @@ public class Commands
           String structureFilepath = structureFile.getAbsolutePath();
 
           // get PAEMATRIX file and label from subvals or Arg.PAEMATRIX
-          String paeFilepath = ArgParser
-                  .getFromSubValArgOrPrefWithSubstitutions(argParser, avm,
-                          Arg.PAEMATRIX, Position.AFTER, av, subVals, null,
-                          null, null);
+          String paeFilepath = avm.getFromSubValArgOrPrefWithSubstitutions(
+                  argParser, Arg.PAEMATRIX, ArgValuesMap.Position.AFTER, av,
+                  subVals, null, null, null);
           if (paeFilepath != null)
           {
             File paeFile = new File(paeFilepath);
@@ -506,25 +555,23 @@ public class Commands
             } catch (IOException e)
             {
               paeFilepath = paeFile.getAbsolutePath();
-              Console.warn("Problem with the PAE file path: '"
+              addWarn("Problem with the PAE file path: '"
                       + paeFile.getPath() + "'");
             }
           }
 
           // showing annotations from structure file or not
-          boolean ssFromStructure = ArgParser.getFromSubValArgOrPref(avm,
+          boolean ssFromStructure = avm.getFromSubValArgOrPref(
                   Arg.SHOWSSANNOTATIONS, subVals, null, "STRUCT_FROM_PDB",
                   true);
 
           // get TEMPFAC type from subvals or Arg.TEMPFAC in case user Adds
           // reference annotations
-          String tftString = ArgParser
-                  .getFromSubValArgOrPrefWithSubstitutions(argParser, avm,
-                          Arg.TEMPFAC, Position.AFTER, av, subVals, null,
-                          null, null);
-          boolean notempfac = ArgParser.getFromSubValArgOrPref(avm,
-                  Arg.NOTEMPFAC, subVals, null, "ADD_TEMPFACT_ANN", false,
-                  true);
+          String tftString = avm.getFromSubValArgOrPrefWithSubstitutions(
+                  argParser, Arg.TEMPFAC, ArgValuesMap.Position.AFTER, av,
+                  subVals, null, null, null);
+          boolean notempfac = avm.getFromSubValArgOrPref(Arg.NOTEMPFAC,
+                  subVals, null, "ADD_TEMPFACT_ANN", false, true);
           TFType tft = notempfac ? null : TFType.DEFAULT;
           if (tftString != null && !notempfac)
           {
@@ -549,146 +596,252 @@ public class Commands
                 if (it.hasNext())
                   sb.append(", ");
               }
-              Console.warn(sb.toString());
+              addWarn(sb.toString());
             }
           }
 
-          String sViewer = ArgParser.getFromSubValArgOrPref(avm,
-                  Arg.STRUCTUREVIEWER, Position.AFTER, av, subVals, null,
-                  null, "jmol");
-          ViewerType viewerType = null;
-          if (!"none".equals(sViewer))
-          {
-            for (ViewerType v : EnumSet.allOf(ViewerType.class))
-            {
-              String name = v.name().toLowerCase(Locale.ROOT)
-                      .replaceAll(" ", "");
-              if (sViewer.equals(name))
-              {
-                viewerType = v;
-                break;
-              }
-            }
-          }
+          String sViewerName = avm.getFromSubValArgOrPref(
+                  Arg.STRUCTUREVIEWER, ArgValuesMap.Position.AFTER, av,
+                  subVals, null, null, "jmol");
+          ViewerType viewerType = ViewerType.getFromString(sViewerName);
 
           // TODO use ssFromStructure
-          StructureViewer sv = StructureChooser
+          StructureViewer structureViewer = StructureChooser
                   .openStructureFileForSequence(null, null, ap, seq, false,
                           structureFilepath, tft, paeFilepath, false,
                           ssFromStructure, false, viewerType);
 
-          if (sv == null)
+          if (structureViewer == null)
           {
-            Console.error("Failed to import and open structure view.");
+            if (!StringUtils.equalsIgnoreCase(sViewerName, "none"))
+            {
+              addError("Failed to import and open structure view for file '"
+                      + structureFile + "'.");
+            }
             continue;
           }
           try
           {
             long tries = 1000;
-            while (sv.isBusy() && tries > 0)
+            while (structureViewer.isBusy() && tries > 0)
             {
               Thread.sleep(25);
-              if (sv.isBusy())
+              if (structureViewer.isBusy())
               {
                 tries--;
                 Console.debug(
                         "Waiting for viewer for " + structureFilepath);
               }
             }
-            if (tries == 0 && sv.isBusy())
+            if (tries == 0 && structureViewer.isBusy())
             {
-              Console.warn(
-                      "Gave up waiting for structure viewer to load. Something may have gone wrong.");
+              addWarn("Gave up waiting for structure viewer to load file '"
+                      + structureFile
+                      + "'. Something may have gone wrong.");
             }
           } catch (Exception x)
           {
-            Console.warn("Exception whilst waiting for structure viewer "
+            addError("Exception whilst waiting for structure viewer "
                     + structureFilepath, x);
+            isError = true;
           }
+
+          // add StructureViewer to svMap list
+          if (svMap == null)
+          {
+            svMap = new HashMap<>();
+          }
+          if (svMap.get(id) == null)
+          {
+            svMap.put(id, new ArrayList<>());
+          }
+          svMap.get(id).add(structureViewer);
+
           Console.debug(
                   "Successfully opened viewer for " + structureFilepath);
-          String structureImageFilename = ArgParser.getValueFromSubValOrArg(
-                  avm, av, Arg.STRUCTUREIMAGE, subVals);
-          if (sv != null && structureImageFilename != null)
-          {
-            ArgValue siAv = avm.getClosestNextArgValueOfArg(av,
-                    Arg.STRUCTUREIMAGE);
-            SubVals sisv = null;
-            if (structureImageFilename.equals(siAv.getValue()))
-            {
-              sisv = siAv.getSubVals();
-            }
-            File structureImageFile = new File(structureImageFilename);
-            String width = ArgParser.getValueFromSubValOrArg(avm, av,
-                    Arg.STRUCTUREIMAGEWIDTH, sisv);
-            String height = ArgParser.getValueFromSubValOrArg(avm, av,
-                    Arg.STRUCTUREIMAGEHEIGHT, sisv);
-            String scale = ArgParser.getValueFromSubValOrArg(avm, av,
-                    Arg.STRUCTUREIMAGESCALE, sisv);
-            String renderer = ArgParser.getValueFromSubValOrArg(avm, av,
-                    Arg.STRUCTUREIMAGETEXTRENDERER, sisv);
-            String typeS = ArgParser.getValueFromSubValOrArg(avm, av,
-                    Arg.STRUCTUREIMAGETYPE, sisv);
-            if (typeS == null || typeS.length() == 0)
-            {
-              typeS = FileUtils.getExtension(structureImageFile);
-            }
-            TYPE imageType;
-            try
-            {
-              imageType = Enum.valueOf(TYPE.class,
-                      typeS.toUpperCase(Locale.ROOT));
-            } catch (IllegalArgumentException e)
-            {
-              Console.warn("Do not know image format '" + typeS
-                      + "', using PNG");
-              imageType = TYPE.PNG;
-            }
-            BitmapImageSizing userBis = ImageMaker
-                    .parseScaleWidthHeightStrings(scale, width, height);
-            // TODO MAKE THIS VIEWER INDEPENDENT!!
-            switch (StructureViewer.getViewerType())
+
+          if (avm.containsArg(Arg.STRUCTUREIMAGE))
+          {
+            for (ArgValue structureImageArgValue : avm
+                    .getArgValueList(Arg.STRUCTUREIMAGE))
             {
-            case JMOL:
-              try
-              {
-                Thread.sleep(1000); // WHY ???
-              } catch (InterruptedException e)
+              String structureImageFilename = argParser.makeSubstitutions(
+                      structureImageArgValue.getValue(), id, true);
+              if (structureViewer != null && structureImageFilename != null)
               {
-                // TODO Auto-generated catch block
-                e.printStackTrace();
-              }
-              JalviewStructureDisplayI sview = sv
-                      .getJalviewStructureDisplay();
-              if (sview instanceof AppJmol)
-              {
-                AppJmol jmol = (AppJmol) sview;
+                SubVals structureImageSubVals = null;
+                structureImageSubVals = structureImageArgValue.getSubVals();
+                File structureImageFile = new File(structureImageFilename);
+                String width = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.WIDTH,
+                        structureImageSubVals);
+                String height = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.HEIGHT,
+                        structureImageSubVals);
+                String scale = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.SCALE,
+                        structureImageSubVals);
+                String renderer = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.TEXTRENDERER,
+                        structureImageSubVals);
+                String typeS = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.TYPE,
+                        structureImageSubVals);
+                if (typeS == null || typeS.length() == 0)
+                {
+                  typeS = FileUtils.getExtension(structureImageFile);
+                }
+                TYPE imageType;
+                try
+                {
+                  imageType = Enum.valueOf(TYPE.class,
+                          typeS.toUpperCase(Locale.ROOT));
+                } catch (IllegalArgumentException e)
+                {
+                  addWarn("Do not know image format '" + typeS
+                          + "', using PNG");
+                  imageType = TYPE.PNG;
+                }
+                BitmapImageSizing userBis = ImageMaker
+                        .parseScaleWidthHeightStrings(scale, width, height);
+
+                /////
+                // DON'T TRY TO EXPORT IF VIEWER IS UNSUPPORTED
+                if (viewerType != ViewerType.JMOL)
+                {
+                  addWarn("Cannot export image for structure viewer "
+                          + viewerType.name() + " yet");
+                  continue;
+                }
+
+                /////
+                // Apply the temporary colourscheme to the linked alignment
+                // TODO: enhance for multiple linked alignments.
+
+                String imageColour = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.IMAGECOLOUR,
+                        structureImageSubVals);
+                ColourSchemeI originalColourScheme = this
+                        .getColourScheme(af);
+                this.colourAlignFrame(af, imageColour);
+
+                /////
+                // custom image background colour
+
+                String bgcolourstring = avm.getValueFromSubValOrArg(
+                        structureImageArgValue, Arg.BGCOLOUR,
+                        structureImageSubVals);
+                Color bgcolour = null;
+                if (bgcolourstring != null && bgcolourstring.length() > 0)
+                {
+                  bgcolour = ColorUtils.parseColourString(bgcolourstring);
+                  if (bgcolour == null)
+                  {
+                    Console.warn(
+                            "Background colour string '" + bgcolourstring
+                                    + "' not recognised -- using default");
+                  }
+                }
+
+                JalviewStructureDisplayI sview = structureViewer
+                        .getJalviewStructureDisplay();
+
+                File sessionToRestore = null;
+
+                List<StructureCommandI> extraCommands = new ArrayList<>();
+
+                if (extraCommands.size() > 0 || bgcolour != null)
+                {
+                  try
+                  {
+                    sessionToRestore = sview.saveSession();
+                  } catch (Throwable t)
+                  {
+                    Console.warn(
+                            "Unable to save temporary session file before custom structure view export operation.");
+                  }
+                }
+
+                ////
+                // Do temporary ops
+
+                if (bgcolour != null)
+                {
+                  sview.getBinding().setBackgroundColour(bgcolour);
+                }
+
+                sview.getBinding().executeCommands(extraCommands, false,
+                        "Executing Custom Commands");
+
+                // and export the view as an image
+                boolean success = this.checksBeforeWritingToFile(avm,
+                        subVals, false, structureImageFilename,
+                        "structure image", isError);
+
+                if (!success)
+                {
+                  continue;
+                }
+                Console.debug("Rendering image to " + structureImageFile);
+                //
+                // TODO - extend StructureViewer / Binding with makePDBImage so
+                // we can do this with every viewer
+                //
+
                 try
                 {
-                  Console.debug("Rendering image to " + structureImageFile);
+                  // We don't expect class cast exception
+                  AppJmol jmol = (AppJmol) sview;
                   jmol.makePDBImage(structureImageFile, imageType, renderer,
                           userBis);
-                  Console.debug("Finished Rendering image to "
+                  Console.info("Exported structure image to "
                           + structureImageFile);
 
-                } catch (ImageOutputException ioexc)
+                  // RESTORE SESSION AFTER EXPORT IF NEED BE
+                  if (sessionToRestore != null)
+                  {
+                    Console.debug(
+                            "Restoring session from " + sessionToRestore);
+
+                    sview.getBinding().restoreSession(
+                            sessionToRestore.getAbsolutePath());
+
+                  }
+                } catch (ImageOutputException ioexec)
+                {
+                  addError(
+                          "Unexpected error when restoring structure viewer session after custom view operations.");
+                  isError = true;
+                  continue;
+                } finally
                 {
-                  Console.warn("Unexpected error whilst exporting image to "
-                          + structureImageFile, ioexc);
+                  try
+                  {
+                    this.colourAlignFrame(af, originalColourScheme);
+                  } catch (Exception t)
+                  {
+                    addError(
+                            "Unexpected error when restoring colourscheme to alignment after temporary change for export.",
+                            t);
+                  }
                 }
-
               }
-              break;
-            default:
-              Console.warn("Cannot export image for structure viewer "
-                      + sv.getViewerType() + " yet");
-              break;
             }
           }
+          argParser.setStructureFilename(null);
         }
       }
     }
 
+    if (wrap)
+    {
+      AlignFrame af = afMap.get(id);
+      if (af != null)
+      {
+        af.setWrapFormat(wrap, true);
+      }
+    }
+
     /*
     boolean doShading = avm.getBoolean(Arg.TEMPFAC_SHADING);
     if (doShading)
@@ -706,7 +859,7 @@ public class Commands
     }
     */
 
-    return theseArgsWereParsed;
+    return theseArgsWereParsed && !isError;
   }
 
   protected void processGroovyScript(String id)
@@ -714,21 +867,29 @@ public class Commands
     ArgValuesMap avm = argParser.getLinkedArgs(id);
     AlignFrame af = afMap.get(id);
 
-    if (af == null)
+    if (avm != null && !avm.containsArg(Arg.GROOVY))
     {
-      Console.warn("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);
+        }
       }
     }
   }
@@ -738,37 +899,45 @@ 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)
     {
-      Console.warn("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;
     }
 
+    Boolean isError = Boolean.valueOf(false);
     if (avm.containsArg(Arg.IMAGE))
     {
-      for (ArgValue av : avm.getArgValueList(Arg.IMAGE))
+      for (ArgValue imageAv : avm.getArgValueList(Arg.IMAGE))
       {
-        String val = av.getValue();
-        SubVals subVal = av.getSubVals();
-        String fileName = subVal.getContent();
+        String val = imageAv.getValue();
+        SubVals imageSubVals = imageAv.getSubVals();
+        String fileName = imageSubVals.getContent();
         File file = new File(fileName);
         String name = af.getName();
-        String renderer = ArgParser.getValueFromSubValOrArg(avm, av,
-                Arg.TEXTRENDERER, subVal);
+        String renderer = avm.getValueFromSubValOrArg(imageAv,
+                Arg.TEXTRENDERER, imageSubVals);
         if (renderer == null)
           renderer = "text";
         String type = "png"; // default
 
-        String scale = ArgParser.getValueFromSubValOrArg(avm, av, Arg.SCALE,
-                subVal);
-        String width = ArgParser.getValueFromSubValOrArg(avm, av, Arg.WIDTH,
-                subVal);
-        String height = ArgParser.getValueFromSubValOrArg(avm, av,
-                Arg.HEIGHT, subVal);
+        String scale = avm.getValueFromSubValOrArg(imageAv, Arg.SCALE,
+                imageSubVals);
+        String width = avm.getValueFromSubValOrArg(imageAv, Arg.WIDTH,
+                imageSubVals);
+        String height = avm.getValueFromSubValOrArg(imageAv, Arg.HEIGHT,
+                imageSubVals);
         BitmapImageSizing userBis = ImageMaker
                 .parseScaleWidthHeightStrings(scale, width, height);
 
-        type = ArgParser.getValueFromSubValOrArg(avm, av, Arg.TYPE, subVal);
+        type = avm.getValueFromSubValOrArg(imageAv, Arg.TYPE, imageSubVals);
         if (type == null && fileName != null)
         {
           for (String ext : new String[] { "svg", "png", "html", "eps" })
@@ -783,7 +952,20 @@ public class Commands
         Cache.setPropsAreReadOnly(true);
         Cache.setProperty("EXPORT_EMBBED_BIOJSON", "false");
 
+        String imageColour = avm.getValueFromSubValOrArg(imageAv,
+                Arg.IMAGECOLOUR, imageSubVals);
+        ColourSchemeI originalColourScheme = this.getColourScheme(af);
+        this.colourAlignFrame(af, imageColour);
+
         Console.info("Writing " + file);
+
+        boolean success = checksBeforeWritingToFile(avm, imageSubVals,
+                false, fileName, "image", isError);
+        if (!success)
+        {
+          continue;
+        }
+
         try
         {
           switch (type)
@@ -831,17 +1013,21 @@ public class Commands
             break;
 
           default:
-            Console.warn(Arg.IMAGE.argString() + " type '" + type
+            addWarn(Arg.IMAGE.argString() + " type '" + type
                     + "' not known. Ignoring");
             break;
           }
         } catch (Exception ioex)
         {
-          Console.warn("Unexpected error during export", ioex);
+          addError("Unexpected error during export to '" + fileName + "'",
+                  ioex);
+          isError = true;
         }
+
+        this.colourAlignFrame(af, originalColourScheme);
       }
     }
-    return true;
+    return !isError;
   }
 
   protected boolean processOutput(String id)
@@ -849,12 +1035,21 @@ 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)
     {
-      Console.warn("Did not have an alignment window for id=" + id);
+      addWarn("Do not have an alignment window (id=" + id
+              + ").  Not proceeding.");
       return false;
     }
 
+    Boolean isError = Boolean.valueOf(false);
+
     if (avm.containsArg(Arg.OUTPUT))
     {
       for (ArgValue av : avm.getArgValueList(Arg.OUTPUT))
@@ -862,29 +1057,12 @@ public class Commands
         String val = av.getValue();
         SubVals subVals = av.getSubVals();
         String fileName = subVals.getContent();
+        boolean stdout = ArgParser.STDOUTFILENAME.equals(fileName);
         File file = new File(fileName);
-        boolean overwrite = ArgParser.getFromSubValArgOrPref(avm,
-                Arg.OVERWRITE, subVals, null, "OVERWRITE_OUTPUT", false);
-        // backups. Use the Arg.BACKUPS or subval "backups" setting first,
-        // otherwise if headless assume false, if not headless use the user
-        // preference with default true.
-        boolean backups = ArgParser.getFromSubValArgOrPref(avm, Arg.BACKUPS,
-                subVals, null,
-                Platform.isHeadless() ? null : BackupFiles.ENABLED,
-                !Platform.isHeadless());
-
-        // if backups is not true then --overwrite must be specified
-        if (file.exists() && !(overwrite || backups))
-        {
-          Console.error("Won't overwrite file '" + fileName + "' without "
-                  + Arg.OVERWRITE.argString() + " or "
-                  + Arg.BACKUPS.argString() + " set");
-          return false;
-        }
 
         String name = af.getName();
-        String format = ArgParser.getValueFromSubValOrArg(avm, av,
-                Arg.FORMAT, subVals);
+        String format = avm.getValueFromSubValOrArg(av, Arg.FORMAT,
+                subVals);
         FileFormats ffs = FileFormats.getInstance();
         List<String> validFormats = ffs.getWritableFormats(false);
 
@@ -912,59 +1090,68 @@ public class Commands
         }
         if (ff == null)
         {
-          StringBuilder validSB = new StringBuilder();
-          for (String f : validFormats)
-          {
-            if (validSB.length() > 0)
-              validSB.append(", ");
-            validSB.append(f);
-            FileFormatI tff = ffs.forName(f);
-            validSB.append(" (");
-            validSB.append(tff.getExtensions());
-            validSB.append(")");
-          }
-
-          Jalview.exit("No valid format specified for "
-                  + Arg.OUTPUT.argString() + ". Valid formats are "
-                  + validSB.toString() + ".", 1);
-          // this return really shouldn't happen
-          return false;
+          if (stdout)
+          {
+            ff = FileFormat.Fasta;
+          }
+          else
+          {
+            StringBuilder validSB = new StringBuilder();
+            for (String f : validFormats)
+            {
+              if (validSB.length() > 0)
+                validSB.append(", ");
+              validSB.append(f);
+              FileFormatI tff = ffs.forName(f);
+              validSB.append(" (");
+              validSB.append(tff.getExtensions());
+              validSB.append(")");
+            }
+
+            addError("No valid format specified for "
+                    + Arg.OUTPUT.argString() + ". Valid formats are "
+                    + validSB.toString() + ".");
+            continue;
+          }
         }
 
-        String savedBackupsPreference = Cache
-                .getDefault(BackupFiles.ENABLED, null);
-        Console.debug("Setting backups to " + backups);
-        Cache.applicationProperties.put(BackupFiles.ENABLED,
-                Boolean.toString(backups));
+        boolean success = checksBeforeWritingToFile(avm, subVals, true,
+                fileName, ff.getName(), isError);
+        if (!success)
+        {
+          continue;
+        }
+
+        boolean backups = avm.getFromSubValArgOrPref(Arg.BACKUPS, subVals,
+                null, Platform.isHeadless() ? null : BackupFiles.ENABLED,
+                !Platform.isHeadless());
 
         Console.info("Writing " + fileName);
 
-        af.saveAlignment(fileName, ff);
-        Console.debug("Returning backups to " + savedBackupsPreference);
-        if (savedBackupsPreference != null)
-          Cache.applicationProperties.put(BackupFiles.ENABLED,
-                  savedBackupsPreference);
+        af.saveAlignment(fileName, ff, stdout, backups);
         if (af.isSaveAlignmentSuccessful())
         {
           Console.debug("Written alignment '" + name + "' in "
-                  + ff.getName() + " format to " + file);
+                  + ff.getName() + " format to '" + file + "'");
         }
         else
         {
-          Console.warn("Error writing file " + file + " in " + ff.getName()
+          addError("Error writing file '" + file + "' in " + ff.getName()
                   + " format!");
+          isError = true;
+          continue;
         }
 
       }
     }
-    return true;
+    return !isError;
   }
 
   private SequenceI getSpecifiedSequence(AlignFrame af, ArgValuesMap avm,
           ArgValue av)
   {
     SubVals subVals = av.getSubVals();
-    ArgValue idAv = avm.getClosestNextArgValueOfArg(av, Arg.SEQID);
+    ArgValue idAv = avm.getClosestNextArgValueOfArg(av, Arg.SEQID, true);
     SequenceI seq = null;
     if (subVals == null && idAv == null)
       return null;
@@ -989,10 +1176,155 @@ public class Commands
         seq = al.getSequenceAt(subVals.getIndex());
       }
     }
-    else if (idAv != null)
+    if (seq == null && idAv != null)
     {
       seq = al.findName(idAv.getValue());
     }
     return seq;
   }
+
+  public AlignFrame[] getAlignFrames()
+  {
+    AlignFrame[] afs = null;
+    if (afMap != null)
+    {
+      afs = (AlignFrame[]) afMap.values().toArray();
+    }
+
+    return afs;
+  }
+
+  public List<StructureViewer> getStructureViewers()
+  {
+    List<StructureViewer> svs = null;
+    if (svMap != null)
+    {
+      for (List<StructureViewer> svList : svMap.values())
+      {
+        if (svs == null)
+        {
+          svs = new ArrayList<>();
+        }
+        svs.addAll(svList);
+      }
+    }
+    return svs;
+  }
+
+  private void colourAlignFrame(AlignFrame af, String colour)
+  {
+    // use string "none" to remove colour scheme
+    if (colour != null && "" != colour)
+    {
+      ColourSchemeI cs = ColourSchemeProperty.getColourScheme(
+              af.getViewport(), af.getViewport().getAlignment(), colour);
+      if (cs == null && !StringUtils.equalsIgnoreCase(colour, "none"))
+      {
+        addWarn("Couldn't parse '" + colour + "' as a colourscheme.");
+      }
+      else
+      {
+        Jalview.testoutput(argParser, Arg.COLOUR, "zappo", colour);
+        colourAlignFrame(af, cs);
+      }
+    }
+  }
+
+  private void colourAlignFrame(AlignFrame af, ColourSchemeI cs)
+  {
+    // Note that cs == null removes colour scheme from af
+    af.changeColour(cs);
+  }
+
+  private ColourSchemeI getColourScheme(AlignFrame af)
+  {
+    return af.getViewport().getGlobalColourScheme();
+  }
+
+  private void addInfo(String errorMessage)
+  {
+    Console.info(errorMessage);
+    errors.add(errorMessage);
+  }
+
+  private void addWarn(String errorMessage)
+  {
+    Console.warn(errorMessage);
+    errors.add(errorMessage);
+  }
+
+  private void addError(String errorMessage)
+  {
+    addError(errorMessage, null);
+  }
+
+  private void addError(String errorMessage, Exception e)
+  {
+    Console.error(errorMessage, e);
+    errors.add(errorMessage);
+  }
+
+  private boolean checksBeforeWritingToFile(ArgValuesMap avm,
+          SubVals subVal, boolean includeBackups, String filename,
+          String adjective, Boolean isError)
+  {
+    File file = new File(filename);
+
+    boolean overwrite = avm.getFromSubValArgOrPref(Arg.OVERWRITE, subVal,
+            null, "OVERWRITE_OUTPUT", false);
+    boolean stdout = false;
+    boolean backups = false;
+    if (includeBackups)
+    {
+      stdout = ArgParser.STDOUTFILENAME.equals(filename);
+      // backups. Use the Arg.BACKUPS or subval "backups" setting first,
+      // otherwise if headless assume false, if not headless use the user
+      // preference with default true.
+      backups = avm.getFromSubValArgOrPref(Arg.BACKUPS, subVal, null,
+              Platform.isHeadless() ? null : BackupFiles.ENABLED,
+              !Platform.isHeadless());
+    }
+
+    if (file.exists() && !(overwrite || backups || stdout))
+    {
+      addWarn("Won't overwrite file '" + filename + "' without "
+              + Arg.OVERWRITE.argString()
+              + (includeBackups ? " or " + Arg.BACKUPS.argString() : "")
+              + " set");
+      return false;
+    }
+
+    boolean mkdirs = avm.getFromSubValArgOrPref(Arg.MKDIRS, subVal, null,
+            "MKDIRS_OUTPUT", false);
+
+    if (!FileUtils.checkParentDir(file, mkdirs))
+    {
+      addError("Directory '"
+              + FileUtils.getParentDir(file).getAbsolutePath()
+              + "' does not exist for " + adjective + " file '" + filename
+              + "'."
+              + (mkdirs ? "" : "  Try using " + Arg.MKDIRS.argString()));
+      isError = true;
+      return false;
+    }
+
+    return true;
+  }
+
+  public List<String> getErrors()
+  {
+    return errors;
+  }
+
+  public String errorsToString()
+  {
+    StringBuilder sb = new StringBuilder();
+    for (String error : errors)
+    {
+      if (sb.length() > 0)
+        sb.append("\n");
+      sb.append("- " + error);
+    }
+    return sb.toString();
+  }
 }
index 30fd530..1bb8162 100644 (file)
  */
 package jalview.bin;
 
-import java.util.Locale;
+import java.io.PrintStream;
 
 import jalview.log.JLogger;
-import jalview.log.JLoggerI;
 import jalview.log.JLoggerI.LogLevel;
 import jalview.log.JLoggerLog4j;
 import jalview.util.ChannelProperties;
@@ -43,8 +42,8 @@ public class Console
     }
     else
     {
-      System.out.println(message);
-      t.printStackTrace();
+      outPrintln(message);
+      Console.printStackTrace(t);
     }
 
   }
@@ -57,7 +56,7 @@ public class Console
     }
     else
     {
-      System.out.println(message);
+      outPrintln(message);
     }
 
   }
@@ -70,8 +69,8 @@ public class Console
     }
     else
     {
-      System.out.println(message);
-      t.printStackTrace();
+      outPrintln(message);
+      Console.printStackTrace(t);
     }
   }
 
@@ -83,7 +82,7 @@ public class Console
     }
     else
     {
-      System.out.println(message);
+      outPrintln(message);
     }
 
   }
@@ -96,8 +95,8 @@ public class Console
     }
     else
     {
-      System.out.println(message);
-      t.printStackTrace();
+      outPrintln(message);
+      Console.printStackTrace(t);
     }
 
   }
@@ -110,7 +109,7 @@ public class Console
     }
     else
     {
-      System.out.println(message);
+      outPrintln(message);
     }
 
   }
@@ -123,7 +122,7 @@ public class Console
     }
     else
     {
-      System.out.println(message);
+      outPrintln(message);
     }
   }
 
@@ -135,8 +134,8 @@ public class Console
     }
     else
     {
-      System.out.println(message);
-      t.printStackTrace();
+      outPrintln(message);
+      Console.printStackTrace(t);
     }
 
   }
@@ -149,7 +148,7 @@ public class Console
     }
     else
     {
-      System.err.println(message);
+      jalview.bin.Console.errPrintln(message);
     }
 
   }
@@ -162,8 +161,8 @@ public class Console
     }
     else
     {
-      System.err.println(message);
-      t.printStackTrace(System.err);
+      jalview.bin.Console.errPrintln(message);
+      Console.printStackTrace(t);
     }
 
   }
@@ -176,7 +175,7 @@ public class Console
     }
     else
     {
-      System.err.println(message);
+      jalview.bin.Console.errPrintln(message);
     }
 
   }
@@ -189,8 +188,8 @@ public class Console
     }
     else
     {
-      System.err.println(message);
-      t.printStackTrace(System.err);
+      jalview.bin.Console.errPrintln(message);
+      Console.printStackTrace(t);
     }
 
   }
@@ -240,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);
       }
@@ -253,7 +252,7 @@ public class Console
       {
         if (!Jalview.quiet())
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Setting initial log level to " + logLevel.name());
         }
         Log4j.init(logLevel);
@@ -267,8 +266,9 @@ public class Console
       log = JLoggerLog4j.getLogger(Cache.JALVIEW_LOGGER_NAME, logLevel);
     } catch (NoClassDefFoundError e)
     {
-      System.err.println("Could not initialise the logger framework");
-      e.printStackTrace();
+      jalview.bin.Console
+              .errPrintln("Could not initialise the logger framework");
+      Console.printStackTrace(e);
     }
 
     // Test message
@@ -290,22 +290,116 @@ 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);
+    }
+  }
+
+  public static void outPrint()
+  {
+    outPrint("");
+  }
+
+  public static void outPrintln()
+  {
+    outPrintln("");
+  }
+
+  public static void outPrint(Object message)
+  {
+    outPrintMessage(message, false, false);
+  }
+
+  public static void outPrint(Object message, boolean forceStdout)
+  {
+    outPrintMessage(message, false, forceStdout);
+  }
+
+  public static void outPrintln(Object message)
+  {
+    outPrintMessage(message, true, false);
+  }
+
+  public static PrintStream outputStream(boolean forceStdout)
+  {
+    // send message to stderr if an output file to stdout is expected
+    if (!forceStdout && Jalview.getInstance() != null
+            && Jalview.getInstance().getBootstrapArgs() != null
+            && Jalview.getInstance().getBootstrapArgs().outputToStdout())
+    {
+      return System.err;
+    }
+    else
+    {
+      return System.out;
+    }
+  }
+
+  public static void outPrintMessage(Object message, boolean newline,
+          boolean forceStdout)
+  {
+    PrintStream ps = outputStream(forceStdout);
+    if (newline)
+    {
+      ps.println(message);
     }
+    else
+    {
+      ps.print(message);
+    }
+  }
+
+  public static void errPrint()
+  {
+    errPrint("");
+  }
+
+  public static void errPrintln()
+  {
+    errPrintln("");
+  }
+
+  public static void errPrint(Object message)
+  {
+    System.err.print(message);
+  }
+
+  public static void errPrintln(Object message)
+  {
+    System.err.println(message);
+  }
+
+  public static void debugPrintStackTrace(Throwable t)
+  {
+    if (!isDebugEnabled())
+    {
+      return;
+    }
+    // send message to stderr if output to stdout is expected
+    printStackTrace(t);
+  }
+
+  public static void printStackTrace(Throwable t)
+  {
+    // send message to stderr if output to stdout is expected
+    t.printStackTrace(System.err);
   }
 
   public final static String LOGGING_TEST_MESSAGE = "Logging to STDERR";
 
-}
+}
\ No newline at end of file
index b01dfb8..5332704 100644 (file)
@@ -61,7 +61,7 @@ class GetMemory
     } catch (NoClassDefFoundError e)
     {
       // com.sun.management.OperatingSystemMXBean doesn't exist in this JVM
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "No com.sun.management.OperatingSystemMXBean: cannot get total physical memory size");
     }
 
index 2bce673..e14c032 100644 (file)
@@ -20,9 +20,8 @@
  */
 package jalview.bin;
 
-import java.util.Locale;
-
 import java.awt.HeadlessException;
+import java.util.Locale;
 
 public class HiDPISetting
 {
@@ -117,8 +116,9 @@ public class HiDPISetting
         }
       } catch (NumberFormatException e)
       {
-        System.err.println(setHiDPIScalePropertyName + " property give ("
-                + setHiDPIScaleProperty + ") but not parseable as integer");
+        jalview.bin.Console.errPrintln(setHiDPIScalePropertyName
+                + " property give (" + setHiDPIScaleProperty
+                + ") but not parseable as integer");
       }
     }
     if (setHiDPI && setHiDPIScale > 0)
@@ -135,8 +135,8 @@ public class HiDPISetting
       try
       {
         int existingPropertyVal = Integer.parseInt(existingProperty);
-        System.out.println("Existing " + scalePropertyName + " is "
-                + existingPropertyVal);
+        jalview.bin.Console.outPrintln("Existing " + scalePropertyName
+                + " is " + existingPropertyVal);
         if (existingPropertyVal > 1)
         {
           setHiDPIScale(existingPropertyVal);
@@ -144,8 +144,9 @@ public class HiDPISetting
         }
       } catch (NumberFormatException e)
       {
-        System.out.println("Could not convert property " + scalePropertyName
-                + " vale '" + existingProperty + "' to number");
+        jalview.bin.Console.outPrintln(
+                "Could not convert property " + scalePropertyName
+                        + " vale '" + existingProperty + "' to number");
       }
     }
 
@@ -159,7 +160,11 @@ public class HiDPISetting
       dpi = screenInfo.getScreenResolution();
     } catch (HeadlessException e)
     {
-      System.err.println("Cannot get screen resolution: " + e.getMessage());
+      if (isLinux)
+      {
+        jalview.bin.Console.errPrintln(
+                "Cannot get screen resolution: " + e.getMessage());
+      }
     }
 
     // try and get screen size height and width
@@ -171,8 +176,12 @@ public class HiDPISetting
       mindimension = Math.min(height, width);
     } catch (HeadlessException e)
     {
-      System.err.println(
-              "Cannot get screen size height and width:" + e.getMessage());
+      if (isLinux)
+      {
+        jalview.bin.Console
+                .errPrintln("Cannot get screen size height and width:"
+                        + e.getMessage());
+      }
     }
 
     // attempt at a formula for scaling based on screen dpi and mindimension.
index 57f2575..e343b0f 100755 (executable)
@@ -73,9 +73,12 @@ 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;
+import jalview.gui.JvOptionPane;
 import jalview.gui.PromptUserConfig;
 import jalview.gui.QuitHandler;
 import jalview.gui.QuitHandler.QResponse;
@@ -117,7 +120,7 @@ import jalview.ws.jws2.Jws2Discoverer;
  * @author $author$
  * @version $Revision$
  */
-public class Jalview
+public class Jalview implements JalviewObjectI
 {
   static
   {
@@ -137,11 +140,11 @@ public class Jalview
 
   protected Commands cmds;
 
-  public static AlignFrame currentAlignFrame;
+  public AlignFrame currentAlignFrame = null;
 
-  public ArgParser argparser = null;
+  private ArgParser argparser = null;
 
-  public BootstrapArgs bootstrapArgs = null;
+  private BootstrapArgs bootstrapArgs = null;
 
   private boolean QUIET = false;
 
@@ -274,7 +277,7 @@ public class Jalview
      * 
      */
     {
-      System.out.println("not in js");
+      Console.outPrintln("not in js");
     }
 
     // BH - for event debugging in JavaScript (Java mode only)
@@ -383,29 +386,30 @@ public class Jalview
       }.start();
     }
 
-    if (!quiet() || bootstrapArgs.contains(Arg.VERSION))
+    if (!quiet() || !bootstrapArgs.outputToStdout()
+            || bootstrapArgs.contains(Arg.VERSION))
     {
-      System.out.println(
+      Console.outPrintln(
               "Java version: " + System.getProperty("java.version"));
-      System.out.println("Java home: " + System.getProperty("java.home"));
-      System.out.println("Java arch: " + System.getProperty("os.arch") + " "
+      Console.outPrintln("Java home: " + System.getProperty("java.home"));
+      Console.outPrintln("Java arch: " + System.getProperty("os.arch") + " "
               + System.getProperty("os.name") + " "
               + System.getProperty("os.version"));
 
       String val = System.getProperty("sys.install4jVersion");
       if (val != null)
       {
-        System.out.println("Install4j version: " + val);
+        Console.outPrintln("Install4j version: " + val);
       }
       val = System.getProperty("installer_template_version");
       if (val != null)
       {
-        System.out.println("Install4j template version: " + val);
+        Console.outPrintln("Install4j template version: " + val);
       }
       val = System.getProperty("launcher_version");
       if (val != null)
       {
-        System.out.println("Launcher version: " + val);
+        Console.outPrintln("Launcher version: " + val);
       }
     }
 
@@ -425,7 +429,7 @@ public class Jalview
     // stop now if only after --version
     if (bootstrapArgs.contains(Arg.VERSION))
     {
-      Jalview.exit(null, 0);
+      Jalview.exit(null, ExitCode.OK);
     }
 
     // old ArgsParser
@@ -445,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))
       {
@@ -457,12 +461,13 @@ public class Jalview
       error.printStackTrace();
       String message = "\nEssential logging libraries not found."
               + "\nUse: java -classpath \"$PATH_TO_LIB$/*:$PATH_TO_CLASSES$\" jalview.bin.Jalview";
-      Jalview.exit(message, 0);
+      Jalview.exit(message, ExitCode.OK);
     }
 
     // register SIGTERM listener
     Runtime.getRuntime().addShutdownHook(new Thread()
     {
+      @Override
       public void run()
       {
         Console.debug("Running shutdown hook");
@@ -509,7 +514,7 @@ public class Jalview
     Cache.loadProperties(usrPropsFile);
     if (usrPropsFile != null)
     {
-      System.out.println(
+      Console.outPrintln(
               "CMD [-props " + usrPropsFile + "] executed successfully!");
       testoutput(bootstrapArgs, Arg.PROPS,
               "test/jalview/bin/testProps.jvprops", usrPropsFile);
@@ -541,9 +546,9 @@ public class Jalview
       {
         List<Map.Entry<Type, String>> helpArgs = bootstrapArgs
                 .getList(Arg.HELP);
-        System.out.println(Arg.usage(helpArgs.stream().map(e -> e.getKey())
+        Console.outPrintln(Arg.usage(helpArgs.stream().map(e -> e.getKey())
                 .collect(Collectors.toList())));
-        Jalview.exit(null, 0);
+        Jalview.exit(null, ExitCode.OK);
       }
       if (aparser.contains("help") || aparser.contains("h"))
       {
@@ -551,8 +556,8 @@ public class Jalview
          * Now using new usage statement.
         showUsage();
         */
-        System.out.println(Arg.usage());
-        Jalview.exit(null, 0);
+        Console.outPrintln(Arg.usage());
+        Jalview.exit(null, ExitCode.OK);
       }
 
       // new CLI
@@ -581,13 +586,13 @@ public class Jalview
         try
         {
           Jws2Discoverer.getDiscoverer().setPreferredUrl(jabawsUrl);
-          System.out.println(
+          Console.outPrintln(
                   "CMD [-jabaws " + jabawsUrl + "] executed successfully!");
           testoutput(bootstrapArgs, Arg.JABAWS,
                   "http://www.compbio.dundee.ac.uk/jabaws", jabawsUrl);
         } catch (MalformedURLException e)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Invalid jabaws parameter: " + jabawsUrl + " ignored");
         }
       }
@@ -617,7 +622,8 @@ public class Jalview
       }
       else
       {
-        System.out.println("Executing setprop argument: " + setprop);
+        jalview.bin.Console
+                .errPrintln("Executing setprop argument: " + setprop);
         if (Platform.isJS())
         {
           Cache.setProperty(setprop.substring(0, p),
@@ -638,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, 0);
+      Jalview.exit(message, ExitCode.NO_LOGGING);
     }
     desktop = null;
 
@@ -670,6 +674,8 @@ public class Jalview
       desktop = new Desktop();
       desktop.setInBatchMode(true); // indicate we are starting up
 
+      mixedCliWarning();
+
       try
       {
         JalviewTaskbar.setTaskbar(this);
@@ -749,7 +755,7 @@ public class Jalview
         }
         else
         {
-          System.out.println("CMD [-nousagestats] executed successfully!");
+          Console.outPrintln("CMD [-nousagestats] executed successfully!");
           testoutput(argparser, Arg.NOUSAGESTATS);
         }
 
@@ -765,7 +771,7 @@ public class Jalview
             // questionnaire
             Console.debug("Starting questionnaire url at " + url);
             desktop.checkForQuestionnaire(url);
-            System.out.println("CMD questionnaire[-" + url
+            Console.outPrintln("CMD questionnaire[-" + url
                     + "] executed successfully!");
           }
           else
@@ -786,8 +792,8 @@ public class Jalview
         }
         else
         {
-          System.out
-                  .println("CMD [-noquestionnaire] executed successfully!");
+          Console.outPrintln(
+                  "CMD [-noquestionnaire] executed successfully!");
           testoutput(argparser, Arg.QUESTIONNAIRE);
         }
 
@@ -806,8 +812,33 @@ public class Jalview
         }
       }
     }
+    else
+    {
+
+      if (getArgParser().isMixedStyle())
+      {
+        String warning = MessageManager.formatMessage(
+                "warning.using_mixed_command_line_arguments",
+                getArgParser().getMixedExamples());
+        Console.warn(warning);
+        Jalview.exit(
+                "Exiting due to mixed old and new command line arguments",
+                ExitCode.INVALID_ARGUMENT);
+      }
+      if (getArgParser().isOldStyle())
+      {
+        String warning = MessageManager
+                .getString("warning.using_old_command_line_arguments")
+                .replace("\n", " ")
+                + "https://www.jalview.org/help/html/features/commandline.html";
+        Console.warn(warning);
+      }
+
+    }
+
     // Run Commands from cli
     cmds = new Commands(argparser, headlessArg);
+    cmds.processArgs();
     boolean commandsSuccess = cmds.argsWereParsed();
 
     if (commandsSuccess)
@@ -823,7 +854,7 @@ public class Jalview
         else
         {
           Jalview.exit("Successfully completed commands in headless mode",
-                  0);
+                  ExitCode.OK);
         }
       }
       Console.info("Successfully completed commands");
@@ -832,7 +863,8 @@ public class Jalview
     {
       if (headlessArg)
       {
-        Jalview.exit("Error when running Commands in headless mode", 1);
+        Jalview.exit("Error when running Commands in headless mode",
+                ExitCode.ERROR_RUNNING_COMMANDS);
       }
       Console.warn("Error when running commands");
     }
@@ -863,7 +895,7 @@ public class Jalview
 
     if (file == null && desktop == null && !commandsSuccess)
     {
-      Jalview.exit("No files to open!", 1);
+      Jalview.exit("No files to open!", ExitCode.NO_FILES);
     }
 
     long progress = -1;
@@ -877,7 +909,7 @@ public class Jalview
                         .getString("status.processing_commandline_args"),
                 progress = System.currentTimeMillis());
       }
-      System.out.println("CMD [-open " + file + "] executed successfully!");
+      Console.outPrintln("CMD [-open " + file + "] executed successfully!");
 
       if (!Platform.isJS())
       /**
@@ -893,7 +925,8 @@ public class Jalview
             if (headless)
             {
               Jalview.exit(
-                      "Can't find file '" + file + "' in headless mode", 1);
+                      "Can't find file '" + file + "' in headless mode",
+                      ExitCode.FILE_NOT_FOUND);
             }
             Console.warn("Can't find file'" + file + "'");
           }
@@ -914,7 +947,7 @@ public class Jalview
               format);
       if (af == null)
       {
-        System.out.println("error");
+        Console.outPrintln("error");
       }
       else
       {
@@ -929,7 +962,7 @@ public class Jalview
 
           if (cs != null)
           {
-            System.out.println(
+            Console.outPrintln(
                     "CMD [-colour " + data + "] executed successfully!");
           }
           af.changeColour(cs);
@@ -941,8 +974,8 @@ public class Jalview
         {
           af.parseFeaturesFile(data,
                   AppletFormatAdapter.checkProtocol(data));
-          // System.out.println("Added " + data);
-          System.out.println(
+          // Console.outPrintln("Added " + data);
+          Console.outPrintln(
                   "CMD groups[-" + data + "]  executed successfully!");
         }
         data = aparser.getValue("features", true);
@@ -950,8 +983,8 @@ public class Jalview
         {
           af.parseFeaturesFile(data,
                   AppletFormatAdapter.checkProtocol(data));
-          // System.out.println("Added " + data);
-          System.out.println(
+          // Console.outPrintln("Added " + data);
+          Console.outPrintln(
                   "CMD [-features " + data + "]  executed successfully!");
         }
 
@@ -959,8 +992,8 @@ public class Jalview
         if (data != null)
         {
           af.loadJalviewDataFile(data, null, null, null);
-          // System.out.println("Added " + data);
-          System.out.println(
+          // Console.outPrintln("Added " + data);
+          Console.outPrintln(
                   "CMD [-annotations " + data + "] executed successfully!");
         }
         // set or clear the sortbytree flag.
@@ -969,7 +1002,7 @@ public class Jalview
           af.getViewport().setSortByTree(true);
           if (af.getViewport().getSortByTree())
           {
-            System.out.println("CMD [-sortbytree] executed successfully!");
+            Console.outPrintln("CMD [-sortbytree] executed successfully!");
           }
         }
         if (aparser.contains("no-annotation"))
@@ -977,7 +1010,7 @@ public class Jalview
           af.getViewport().setShowAnnotation(false);
           if (!af.getViewport().isShowAnnotation())
           {
-            System.out.println("CMD no-annotation executed successfully!");
+            Console.outPrintln("CMD no-annotation executed successfully!");
           }
         }
         if (aparser.contains("nosortbytree"))
@@ -985,8 +1018,8 @@ public class Jalview
           af.getViewport().setSortByTree(false);
           if (!af.getViewport().getSortByTree())
           {
-            System.out
-                    .println("CMD [-nosortbytree] executed successfully!");
+            Console.outPrintln(
+                    "CMD [-nosortbytree] executed successfully!");
           }
         }
         data = aparser.getValue("tree", true);
@@ -994,7 +1027,7 @@ public class Jalview
         {
           try
           {
-            System.out.println(
+            Console.outPrintln(
                     "CMD [-tree " + data + "] executed successfully!");
             NewickFile nf = new NewickFile(data,
                     AppletFormatAdapter.checkProtocol(data));
@@ -1002,7 +1035,7 @@ public class Jalview
                     .setCurrentTree(af.showNewickTree(nf, data).getTree());
           } catch (IOException ex)
           {
-            System.err.println("Couldn't add tree " + data);
+            jalview.bin.Console.errPrintln("Couldn't add tree " + data);
             ex.printStackTrace(System.err);
           }
         }
@@ -1011,9 +1044,9 @@ public class Jalview
         {
           // Execute the groovy script after we've done all the rendering stuff
           // and before any images or figures are generated.
-          System.out.println("Executing script " + groovyscript);
+          Console.outPrintln("Executing script " + groovyscript);
           executeGroovyScript(groovyscript, af);
-          System.out.println("CMD groovy[" + groovyscript
+          Console.outPrintln("CMD groovy[" + groovyscript
                   + "] executed successfully!");
           groovyscript = null;
         }
@@ -1027,14 +1060,14 @@ public class Jalview
 
             if (outputFormat.equalsIgnoreCase("png"))
             {
-              System.out.println("Creating PNG image: " + file);
+              Console.outPrintln("Creating PNG image: " + file);
               af.createPNG(new File(file));
               imageName = (new File(file)).getName();
               continue;
             }
             else if (outputFormat.equalsIgnoreCase("svg"))
             {
-              System.out.println("Creating SVG image: " + file);
+              Console.outPrintln("Creating SVG image: " + file);
               File imageFile = new File(file);
               imageName = imageFile.getName();
               af.createSVG(imageFile);
@@ -1046,7 +1079,7 @@ public class Jalview
               imageName = imageFile.getName();
               HtmlSvgOutput htmlSVG = new HtmlSvgOutput(af.alignPanel);
 
-              System.out.println("Creating HTML image: " + file);
+              Console.outPrintln("Creating HTML image: " + file);
               htmlSVG.exportHTML(file);
               continue;
             }
@@ -1054,7 +1087,8 @@ public class Jalview
             {
               if (file == null)
               {
-                System.err.println("The output html file must not be null");
+                jalview.bin.Console.errPrintln(
+                        "The output html file must not be null");
                 return;
               }
               try
@@ -1066,21 +1100,21 @@ public class Jalview
                 e.printStackTrace();
               }
               BioJsHTMLOutput bjs = new BioJsHTMLOutput(af.alignPanel);
-              System.out.println(
+              Console.outPrintln(
                       "Creating BioJS MSA Viwer HTML file: " + file);
               bjs.exportHTML(file);
               continue;
             }
             else if (outputFormat.equalsIgnoreCase("imgMap"))
             {
-              System.out.println("Creating image map: " + file);
+              Console.outPrintln("Creating image map: " + file);
               af.createImageMap(new File(file), imageName);
               continue;
             }
             else if (outputFormat.equalsIgnoreCase("eps"))
             {
               File outputFile = new File(file);
-              System.out.println(
+              Console.outPrintln(
                       "Creating EPS file: " + outputFile.getAbsolutePath());
               af.createEPS(outputFile);
               continue;
@@ -1092,14 +1126,14 @@ public class Jalview
               outFormat = FileFormats.getInstance().forName(outputFormat);
             } catch (Exception formatP)
             {
-              System.out.println("Couldn't parse " + outFormat
+              Console.outPrintln("Couldn't parse " + outFormat
                       + " as a valid Jalview format string.");
             }
             if (outFormat != null)
             {
               if (!outFormat.isWritable())
               {
-                System.out.println(
+                Console.outPrintln(
                         "This version of Jalview does not support alignment export as "
                                 + outputFormat);
               }
@@ -1108,19 +1142,19 @@ public class Jalview
                 af.saveAlignment(file, outFormat);
                 if (af.isSaveAlignmentSuccessful())
                 {
-                  System.out.println("Written alignment in "
+                  Console.outPrintln("Written alignment in "
                           + outFormat.getName() + " format to " + file);
                 }
                 else
                 {
-                  System.out.println("Error writing file " + file + " in "
+                  Console.outPrintln("Error writing file " + file + " in "
                           + outFormat.getName() + " format!!");
                 }
               }
             }
           } catch (ImageOutputException ioexc)
           {
-            System.out.println(
+            Console.outPrintln(
                     "Unexpected error whilst exporting image to " + file);
             ioexc.printStackTrace();
           }
@@ -1129,7 +1163,7 @@ public class Jalview
 
         while (aparser.getSize() > 0)
         {
-          System.out.println("Unknown arg: " + aparser.nextValue());
+          Console.outPrintln("Unknown arg: " + aparser.nextValue());
         }
       }
     }
@@ -1197,12 +1231,12 @@ public class Jalview
     {
       if (Cache.groovyJarsPresent())
       {
-        System.out.println("Executing script " + groovyscript);
+        Console.outPrintln("Executing script " + groovyscript);
         executeGroovyScript(groovyscript, startUpAlframe);
       }
       else
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Sorry. Groovy Support is not available, so ignoring the provided groovy script "
                         + groovyscript);
       }
@@ -1216,6 +1250,8 @@ public class Jalview
       }
       desktop.setInBatchMode(false);
     }
+
+    cliWarning();
   }
 
   private static void setLookAndFeel()
@@ -1497,7 +1533,7 @@ public class Jalview
       UIManager.put("TabbedPane.tabType", "card");
       UIManager.put("TabbedPane.showTabSeparators", true);
       UIManager.put("TabbedPane.showContentSeparator", true);
-      UIManager.put("TabbedPane.tabSeparatorsFullHeight", true);
+      // UIManager.put("TabbedPane.tabSeparatorsFullHeight", true);
       UIManager.put("TabbedPane.tabsOverlapBorder", true);
       UIManager.put("TabbedPane.hasFullBorder", true);
       UIManager.put("TabbedPane.tabLayoutPolicy", "scroll");
@@ -1547,7 +1583,7 @@ public class Jalview
   /*
   private static void showUsage()
   {
-    System.out.println(
+    jalview.bin.Console.outPrintln(
             "Usage: jalview -open [FILE] [OUTPUT_FORMAT] [OUTPUT_FILE]\n\n"
                     + "-nodisplay\tRun Jalview without User Interface.\n"
                     + "-props FILE\tUse the given Jalview properties file instead of users default.\n"
@@ -1596,9 +1632,8 @@ public class Jalview
      */
     PromptUserConfig prompter = new PromptUserConfig(Desktop.desktop,
             "USAGESTATS",
-            MessageManager.getString("prompt.plausible_analytics_title"),
-            MessageManager.getString("prompt.plausible_analytics"),
-            new Runnable()
+            MessageManager.getString("prompt.analytics_title"),
+            MessageManager.getString("prompt.analytics"), new Runnable()
             {
               @Override
               public void run()
@@ -1658,9 +1693,10 @@ public class Jalview
 
       } catch (Exception ex)
       {
-        System.err.println("Failed to read from STDIN into tempfile "
-                + ((tfile == null) ? "(tempfile wasn't created)"
-                        : tfile.toString()));
+        jalview.bin.Console
+                .errPrintln("Failed to read from STDIN into tempfile "
+                        + ((tfile == null) ? "(tempfile wasn't created)"
+                                : tfile.toString()));
         ex.printStackTrace();
         return;
       }
@@ -1669,7 +1705,7 @@ public class Jalview
         sfile = tfile.toURI().toURL();
       } catch (Exception x)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Unexpected Malformed URL Exception for temporary file created from STDIN: "
                         + tfile.toURI());
         x.printStackTrace();
@@ -1686,17 +1722,20 @@ public class Jalview
         tfile = new File(groovyscript);
         if (!tfile.exists())
         {
-          System.err.println("File '" + groovyscript + "' does not exist.");
+          jalview.bin.Console.errPrintln(
+                  "File '" + groovyscript + "' does not exist.");
           return;
         }
         if (!tfile.canRead())
         {
-          System.err.println("File '" + groovyscript + "' cannot be read.");
+          jalview.bin.Console.errPrintln(
+                  "File '" + groovyscript + "' cannot be read.");
           return;
         }
         if (tfile.length() < 1)
         {
-          System.err.println("File '" + groovyscript + "' is empty.");
+          jalview.bin.Console
+                  .errPrintln("File '" + groovyscript + "' is empty.");
           return;
         }
         try
@@ -1704,7 +1743,7 @@ public class Jalview
           sfile = tfile.getAbsoluteFile().toURI().toURL();
         } catch (Exception ex)
         {
-          System.err.println("Failed to create a file URL for "
+          jalview.bin.Console.errPrintln("Failed to create a file URL for "
                   + tfile.getAbsoluteFile());
           return;
         }
@@ -1712,12 +1751,11 @@ public class Jalview
     }
     try
     {
+      JalviewObjectI j = new JalviewObject(this);
       Map<String, java.lang.Object> 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);
@@ -1729,10 +1767,10 @@ public class Jalview
       }
     } catch (Exception e)
     {
-      System.err.println("Exception Whilst trying to execute file " + sfile
-              + " as a groovy script.");
+      jalview.bin.Console
+              .errPrintln("Exception Whilst trying to execute file " + sfile
+                      + " as a groovy script.");
       e.printStackTrace(System.err);
-
     }
   }
 
@@ -1746,39 +1784,42 @@ 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!", 0);
+    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;
   }
 
-  protected Commands getCommands()
+  public Commands getCommands()
   {
     return cmds;
   }
 
-  public static void exit(String message, int exitcode)
+  public static void exit(String message, ExitCode ec)
   {
+    int exitcode = ec == ExitCode.OK ? 0 : ec.ordinal() + 1;
     if (Console.log == null)
     {
       // Don't start the logger just to exit!
@@ -1786,11 +1827,11 @@ public class Jalview
       {
         if (exitcode == 0)
         {
-          System.out.println(message);
+          Console.outPrintln(message);
         }
         else
         {
-          System.err.println(message);
+          jalview.bin.Console.errPrintln(message);
         }
       }
     }
@@ -1815,14 +1856,35 @@ public class Jalview
     }
   }
 
+  public enum ExitCode
+  {
+    // 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, NO_LOGGING, GROOVY_ERROR;
+  }
+
   /******************************
    * 
    * TEST OUTPUT METHODS
    * 
+   * these operate only when Arg.TESTOUTPUT has been passed, and variously check
+   * if an expected value / arg was set and report it to the test framework.
+   * 
    ******************************/
   /**
-   * method for reporting string values parsed/processed during tests
+   * report string values parsed/processed during tests When the Bootstrap
+   * argument Arg.TESTOUTPUT is present - reports on debug if given s1 is not
+   * null and not equals s2, warns if given argument is not set, and calls
+   * testoutput(true,a,s1,s2) to report processing progress.
    * 
+   * @param ap
+   *          - ArgParser handling parsing
+   * @param a
+   *          - Arg currently being processed
+   * @param s1
+   *          - expected
+   * @param s2
    */
   protected static void testoutput(ArgParser ap, Arg a, String s1,
           String s2)
@@ -1847,7 +1909,9 @@ public class Jalview
   }
 
   /**
-   * method for reporting string values parsed/processed during tests
+   * report values passed via bootstrap arguments
+   * 
+   * TODO: significant code duplication with testouput(Argparser...) - move it
    */
 
   protected static void testoutput(BootstrapArgs bsa, Arg a, String s1,
@@ -1875,14 +1939,15 @@ public class Jalview
   }
 
   /**
-   * report value set for string values parsed/processed during tests
+   * conditionally (on @param yes) report that expected value s1 was set during
+   * CommandsTest tests
    */
   private static void testoutput(boolean yes, Arg a, String s1, String s2)
   {
     if (yes && ((s1 == null && s2 == null)
             || (s1 != null && s1.equals(s2))))
     {
-      System.out.println("[TESTOUTPUT] arg " + a.argString() + "='" + s1
+      Console.outPrintln("[TESTOUTPUT] arg " + a.argString() + "='" + s1
               + "' was set");
     }
   }
@@ -1940,6 +2005,90 @@ public class Jalview
     {
       message = a.argString() + (yes ? " was set" : " was not set");
     }
-    System.out.println("[TESTOUTPUT] arg " + message);
+    Console.outPrintln("[TESTOUTPUT] arg " + message);
+  }
+
+  public ArgParser getArgParser()
+  {
+    return argparser;
+  }
+
+  public BootstrapArgs getBootstrapArgs()
+  {
+    return bootstrapArgs;
+  }
+
+  public static boolean isBatchMode()
+  {
+    return getInstance() != null && (getInstance().desktop == null
+            || getInstance().desktop.isInBatchMode());
+  }
+
+  /**
+   * Warning about old or mixed command line arguments
+   */
+  private void mixedCliWarning()
+  {
+    Jalview j = Jalview.getInstance();
+    boolean mixedStyle = j.getArgParser() != null
+            && j.getArgParser().isMixedStyle();
+    String title = MessageManager.getString("label.command_line_arguments");
+    if (mixedStyle)
+    {
+      String warning = MessageManager.formatMessage(
+              "warning.using_mixed_command_line_arguments",
+              j.getArgParser().getMixedExamples());
+      String quit = MessageManager.getString("action.quit");
+
+      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.",
+              ExitCode.MIXED_CLI_ARGUMENTS);
+    }
+  }
+
+  private void cliWarning()
+  {
+    Jalview j = Jalview.getInstance();
+    Commands c = j.getCommands();
+    boolean oldStyle = j.getArgParser() != null
+            && j.getArgParser().isOldStyle();
+    String title = MessageManager.getString("label.command_line_arguments");
+    if (oldStyle)
+    {
+      String warning = MessageManager
+              .getString("warning.using_old_command_line_arguments");
+      String url = "<a href=\"https://www.jalview.org/help/html/features/commandline.html\">https://www.jalview.org/help/html/features/commandline.html</a>";
+      if (Desktop.instance != null)
+      {
+        String cont = MessageManager.getString("label.continue");
+
+        Desktop.instance.nonBlockingDialog(title, warning, url, cont,
+                JvOptionPane.WARNING_MESSAGE, false, true, true, 30000);
+      }
+    }
+    if (j.getCommands() != null && j.getCommands().getErrors().size() > 0)
+    {
+      if (Desktop.instance != null)
+      {
+        String message = MessageManager
+                .getString("warning.the_following_errors");
+        String ok = MessageManager.getString("action.ok");
+        int shortest = 60;
+        List<String> errors = j.getCommands().getErrors();
+        for (int i = 0; i < errors.size(); i++)
+        {
+          shortest = Math.min(shortest, errors.get(i).length());
+        }
+        Desktop.instance.nonBlockingDialog(
+                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, -1);
+      }
+    }
   }
+
 }
index 7d66f6d..e8be95f 100644 (file)
@@ -292,7 +292,7 @@ public class JalviewLite extends Applet
     {
       if (debug)
       {
-        System.err.println("Selecting region using separator string '"
+        jalview.bin.Console.errPrintln("Selecting region using separator string '"
                 + separator + "'");
       }
     }
@@ -344,7 +344,7 @@ public class JalviewLite extends Applet
             from--;
           } catch (NumberFormatException ex)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "ERROR: Couldn't parse first integer in range element column selection string '"
                             + cl + "' - format is 'from-to'");
             return;
@@ -355,7 +355,7 @@ public class JalviewLite extends Applet
             to--;
           } catch (NumberFormatException ex)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "ERROR: Couldn't parse second integer in range element column selection string '"
                             + cl + "' - format is 'from-to'");
             return;
@@ -396,13 +396,13 @@ public class JalviewLite extends Applet
             }
             if (debug)
             {
-              System.err.println("Range '" + cl + "' deparsed as [" + from
+              jalview.bin.Console.errPrintln("Range '" + cl + "' deparsed as [" + from
                       + "," + to + "]");
             }
           }
           else
           {
-            System.err.println("ERROR: Invalid Range '" + cl
+            jalview.bin.Console.errPrintln("ERROR: Invalid Range '" + cl
                     + "' deparsed as [" + from + "," + to + "]");
           }
         }
@@ -422,7 +422,7 @@ public class JalviewLite extends Applet
             }
             else
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "ERROR: Couldn't parse integer from point selection element of column selection string '"
                               + cl + "'");
               return;
@@ -451,13 +451,13 @@ public class JalviewLite extends Applet
             csel.addElement(r);
             if (debug)
             {
-              System.err.println("Point selection '" + cl
+              jalview.bin.Console.errPrintln("Point selection '" + cl
                       + "' deparsed as [" + r + "]");
             }
           }
           else
           {
-            System.err.println("ERROR: Invalid Point selection '" + cl
+            jalview.bin.Console.errPrintln("ERROR: Invalid Point selection '" + cl
                     + "' deparsed as [" + r + "]");
           }
         }
@@ -940,7 +940,7 @@ public class JalviewLite extends Applet
       listener = listener.trim();
       if (listener.length() == 0)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "jalview Javascript error: Ignoring empty function for mouseover listener.");
         return;
       }
@@ -952,11 +952,11 @@ public class JalviewLite extends Applet
             .addStructureViewerListener(mol);
     if (debug)
     {
-      System.err.println("Added a mouseover listener for "
+      jalview.bin.Console.errPrintln("Added a mouseover listener for "
               + ((af == null) ? "All frames"
                       : "Just views for "
                               + af.getAlignViewport().getSequenceSetId()));
-      System.err.println("There are now " + javascriptListeners.size()
+      jalview.bin.Console.errPrintln("There are now " + javascriptListeners.size()
               + " listeners in total.");
     }
   }
@@ -987,7 +987,7 @@ public class JalviewLite extends Applet
       listener = listener.trim();
       if (listener.length() == 0)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "jalview Javascript error: Ignoring empty function for selection listener.");
         return;
       }
@@ -999,11 +999,11 @@ public class JalviewLite extends Applet
             .addSelectionListener(mol);
     if (debug)
     {
-      System.err.println("Added a selection listener for "
+      jalview.bin.Console.errPrintln("Added a selection listener for "
               + ((af == null) ? "All frames"
                       : "Just views for "
                               + af.getAlignViewport().getSequenceSetId()));
-      System.err.println("There are now " + javascriptListeners.size()
+      jalview.bin.Console.errPrintln("There are now " + javascriptListeners.size()
               + " listeners in total.");
     }
   }
@@ -1027,7 +1027,7 @@ public class JalviewLite extends Applet
       listener = listener.trim();
       if (listener.length() == 0)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "jalview Javascript error: Ignoring empty function for selection listener.");
         return;
       }
@@ -1039,9 +1039,9 @@ public class JalviewLite extends Applet
             .addStructureViewerListener(mol);
     if (debug)
     {
-      System.err.println("Added a javascript structure viewer listener '"
+      jalview.bin.Console.errPrintln("Added a javascript structure viewer listener '"
               + listener + "'");
-      System.err.println("There are now " + javascriptListeners.size()
+      jalview.bin.Console.errPrintln("There are now " + javascriptListeners.size()
               + " listeners in total.");
     }
   }
@@ -1087,7 +1087,7 @@ public class JalviewLite extends Applet
         rprt = debug;
         if (debug)
         {
-          System.err.println("Removed listener '" + listener + "'");
+          jalview.bin.Console.errPrintln("Removed listener '" + listener + "'");
         }
       }
       else
@@ -1097,7 +1097,7 @@ public class JalviewLite extends Applet
     }
     if (rprt)
     {
-      System.err.println("There are now " + javascriptListeners.size()
+      jalview.bin.Console.errPrintln("There are now " + javascriptListeners.size()
               + " listeners in total.");
     }
   }
@@ -1105,14 +1105,14 @@ public class JalviewLite extends Applet
   @Override
   public void stop()
   {
-    System.err.println("Applet " + getName() + " stop().");
+    jalview.bin.Console.errPrintln("Applet " + getName() + " stop().");
     tidyUp();
   }
 
   @Override
   public void destroy()
   {
-    System.err.println("Applet " + getName() + " destroy().");
+    jalview.bin.Console.errPrintln("Applet " + getName() + " destroy().");
     tidyUp();
   }
 
@@ -1189,7 +1189,7 @@ public class JalviewLite extends Applet
           }
         } catch (NumberFormatException e)
         {
-          System.err.println("Ignoring invalid residue number string '"
+          jalview.bin.Console.errPrintln("Ignoring invalid residue number string '"
                   + pdbResNum + "'");
         }
 
@@ -1220,7 +1220,7 @@ public class JalviewLite extends Applet
 
         } catch (Exception ex)
         {
-          System.err.println("Couldn't parse integer arguments (topRow='"
+          jalview.bin.Console.errPrintln("Couldn't parse integer arguments (topRow='"
                   + topRow + "' and leftHandColumn='" + leftHandColumn
                   + "')");
           ex.printStackTrace();
@@ -1251,7 +1251,7 @@ public class JalviewLite extends Applet
 
         } catch (Exception ex)
         {
-          System.err.println("Couldn't parse integer arguments (topRow='"
+          jalview.bin.Console.errPrintln("Couldn't parse integer arguments (topRow='"
                   + topRow + "')");
           ex.printStackTrace();
         }
@@ -1283,7 +1283,7 @@ public class JalviewLite extends Applet
 
         } catch (Exception ex)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Couldn't parse integer arguments (leftHandColumn='"
                           + leftHandColumn + "')");
           ex.printStackTrace();
@@ -1415,18 +1415,18 @@ public class JalviewLite extends Applet
     {
       if (debug)
       {
-        System.err.println("Applet context is '"
+        jalview.bin.Console.errPrintln("Applet context is '"
                 + getAppletContext().getClass().toString() + "'");
       }
       JSObject scriptObject = JSObject.getWindow(this);
       if (debug && scriptObject != null)
       {
-        System.err.println("Applet has Javascript callback support.");
+        jalview.bin.Console.errPrintln("Applet has Javascript callback support.");
       }
 
     } catch (Exception ex)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Warning: No JalviewLite javascript callbacks available.");
       if (debug)
       {
@@ -1436,9 +1436,9 @@ public class JalviewLite extends Applet
 
     if (debug)
     {
-      System.err.println("JalviewLite Version " + getVersion());
-      System.err.println("Build Date : " + getBuildDate());
-      System.err.println("Installation : " + getInstallation());
+      jalview.bin.Console.errPrintln("JalviewLite Version " + getVersion());
+      jalview.bin.Console.errPrintln("Build Date : " + getBuildDate());
+      jalview.bin.Console.errPrintln("Installation : " + getInstallation());
     }
     String externalsviewer = getParameter("externalstructureviewer");
     if (externalsviewer != null)
@@ -1465,7 +1465,7 @@ public class JalviewLite extends Applet
         separator = sep;
         if (debug)
         {
-          System.err.println("Separator set to '" + separator + "'");
+          jalview.bin.Console.errPrintln("Separator set to '" + separator + "'");
         }
       }
       else
@@ -1573,7 +1573,7 @@ public class JalviewLite extends Applet
     {
       if (tries > 0)
       {
-        System.err.println("LiveConnect request thread going to sleep.");
+        jalview.bin.Console.errPrintln("LiveConnect request thread going to sleep.");
       }
       try
       {
@@ -1584,7 +1584,7 @@ public class JalviewLite extends Applet
       ;
       if (tries++ > 0)
       {
-        System.err.println("LiveConnect request thread woken up.");
+        jalview.bin.Console.errPrintln("LiveConnect request thread woken up.");
       }
       try
       {
@@ -1595,7 +1595,7 @@ public class JalviewLite extends Applet
         }
       } catch (Exception jsex)
       {
-        System.err.println("Attempt " + tries
+        jalview.bin.Console.errPrintln("Attempt " + tries
                 + " to access LiveConnect javascript failed.");
       }
     }
@@ -1632,14 +1632,14 @@ public class JalviewLite extends Applet
                   "Calling oninit callback '" + initjscallback + "'.");
         } catch (Exception e)
         {
-          System.err.println("Exception when executing _oninit callback '"
+          jalview.bin.Console.errPrintln("Exception when executing _oninit callback '"
                   + initjscallback + "'.");
           e.printStackTrace();
         }
       }
       else
       {
-        System.err.println("Not executing _oninit callback '"
+        jalview.bin.Console.errPrintln("Not executing _oninit callback '"
                 + initjscallback + "' - no scripting allowed.");
       }
     }
@@ -1700,7 +1700,7 @@ public class JalviewLite extends Applet
           ((AlignFrame) frame).viewport.applet.currentAlignFrame = (AlignFrame) frame;
           if (debug)
           {
-            System.err.println("Activated window " + frame);
+            jalview.bin.Console.errPrintln("Activated window " + frame);
           }
         }
         // be good.
@@ -1715,7 +1715,7 @@ public class JalviewLite extends Applet
        * 
        * public void windowDeactivated(WindowEvent e) { if (currentAlignFrame ==
        * frame) { currentAlignFrame = null; if (debug) {
-       * System.err.println("Deactivated window "+frame); } }
+       * jalview.bin.Console.errPrintln("Deactivated window "+frame); } }
        * super.windowDeactivated(e); }
        */
     });
@@ -1801,7 +1801,7 @@ public class JalviewLite extends Applet
           }
           if (!jmolAvailable)
           {
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     "Jmol not available - Using mc_view for structures");
           }
         } catch (java.lang.ClassNotFoundException ex)
@@ -1813,7 +1813,7 @@ public class JalviewLite extends Applet
         jmolAvailable = false;
         if (debug)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Skipping Jmol check. Will use mc_view (probably)");
         }
       }
@@ -1844,7 +1844,7 @@ public class JalviewLite extends Applet
     {
       if (JalviewLite.debug)
       {
-        System.err.println(msg);
+        jalview.bin.Console.errPrintln(msg);
       }
     }
 
@@ -1884,7 +1884,7 @@ public class JalviewLite extends Applet
       {
         if (debug)
         {
-          System.err.println("Prepended document base '" + documentBase
+          jalview.bin.Console.errPrintln("Prepended document base '" + documentBase
                   + "' to make: '" + withDocBase + "'");
         }
         protocol = DataSourceType.URL;
@@ -1903,7 +1903,7 @@ public class JalviewLite extends Applet
         protocol = DataSourceType.URL;
         if (debug)
         {
-          System.err.println("Prepended codebase '" + codeBase
+          jalview.bin.Console.errPrintln("Prepended codebase '" + codeBase
                   + "' to make: '" + withCodeBase + "'");
         }
         return withCodeBase;
@@ -2010,7 +2010,7 @@ public class JalviewLite extends Applet
                   + " as "
                   + (al1.isNucleotide() ? "protein product" : "cDNA")
                   + " for " + af.getTitle();
-          System.err.println(msg);
+          jalview.bin.Console.errPrintln(msg);
         }
       }
 
@@ -2084,7 +2084,7 @@ public class JalviewLite extends Applet
             dbgMsg(">>>Dump finished.");
           } catch (Exception e)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Exception when trying to dump the content of the file parameter.");
             e.printStackTrace();
           }
@@ -2214,7 +2214,7 @@ public class JalviewLite extends Applet
                 {
                   // this may not really be a problem but we give a warning
                   // anyway
-                  System.err.println(
+                  jalview.bin.Console.errPrintln(
                           "Warning: Possible input parsing error: Null sequence for attachment of PDB (sequence "
                                   + i + ")");
                 }
@@ -2320,7 +2320,7 @@ public class JalviewLite extends Applet
         }
         else
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Annotations were not added from annotation file '"
                           + param + "'");
         }
@@ -2392,13 +2392,13 @@ public class JalviewLite extends Applet
         {
           if (debug)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Attempting to load T-COFFEE score file from the scoreFile parameter");
           }
           result = alignFrame.loadScoreFile(sScoreFile);
           if (!result)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Failed to parse T-COFFEE parameter as a valid score file ('"
                             + sScoreFile + "')");
           }
@@ -2469,13 +2469,13 @@ public class JalviewLite extends Applet
         boolean rtn = (getClass().getResourceAsStream("/" + f) != null);
         if (debug)
         {
-          System.err.println("Resource '" + f + "' was "
+          jalview.bin.Console.errPrintln("Resource '" + f + "' was "
                   + (rtn ? "" : "not ") + "located by classloader.");
         }
         return rtn;
       } catch (Exception ex)
       {
-        System.out.println("Exception checking resources: " + f + " " + ex);
+        jalview.bin.Console.outPrintln("Exception checking resources: " + f + " " + ex);
         return false;
       }
     }
@@ -2496,7 +2496,7 @@ public class JalviewLite extends Applet
     {
       return initialAlignFrame;
     }
-    System.err.println(
+    jalview.bin.Console.errPrintln(
             "Implementation error: Jalview Applet API cannot work out which AlignFrame to use.");
     return null;
   }
@@ -2564,18 +2564,18 @@ public class JalviewLite extends Applet
       jv.removeAllElements();
       if (debug)
       {
-        System.err.println("Array from '" + separator
+        jalview.bin.Console.errPrintln("Array from '" + separator
                 + "' separated List:\n" + v.length);
         for (int i = 0; i < v.length; i++)
         {
-          System.err.println("item " + i + " '" + v[i] + "'");
+          jalview.bin.Console.errPrintln("item " + i + " '" + v[i] + "'");
         }
       }
       return v;
     }
     if (debug)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Empty Array from '" + separator + "' separated List");
     }
     return null;
@@ -2620,13 +2620,13 @@ public class JalviewLite extends Applet
       {
         System.err
                 .println("Returning '" + separator + "' separated List:\n");
-        System.err.println(v);
+        jalview.bin.Console.errPrintln(v);
       }
       return v.toString();
     }
     if (debug)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Returning empty '" + separator + "' separated List\n");
     }
     return "" + separator;
@@ -2745,7 +2745,7 @@ public class JalviewLite extends Applet
     this.separator = separator;
     if (debug)
     {
-      System.err.println("Default Separator now: '" + separator + "'");
+      jalview.bin.Console.errPrintln("Default Separator now: '" + separator + "'");
     }
   }
 
@@ -2901,7 +2901,7 @@ public class JalviewLite extends Applet
     Color col = ColorUtils.parseColourString(colprop);
     if (col == null)
     {
-      System.err.println("Couldn't parse '" + colprop + "' as a colour for "
+      jalview.bin.Console.errPrintln("Couldn't parse '" + colprop + "' as a colour for "
               + colparam);
     }
     return (col == null) ? defcolour : col;
@@ -2971,7 +2971,7 @@ public class JalviewLite extends Applet
     }
     if (debug)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "resolveUrlForLocalOrAbsolute returning " + resolvedPath);
     }
     return resolvedPath;
@@ -3000,7 +3000,7 @@ public class JalviewLite extends Applet
                         : getDocumentBase());
         if (debug)
         {
-          System.err.println("Show url (prepended " + prepend
+          jalview.bin.Console.errPrintln("Show url (prepended " + prepend
                   + " - toggle resolvetocodebase if code/docbase resolution is wrong): "
                   + url);
         }
@@ -3009,7 +3009,7 @@ public class JalviewLite extends Applet
       {
         if (debug)
         {
-          System.err.println("Show url: " + url);
+          jalview.bin.Console.errPrintln("Show url: " + url);
         }
       }
       if (url.indexOf("javascript:") == 0)
index f2ffda5..d38892a 100644 (file)
@@ -64,7 +64,7 @@ public class JalviewLiteURLRetrieve extends Applet
     DataSourceType protocol = null;
     try
     {
-      System.out.println("Loading thread started with:\n>>file\n" + file
+      jalview.bin.Console.outPrintln("Loading thread started with:\n>>file\n" + file
               + ">>endfile");
       // This might throw a security exception in certain browsers
       // Netscape Communicator for instance.
@@ -77,7 +77,7 @@ public class JalviewLiteURLRetrieve extends Applet
           rtn = true;
           is.close();
         }
-        System.err.println("Resource '" + file + "' was "
+        jalview.bin.Console.errPrintln("Resource '" + file + "' was "
                 + (rtn ? "" : "not") + " located by classloader.");
         if (rtn)
         {
@@ -86,7 +86,7 @@ public class JalviewLiteURLRetrieve extends Applet
 
       } catch (Exception ex)
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "Exception checking resources: " + file + " " + ex);
       }
       if (file.indexOf("://") > -1)
@@ -99,7 +99,7 @@ public class JalviewLiteURLRetrieve extends Applet
         protocol = DataSourceType.FILE;
       }
 
-      System.out.println("Trying to get contents of resource:");
+      jalview.bin.Console.outPrintln("Trying to get contents of resource:");
       FileParse fp = new FileParse(file, protocol);
       if (fp.isValid())
       {
@@ -112,7 +112,7 @@ public class JalviewLiteURLRetrieve extends Applet
       }
       else
       {
-        System.out.println("Resource at " + file
+        jalview.bin.Console.outPrintln("Resource at " + file
                 + " cannot be read with protocol==" + protocol);
         return;
       }
@@ -121,11 +121,11 @@ public class JalviewLiteURLRetrieve extends Applet
       if (format == null)
       {
         format = new IdentifyFile().identify(file, protocol);
-        System.out.println("Format is " + format);
+        jalview.bin.Console.outPrintln("Format is " + format);
       }
       else
       {
-        System.out.println("User specified Format is " + format);
+        jalview.bin.Console.outPrintln("User specified Format is " + format);
       }
       AlignmentI al = null;
       try
@@ -133,17 +133,17 @@ public class JalviewLiteURLRetrieve extends Applet
         al = new AppletFormatAdapter().readFile(file, protocol, format);
       } catch (java.io.IOException ex)
       {
-        System.err.println("Failed to open the file.");
+        jalview.bin.Console.errPrintln("Failed to open the file.");
         ex.printStackTrace();
       }
       if (al != null)
       {
-        System.out.println(new AppletFormatAdapter()
+        jalview.bin.Console.outPrintln(new AppletFormatAdapter()
                 .formatSequences(FileFormat.Fasta, al, false));
       }
     } catch (Exception e)
     {
-      System.err.println("bailing out : Unexpected exception:");
+      jalview.bin.Console.errPrintln("bailing out : Unexpected exception:");
       e.printStackTrace();
     }
   }
index c7ababa..e04c04f 100644 (file)
@@ -46,7 +46,7 @@ public class JalviewTaskbar
         }
         else
         {
-          System.out.println("Unable to setIconImage()");
+          Console.outPrintln("Unable to setIconImage()");
         }
       }
     }
index a87d322..e1415be 100644 (file)
@@ -50,28 +50,7 @@ public class Launcher
 {
   private final static String startClass = "jalview.bin.Jalview";
 
-  private static boolean checkJVMSymlink(String testBin)
-  {
-    File testBinFile = new File(testBin);
-    if (!testBinFile.exists())
-    {
-      return false;
-    }
-    File targetFile = null;
-    try
-    {
-      targetFile = testBinFile.getCanonicalFile();
-    } catch (IOException e)
-    {
-      return false;
-    }
-    if (targetFile != null && ("java".equals(targetFile.getName())
-            || "java.exe".equals(targetFile.getName())))
-    {
-      return true;
-    }
-    return false;
-  }
+  private final static String headlessProperty = "java.awt.headless";
 
   /**
    * main method for jalview.bin.Launcher. This restarts the same JRE's JVM with
@@ -85,53 +64,27 @@ public class Launcher
   {
     if (!LaunchUtils.checkJavaVersion())
     {
-      System.err.println("WARNING - The Java version being used (Java "
-              + LaunchUtils.getJavaVersion()
-              + ") may lead to problems. This installation of Jalview should be used with Java "
-              + LaunchUtils.getJavaCompileVersion() + ".");
-    }
-    final String appName = ChannelProperties.getProperty("app_name");
-    final String javaBinDir = System.getProperty("java.home")
-            + File.separator + "bin" + File.separator;
-    String javaBin = null;
-    if (javaBin == null && checkJVMSymlink(javaBinDir + appName))
-    {
-      javaBin = javaBinDir + appName;
-    }
-    if (javaBin == null && checkJVMSymlink(javaBinDir + "Jalview"))
-    {
-      javaBin = javaBinDir + "Jalview";
-    }
-    if (javaBin == null)
-    {
-      javaBin = "java";
-    }
-
-    List<String> command = new ArrayList<>();
-    command.add(javaBin);
-
-    String memSetting = null;
-
-    boolean isAMac = System.getProperty("os.name").indexOf("Mac") > -1;
-
-    for (String jvmArg : ManagementFactory.getRuntimeMXBean()
-            .getInputArguments())
-    {
-      command.add(jvmArg);
+      jalview.bin.Console
+              .errPrintln("WARNING - The Java version being used (Java "
+                      + LaunchUtils.getJavaVersion()
+                      + ") may lead to problems. This installation of Jalview should be used with Java "
+                      + LaunchUtils.getJavaCompileVersion() + ".");
     }
-    command.add("-cp");
-    command.add(ManagementFactory.getRuntimeMXBean().getClassPath());
 
     String jvmmempc = null;
     String jvmmemmax = null;
     boolean debug = false;
     boolean wait = true;
     boolean quiet = false;
+    boolean headless = false;
+    boolean gui = false;
+    boolean stdout = false;
     // must set --debug before --launcher...
     boolean launcherstop = false;
     boolean launcherprint = false;
     boolean launcherwait = false;
     ArrayList<String> arguments = new ArrayList<>();
+    String previousArg = null;
     for (String arg : args)
     {
       if (arg.equals("--debug"))
@@ -142,6 +95,19 @@ public class Launcher
       {
         quiet = true;
       }
+      if (arg.equals("--headless"))
+      {
+        headless = true;
+      }
+      if (arg.equals("--gui"))
+      {
+        gui = true;
+      }
+      if (arg.equals("--output=-")
+              || (arg.equals("-") && "--output".equals(previousArg)))
+      {
+        stdout = true;
+      }
       if (debug && arg.equals("--launcherprint"))
       {
         launcherprint = true;
@@ -159,6 +125,7 @@ public class Launcher
       {
         wait = false;
       }
+      previousArg = arg;
       // Don't add the --launcher... args to Jalview launch
       if (arg.startsWith("--launcher"))
       {
@@ -199,6 +166,29 @@ public class Launcher
         arguments.add(arg);
       }
     }
+    if (gui)
+    {
+      // --gui takes precedence over --headless
+      headless = false;
+    }
+
+    final String appName = ChannelProperties.getProperty("app_name");
+
+    // if we're using jalview.bin.Launcher we always assume a console is in use
+    final String javaBin = LaunchUtils.findJavaBin(true);
+
+    List<String> command = new ArrayList<>();
+    command.add(javaBin);
+
+    String memSetting = null;
+
+    for (String jvmArg : ManagementFactory.getRuntimeMXBean()
+            .getInputArguments())
+    {
+      command.add(jvmArg);
+    }
+    command.add("-cp");
+    command.add(ManagementFactory.getRuntimeMXBean().getClassPath());
 
     // use saved preferences if no cmdline args
     boolean useCustomisedSettings = LaunchUtils
@@ -221,6 +211,7 @@ public class Launcher
     boolean memSet = false;
     boolean dockIcon = false;
     boolean dockName = false;
+    boolean headlessProp = false;
     for (int i = 0; i < command.size(); i++)
     {
       String arg = command.get(i);
@@ -241,6 +232,10 @@ public class Launcher
       {
         dockName = true;
       }
+      else if (arg.startsWith("-D" + headlessProperty + "="))
+      {
+        headlessProp = true;
+      }
     }
 
     if (!memSet)
@@ -255,7 +250,7 @@ public class Launcher
       }
     }
 
-    if (isAMac)
+    if (LaunchUtils.isMac)
     {
       if (!dockIcon)
       {
@@ -276,11 +271,16 @@ public class Launcher
                 + appName);
       }
     }
+    if (headless && !headlessProp)
+    {
+      System.setProperty(headlessProperty, "true");
+      command.add("-D" + headlessProperty + "=true");
+    }
 
     String scalePropertyArg = HiDPISetting.getScalePropertyArg();
     if (scalePropertyArg != null)
     {
-      sysout(debug, quiet, "Running " + startClass + " with scale setting "
+      syserr(debug, quiet, "Running " + startClass + " with scale setting "
               + scalePropertyArg);
       command.add(scalePropertyArg);
     }
@@ -293,10 +293,10 @@ public class Launcher
     if ((Boolean.parseBoolean(System.getProperty("launcherprint", "false"))
             || launcherprint))
     {
-      sysout(debug, quiet,
+      syserr(debug, quiet,
               "LAUNCHER COMMAND: " + String.join(" ", builder.command()));
     }
-    sysout(debug, quiet,
+    syserr(debug, quiet,
             "Running " + startClass + " with "
                     + (memSetting == null ? "no memory setting"
                             : ("memory setting " + memSetting)));
@@ -304,7 +304,7 @@ public class Launcher
     if (Boolean.parseBoolean(System.getProperty("launcherstop", "false"))
             || (debug && launcherstop))
     {
-      sysout(debug, quiet,
+      syserr(debug, quiet,
               "System property 'launcherstop' is set and not 'false'. Exiting.");
       System.exit(0);
     }
@@ -314,22 +314,23 @@ public class Launcher
       Process process = builder.start();
       if (wait || launcherwait)
       {
-        sysout(debug, quiet, "Launching application process");
+        syserr(debug, quiet, "Launching application process");
         process.waitFor();
       }
       else
       {
         int waitInt = 0;
-        sysout(debug, quiet,
+        syserr(debug, quiet,
                 "Wait time for application process is " + waitInt + "ms");
         process.waitFor(waitInt, TimeUnit.MILLISECONDS);
       }
-      sysout(debug, quiet, "Launcher process ending");
+      syserr(debug, quiet, "Launcher process ending");
     } catch (IOException e)
     {
       if (e.getMessage().toLowerCase(Locale.ROOT).contains("memory"))
       {
-        System.err.println("Caught a memory exception: " + e.getMessage());
+        jalview.bin.Console
+                .errPrintln("Caught a memory exception: " + e.getMessage());
         // Probably the "Cannot allocate memory" error, try without the memory
         // setting
         ArrayList<String> commandNoMem = new ArrayList<>();
@@ -342,7 +343,7 @@ public class Launcher
         }
         final ProcessBuilder builderNoMem = new ProcessBuilder(
                 commandNoMem);
-        System.err.println("Command without memory setting: "
+        jalview.bin.Console.errPrintln("Command without memory setting: "
                 + String.join(" ", builderNoMem.command()));
         try
         {
@@ -364,11 +365,11 @@ public class Launcher
     }
   }
 
-  private static void sysout(boolean debug, boolean quiet, String message)
+  private static void syserr(boolean debug, boolean quiet, String message)
   {
     if (debug && !quiet)
     {
-      System.out.println("LAUNCHERDEBUG - " + message);
+      jalview.bin.Console.errPrintln("LAUNCHERDEBUG - " + message);
     }
   }
 
index bb545cb..7458d55 100644 (file)
@@ -354,7 +354,7 @@ public class MemorySetting
     else
     {
       // number too big for a Long. Limit to Long.MAX_VALUE
-      System.out.println("Memory parsing of '" + memString
+      jalview.bin.Console.outPrintln("Memory parsing of '" + memString
               + "' produces number too big.  Limiting to Long.MAX_VALUE="
               + Long.MAX_VALUE);
       return Long.MAX_VALUE;
@@ -395,7 +395,7 @@ public class MemorySetting
     ADJUSTMENT_MESSAGE = reason;
     if (!quiet)
     {
-      System.out.println(reason);
+      jalview.bin.Console.outPrintln(reason);
     }
   }
 
index 2f25978..93156ac 100644 (file)
@@ -19,7 +19,7 @@ public enum Arg
 
   // Initialising arguments (BOOTSTRAP)
   HELP(Type.HELP, "h", "Display basic help", Opt.UNARY, Opt.BOOTSTRAP,
-          Opt.HASTYPE, Opt.MULTI),
+          Opt.HASTYPE, Opt.MULTIVALUE),
   /*
    * Other --help-type Args will be added by the static block.
    */
@@ -29,8 +29,8 @@ public enum Arg
           Opt.UNARY, Opt.BOOTSTRAP),
   HEADLESS(Type.CONFIG,
           "Run Jalview in headless mode. No GUI interface will be created and Jalview will quit after all arguments have been processed. "
-                  + "Headless mode is assumed if an output file is to be generated, this can be overridden with --noheadless or --gui.",
-          Opt.BOOLEAN, Opt.BOOTSTRAP),
+                  + "Headless mode is assumed if an output file is to be generated, this can be overridden with --gui.",
+          Opt.UNARY, Opt.BOOTSTRAP),
   GUI(Type.CONFIG,
           "Do not run Jalview in headless mode.  This overrides the assumption of headless mode when an output file is to be generated.",
           Opt.UNARY, Opt.BOOTSTRAP),
@@ -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.",
@@ -62,27 +64,28 @@ public enum Arg
           Opt.BOOTSTRAP, Opt.SECRET),
   QUIET(Type.CONFIG, "q",
           "Stop all output to STDOUT (after the Java Virtual Machine has started). Use â€‘‑quiet a second time to stop all output to STDERR.",
-          Opt.UNARY, Opt.MULTI, Opt.BOOTSTRAP),
+          Opt.UNARY, Opt.MULTIVALUE, Opt.BOOTSTRAP),
   INITSUBSTITUTIONS(Type.CONFIG,
           "Set â€‘‑substitutions to be initially enabled (or initially disabled).",
           true, Opt.BOOLEAN, Opt.BOOTSTRAP, Opt.NOACTION, Opt.SECRET),
   P(Type.CONFIG, "Set a Jalview preference value for this session.",
           Opt.PREFIXKEV, Opt.PRESERVECASE, Opt.STRING, Opt.BOOTSTRAP,
-          Opt.MULTI, Opt.NOACTION, Opt.SECRET), // keep this secret for now.
+          Opt.MULTIVALUE, Opt.NOACTION, Opt.SECRET), // keep this secret for
+                                                     // now.
 
   // Opening an alignment
   OPEN(Type.OPENING,
           "Opens one or more alignment files or URLs in new alignment windows.",
-          Opt.STRING, Opt.LINKED, Opt.INCREMENTDEFAULTCOUNTER, Opt.MULTI,
-          Opt.GLOB, Opt.ALLOWSUBSTITUTIONS, Opt.INPUT, Opt.STORED,
-          Opt.PRIMARY),
+          Opt.STRING, Opt.LINKED, Opt.INCREMENTDEFAULTCOUNTER,
+          Opt.MULTIVALUE, Opt.GLOB, Opt.ALLOWSUBSTITUTIONS, Opt.INPUT,
+          Opt.STORED, Opt.PRIMARY),
   APPEND(Type.OPENING,
           "Appends one or more alignment files or URLs to the open alignment window (or opens a new alignment if none already open).",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.GLOB,
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.GLOB,
           Opt.ALLOWSUBSTITUTIONS, Opt.INPUT, Opt.PRIMARY),
   TITLE(Type.OPENING,
           "Specifies the title for the open alignment window as string.",
-          Opt.STRING, Opt.LINKED),
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
   COLOUR(Type.OPENING, "color", // being a bit soft on the Americans!
           "Applies the colour scheme to the open alignment window. Valid values include:\n"
                   + "clustal,\n" + "blosum62,\n" + "pc-identity,\n"
@@ -93,103 +96,122 @@ public enum Arg
                   + "turn-propensity,\n" + "buried-index,\n"
                   + "nucleotide,\n" + "nucleotide-ambiguity,\n"
                   + "purine-pyrimidine,\n" + "rna-helices,\n"
-                  + "t-coffee-scores,\n" + "sequence-id.\n"
-                  +"\n"
+                  + "t-coffee-scores,\n" + "sequence-id.\n" + "\n"
                   + "Names of user defined colourschemes will also work,\n"
-                 +"and jalview colourscheme specifications like\n"
-                  +"--colour=\"D,E=red; K,R,H=0022FF; C,c=yellow\"",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+                  + "and jalview colourscheme specifications like\n"
+                  + "--colour=\"D,E=red; K,R,H=0022FF; C,c=yellow\"",
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
   FEATURES(Type.OPENING, "Add a feature file or URL to the open alignment.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.ALLOWMULTIID),
   TREE(Type.OPENING, "Add a tree file or URL to the open alignment.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.ALLOWMULTIID),
   SORTBYTREE(Type.OPENING,
           "Enforces sorting (or not sorting) the open alignment in the order of an attached phylogenetic tree.",
-          true, Opt.LINKED, Opt.BOOLEAN, Opt.ALLOWALL),
+          true, Opt.LINKED, Opt.BOOLEAN, Opt.ALLOWMULTIID),
   ANNOTATIONS(Type.OPENING,
           "Add an annotations file or URL to the open alignment.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.ALLOWMULTIID),
   SHOWANNOTATIONS(Type.OPENING,
           "Enforces showing (or not showing) alignment annotations.",
-          Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWALL),
+          Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWMULTIID, Opt.ALLOWMULTIID),
   WRAP(Type.OPENING,
           "Enforces wrapped (or not wrapped) alignment formatting.",
-          Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWALL),
+          Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWMULTIID, Opt.ALLOWMULTIID),
   NOSTRUCTURE(Type.OPENING,
           "Do not open or process any 3D structure in the â€‘‑open or â€‘‑append files.",
-          Opt.UNARY, Opt.LINKED, Opt.ALLOWALL),
+          Opt.UNARY, Opt.LINKED, Opt.ALLOWMULTIID, Opt.ALLOWMULTIID),
 
   // Adding a 3D structure
   STRUCTURE(Type.STRUCTURE,
           "Load a structure file or URL associated with a sequence in the open alignment.\n"
                   + "The sequence to be associated with can be specified with a following --seqid argument, or the subval modifier seqid=ID can be used. A subval INDEX can also be used to specify the INDEX-th sequence in the open alignment.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS,
-          Opt.PRIMARY),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.PRIMARY, Opt.ALLOWMULTIID),
   SEQID(Type.STRUCTURE,
           "Specify the sequence name for the preceding --structure to be associated with.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.ALLOWMULTIID),
   PAEMATRIX(Type.STRUCTURE,
           "Add a PAE json matrix file to the preceding --structure.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.ALLOWMULTIID),
   TEMPFAC(Type.STRUCTURE,
           "Set the type of temperature factor. Possible values are:\n"
                   + "default,\n" + "plddt.",
-          Opt.STRING, Opt.LINKED),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
   STRUCTUREVIEWER(Type.STRUCTURE,
           "Set the structure viewer to use to open the 3D structure file specified in previous --structure to name. Possible values of name are:\n"
                   + "none,\n" + "jmol,\n" + "chimera,\n" + "chimerax,\n"
                   + "pymol.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
   NOTEMPFAC(Type.STRUCTURE,
           "Do not show the temperature factor annotation for the preceding --structure.",
-          Opt.UNARY, Opt.LINKED, Opt.ALLOWALL, Opt.SECRET), // keep this secret
-                                                            // until it works!
+          Opt.UNARY, Opt.LINKED, Opt.ALLOWMULTIID, Opt.SECRET), // keep this
+                                                                // secret until
+                                                                // it works!
   SHOWSSANNOTATIONS(Type.STRUCTURE, null, Opt.BOOLEAN, Opt.LINKED,
-          Opt.ALLOWALL),
+          Opt.ALLOWMULTIID),
 
   // Outputting files
   IMAGE(Type.IMAGE,
           "Output an image of the open alignment window. Format is specified by the subval modifier, a following --type argument or guessed from the file extension. Valid formats/extensions are:\n"
                   + "svg,\n" + "png,\n" + "eps,\n" + "html,\n" + "biojs.",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWSUBSTITUTIONS, Opt.ALLOWALL,
-          Opt.REQUIREINPUT, Opt.OUTPUTFILE, Opt.PRIMARY),
+          Opt.STRING, Opt.LINKED, Opt.ALLOWSUBSTITUTIONS, Opt.MULTIVALUE,
+          Opt.ALLOWMULTIID, Opt.REQUIREINPUT, Opt.OUTPUTFILE, Opt.PRIMARY),
+  STRUCTUREIMAGE(Type.IMAGE,
+          "Export an image of a 3D structure opened in JMOL", Opt.STRING,
+          Opt.LINKED, Opt.MULTIVALUE, Opt.OUTPUTFILE, Opt.ALLOWMULTIID,
+          Opt.PRIMARY),
   TYPE(Type.IMAGE,
-          "Set the image format for the preceding --image. Valid values are:\n"
-                  + "svg,\n" + "png,\n" + "eps,\n" + "html,\n" + "biojs.",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+          "Set the image format for the preceding " + Arg.IMAGE.argString()
+                  + " or " + Arg.STRUCTUREIMAGE.argString()
+                  + ". Valid values are:\n" + "svg,\n" + "png,\n" + "eps,\n"
+                  + "html,\n" + "biojs.",
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
   TEXTRENDERER(Type.IMAGE,
           "Sets whether text in a vector image format (SVG, HTML, EPS) should be rendered as text or vector line-art. Possible values are:\n"
                   + "text,\n" + "lineart.",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
   SCALE(Type.IMAGE,
           "Sets a scaling for bitmap image format (PNG). Should be given as a floating point number. If used in conjunction with --width and --height then the smallest scaling will be used (scale, width and height provide bounds for the image).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
   WIDTH(Type.IMAGE,
           "Sets a width for bitmap image format (PNG) with the height maintaining the aspect ratio. Should be given as a positive integer. If used in conjunction with --scale and --height then the smallest scaling will be used (scale, width and height provide bounds for the image).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
   HEIGHT(Type.IMAGE,
           "Sets a height for bitmap image format (PNG) with the width maintaining the aspect ratio. Should be given as a positive integer. If used in conjunction with --scale and --width then the smallest scaling will be used (scale, width and height provide bounds for the image).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
-  STRUCTUREIMAGE(Type.STRUCTUREIMAGE,
-          "Export an image of a 3D structure opened in JMOL", Opt.STRING,
-          Opt.LINKED, Opt.MULTI, Opt.OUTPUTFILE),
-  STRUCTUREIMAGETYPE(Type.STRUCTUREIMAGE,
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
+  IMAGECOLOUR(Type.IMAGE, "imagecolor", // being a bit soft on the Americans!
+          "Applies the colour scheme to the open alignment window for this image, otherwise the value of "
+                  + Arg.COLOUR.argString()
+                  + " (or none) will apply. Valid values are the same as "
+                  + Arg.COLOUR.argString() + ".",
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
+  BGCOLOUR(Type.IMAGE, "bgcolor", // being a bit soft on the Americans!
+          "Applies a background colour to the structure image. Valid values are named colours known to Java or RRGGBB 6 digit hex-string.",
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWMULTIID),
+  /*
+  STRUCTUREIMAGETYPE(Type.IMAGE,
           "Set the structure image format for the preceding --structureimage. Valid values are:\n"
                   + "svg,\n" + "png,\n" + "eps,\n" + "html,\n" + "biojs.",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
-  STRUCTUREIMAGETEXTRENDERER(Type.STRUCTUREIMAGE,
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
+  STRUCTUREIMAGETEXTRENDERER(Type.IMAGE,
           "Sets whether text in a vector structure image format (SVG, EPS) should be rendered as text or vector line-art. Possible values are:\n"
                   + "text,\n" + "lineart.",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
-  STRUCTUREIMAGESCALE(Type.STRUCTUREIMAGE,
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
+  STRUCTUREIMAGESCALE(Type.IMAGE,
           "Sets a scaling for bitmap structure image format (PNG). Should be given as a floating point number. If used in conjunction with --structureimagewidth and --structureimageheight then the smallest scaling will be used (structureimagescale, structureimagewidth and structureimageheight provide bounds for the structure image).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
-  STRUCTUREIMAGEWIDTH(Type.STRUCTUREIMAGE,
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
+  STRUCTUREIMAGEWIDTH(Type.IMAGE,
           "Sets a width for bitmap structure image format (PNG) with the height maintaining the aspect ratio. Should be given as a positive integer. If used in conjunction with --structureimagescale and --structureimageheight then the smallest scaling will be used (structureimagescale, structureimagewidth and structureimageheight provide bounds for the structure image).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
-  STRUCTUREIMAGEHEIGHT(Type.STRUCTUREIMAGE,
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
+  STRUCTUREIMAGEHEIGHT(Type.IMAGE,
           "Sets a height for bitmap structure image format (PNG) with the width maintaining the aspect ratio. Should be given as a positive integer. If used in conjunction with --structureimagescale and --structureimagewidth then the smallest scaling will be used (structureimagescale, structureimagewidth and structureimageheight provide bounds for the structure image).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
+  */
 
   OUTPUT(Type.OUTPUT,
           "Export the open alignment to file filename. The format name is specified by the subval modifier format=name, a following --format name argument or guessed from the file extension. Valid format names (and file extensions) are:\n"
@@ -199,32 +221,36 @@ public enum Arg
                   + "pileup (pileup),\n" + "msf (msf),\n"
                   + "clustal (aln),\n" + "phylip (phy),\n"
                   + "jalview (jvp, jar).",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWSUBSTITUTIONS, Opt.ALLOWALL,
-          Opt.REQUIREINPUT, Opt.OUTPUTFILE, Opt.PRIMARY),
+          Opt.STRING, Opt.LINKED, Opt.ALLOWSUBSTITUTIONS, Opt.ALLOWMULTIID,
+          Opt.REQUIREINPUT, Opt.OUTPUTFILE, Opt.STDOUT, Opt.PRIMARY),
   FORMAT(Type.OUTPUT,
           "Sets the format for the preceding --output file. Valid formats are:\n"
                   + "fasta,\n" + "pfam,\n" + "stockholm,\n" + "pir,\n"
                   + "blc,\n" + "amsa,\n" + "json,\n" + "pileup,\n"
                   + "msf,\n" + "clustal,\n" + "phylip,\n" + "jalview.",
-          Opt.STRING, Opt.LINKED, Opt.ALLOWALL),
+          Opt.STRING, Opt.LINKED, Opt.ALLOWMULTIID),
   GROOVY(Type.PROCESS,
           "Process a groovy script in the file for the open alignment.",
-          Opt.STRING, Opt.LINKED, Opt.MULTI, Opt.ALLOWSUBSTITUTIONS,
-          Opt.ALLOWALL),
+          Opt.STRING, Opt.LINKED, Opt.MULTIVALUE, Opt.ALLOWSUBSTITUTIONS,
+          Opt.ALLOWMULTIID),
   BACKUPS(Type.OUTPUT,
           "Enable (or disable) writing backup files when saving an â€‘‑output file. This applies to the current open alignment.  To apply to all â€‘‑output and â€‘‑image files, use after â€‘‑all.",
-          true, Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWALL),
+          true, Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWMULTIID),
   OVERWRITE(Type.OUTPUT,
           "Enable (or disable) overwriting of output files without backups enabled. This applies to the current open alignment.  To apply to all â€‘‑output and â€‘‑image files, use after â€‘‑all.",
-          Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWALL),
+          Opt.BOOLEAN, Opt.LINKED, Opt.ALLOWMULTIID),
   CLOSE(Type.OPENING,
           "Close the current open alignment window. This occurs after other output arguments. This applies to the current open alignment.  To apply to all â€‘‑output and â€‘‑image files, use after â€‘‑all.",
-          Opt.UNARY, Opt.LINKED, Opt.ALLOWALL),
+          Opt.UNARY, Opt.LINKED, Opt.ALLOWMULTIID),
+  MKDIRS(Type.OUTPUT,
+          "Automatically create directories when outputting a file to a new directory.",
+          Opt.UNARY, Opt.LINKED, Opt.ALLOWMULTIID),
 
   // controlling flow of arguments
   NEW(Type.FLOW,
           "Move on to a new alignment window. This will ensure --append will start a new alignment window and other linked arguments will apply to the new alignment window.",
-          Opt.UNARY, Opt.MULTI, Opt.NOACTION, Opt.INCREMENTDEFAULTCOUNTER),
+          Opt.UNARY, Opt.MULTIVALUE, Opt.NOACTION,
+          Opt.INCREMENTDEFAULTCOUNTER),
   SUBSTITUTIONS(Type.FLOW,
           "The following argument values allow (or don't allow) subsituting filename parts. This is initially true. Valid substitutions are:\n"
                   + "{basename} - the filename-without-extension of the currently --opened file (or first --appended file),\n"
@@ -234,22 +260,22 @@ public enum Arg
                   + "{n} - the value of the index counter (starting at 0).\n"
                   + "{++n} - increase and substitute the value of the index counter,\n"
                   + "{} - the value of the current alignment window default index.",
-          true, Opt.BOOLEAN, Opt.MULTI, Opt.NOACTION),
+          true, Opt.BOOLEAN, Opt.MULTIVALUE, Opt.NOACTION),
   ARGFILE(Type.FLOW,
           "Open one or more files filename and read, line-by-line, as arguments to Jalview.\n"
                   + "Values in an argfile should be given with an equals sign (\"=\") separator with no spaces.\n"
                   + "Note that if you use one or more --argfile arguments then all other non-initialising arguments will be ignored.",
-          Opt.STRING, Opt.MULTI, Opt.BOOTSTRAP, Opt.GLOB,
+          Opt.STRING, Opt.MULTIVALUE, Opt.BOOTSTRAP, Opt.GLOB,
           Opt.ALLOWSUBSTITUTIONS),
   NPP(Type.FLOW, "n++",
           "Increase the index counter used in argument value substitutions.",
-          Opt.UNARY, Opt.MULTI, Opt.NOACTION),
+          Opt.UNARY, Opt.MULTIVALUE, Opt.NOACTION),
   ALL(Type.FLOW,
           "Apply the following output arguments to all sets of linked arguments.",
-          Opt.BOOLEAN, Opt.MULTI, Opt.NOACTION),
+          Opt.BOOLEAN, Opt.MULTIVALUE, Opt.NOACTION),
   OPENED(Type.FLOW,
           "Apply the following output arguments to all of the last --open'ed set of linked arguments.",
-          Opt.BOOLEAN, Opt.MULTI, Opt.NOACTION),
+          Opt.BOOLEAN, Opt.MULTIVALUE, Opt.NOACTION),
   QUIT(Type.FLOW,
           "After all files have been opened, appended and output, quit Jalview. In â€‘‑headless mode this already happens.",
           Opt.UNARY),
@@ -258,26 +284,27 @@ public enum Arg
           Opt.UNARY, Opt.SECRET),
   ALLSTRUCTURES(Type.FLOW,
           "Apply the following 3D structure formatting arguments to all structures within the open alignment.",
-          Opt.BOOLEAN, Opt.MULTI, Opt.NOACTION),
+          Opt.BOOLEAN, Opt.MULTIVALUE, Opt.NOACTION),
 
   // secret options
   TESTOUTPUT(Type.CONFIG,
           "Allow specific stdout information.  For testing purposes only.",
           Opt.UNARY, Opt.BOOTSTRAP, Opt.SECRET), // do not show this to the user
   SETPROP(Type.CONFIG, "Set an individual Java System property.",
-          Opt.STRING, Opt.MULTI, Opt.BOOTSTRAP, Opt.SECRET), // not in use yet
+          Opt.STRING, Opt.MULTIVALUE, Opt.BOOTSTRAP, Opt.SECRET), // not in use
+                                                                  // yet
   NIL(Type.FLOW,
           "This argument does nothing on its own, but can be used with linkedIds.",
-          Opt.UNARY, Opt.LINKED, Opt.MULTI, Opt.NOACTION, Opt.SECRET),
+          Opt.UNARY, Opt.LINKED, Opt.MULTIVALUE, Opt.NOACTION, Opt.SECRET),
 
   // private options (inserted during arg processing)
   SETARGFILE(Type.FLOW,
           "Sets the current value of the argfilename.  Inserted before argfilecontents.",
-          Opt.UNARY, Opt.LINKED, Opt.STRING, Opt.MULTI, Opt.PRIVATE,
+          Opt.UNARY, Opt.LINKED, Opt.STRING, Opt.MULTIVALUE, Opt.PRIVATE,
           Opt.NOACTION),
   UNSETARGFILE(Type.FLOW,
           "Unsets the current value of the argfilename.  Inserted after argfile contents.",
-          Opt.UNARY, Opt.LINKED, Opt.MULTI, Opt.PRIVATE, Opt.NOACTION),
+          Opt.UNARY, Opt.LINKED, Opt.MULTIVALUE, Opt.PRIVATE, Opt.NOACTION),
 
   // these last two have no purpose in the normal Jalview application but are
   // used by jalview.bin.Launcher to set memory settings. They are not used by
@@ -316,7 +343,7 @@ public enum Arg
      * A MULTI Arg can be specified multiple times.
      * Multiple values are stored in the ArgValuesMap (along with their positional index) for each linkedId.
      */
-    MULTI("can be specified multiple times"),
+    MULTIVALUE("can be specified multiple times"),
     /*
      * A Linked Arg can be linked to others through a --arg[linkedId] or --arg[linkedId]=value.
      * If no linkedId is specified then the current default linkedId will be used.
@@ -363,7 +390,7 @@ public enum Arg
     /*
      * An ALLOWALL Arg can use the '*' linkedId to apply to all known linkedIds
      */
-    ALLOWALL("can be used with " + ArgParser.DOUBLEDASH + "all"),
+    ALLOWMULTIID("can be used with " + ArgParser.DOUBLEDASH + "all"),
     /*
      * If an Arg has the INCREMENTDEFAULTCOUNTER option and the default linkedId is used,
      * the defaultLinkedIdCounter is incremented *first*.
@@ -384,6 +411,11 @@ public enum Arg
      */
     OUTPUTFILE("output file --headless will be assumed unless --gui used"),
     /*
+     * A STDOUT Arg can take an output filename that can be '-' to mean print to STDOUT.
+     */
+    STDOUT("allows the output filename '" + ArgParser.STDOUTFILENAME
+            + "' to mean output to STDOUT"),
+    /*
      * A STORED Arg resets and creates a new set of "opened" linkedIds
      */
     STORED(null),
@@ -447,8 +479,9 @@ public enum Arg
     STRUCTURE("arguments used to add and format 3D structure data"),
     PROCESS("arguments used to process an alignment once opened"),
     OUTPUT("arguments used to save data from a processed alignment"),
-    IMAGE("arguments used to export an image of an alignment"),
-    STRUCTUREIMAGE("arguments used to export an image of an structure"),
+    IMAGE("arguments used to export an image of an alignment or structure"),
+    // IMAGE("arguments used to export an image of an alignment"),
+    // STRUCTUREIMAGE("arguments used to export an image of an structure"),
     FLOW("arguments that control processing of the other arguments"), //
     ALL("all arguments"), // mostly just a place-holder for --help-all
     NONE, // mostly a place-holder for --help
index 907b1fa..155f69e 100644 (file)
@@ -31,12 +31,11 @@ import java.util.EnumSet;
 import java.util.Enumeration;
 import java.util.HashMap;
 import java.util.List;
-import java.util.Locale;
 import java.util.Map;
 
-import jalview.bin.Cache;
 import jalview.bin.Console;
 import jalview.bin.Jalview;
+import jalview.bin.Jalview.ExitCode;
 import jalview.bin.argparser.Arg.Opt;
 import jalview.bin.argparser.Arg.Type;
 import jalview.util.FileUtils;
@@ -50,6 +49,8 @@ public class ArgParser
 
   public static final char EQUALS = '=';
 
+  public static final String STDOUTFILENAME = "-";
+
   protected static final String NEGATESTRING = "no";
 
   /**
@@ -118,6 +119,46 @@ public class ArgParser
   private static final String LINKEDIDDIRNAME = "{dirname}";
 
   /**
+   * On-the-fly substitution (not made at argument parsing time)! the current
+   * structure filename extension
+   */
+  private static final String STRUCTUREEXTENSION = "{structureextension}";
+
+  /**
+   * On-the-fly substitution (not made at argument parsing time)! the current
+   * structure filename base
+   */
+  private static final String STRUCTUREBASENAME = "{structurebasename}";
+
+  /**
+   * On-the-fly substitution (not made at argument parsing time)! the current
+   * structure filename dir path
+   */
+  private static final String STRUCTUREDIRNAME = "{structuredirname}";
+
+  /**
+   * On-the-fly substitution (not made at argument parsing time)! increment the
+   * on-the-fly counter and substitute the incremented value
+   */
+  private static final String INCREMENTONTHEFLYCOUNTER = "{++m}";
+
+  /**
+   * On-the-fly substitution (not made at argument parsing time)! the current
+   * substitute with the on-the-fly counter
+   */
+  private static final String ONTHEFLYCOUNTER = "{m}";
+
+  /**
+   * the string used for on-the-fly structure filename substitutions
+   */
+  private String currentStructureFilename = null;
+
+  /**
+   * the counter used for on-the-fly {m} substitutions
+   */
+  private int ontheflyCounter = 0;
+
+  /**
    * the current argfile
    */
   private String argFile = null;
@@ -148,12 +189,6 @@ public class ArgParser
   private boolean allLinkedIds = false;
 
   /**
-   * flag to say whether the default linkedId is the current default linked id
-   * or OPENED linkedIds
-   */
-  private boolean openedLinkedIds = false;
-
-  /**
    * flag to say whether the structure arguments should be applied to all
    * structures with this linked id
    */
@@ -175,6 +210,15 @@ public class ArgParser
 
   private BootstrapArgs bootstrapArgs = null;
 
+  private boolean oldArguments = false;
+
+  private boolean mixedArguments = false;
+
+  /**
+   * saved examples of mixed arguments
+   */
+  private String[] mixedExamples = new String[] { null, null };
+
   static
   {
     argMap = new HashMap<>();
@@ -209,12 +253,15 @@ public class ArgParser
   public ArgParser(String[] args, boolean initsubstitutions,
           BootstrapArgs bsa)
   {
-    // Make a mutable new ArrayList so that shell globbing parser works.
-    // (When shell file globbing is used, there are a sequence of non-Arg
-    // arguments (which are the expanded globbed filenames) that need to be
-    // consumed by the --append/--argfile/etc Arg which is most easily done by
-    // removing these filenames from the list one at a time. This can't be done
-    // with an ArrayList made with only Arrays.asList(String[] args). )
+    /*
+     *  Make a mutable new ArrayList so that shell globbing parser works.
+     * (When shell file globbing is used, there are a sequence of non-Arg
+     * arguments (which are the expanded globbed filenames) that need to be
+     * consumed by the --append/--argfile/etc Arg which is most easily done
+     * by removing these filenames from the list one at a time. This can't be
+     * done with an ArrayList made with only Arrays.asList(String[] args) as
+     * that is not mutable. )
+     */
     this(new ArrayList<>(Arrays.asList(args)), initsubstitutions, false,
             bsa);
   }
@@ -236,23 +283,48 @@ public class ArgParser
       if (arg.startsWith(DOUBLEDASH))
       {
         dd = true;
-        break;
+        if (mixedExamples[1] == null)
+        {
+          mixedExamples[1] = arg;
+        }
       }
-      else if (arg.startsWith("-") || arg.equals("open"))
+      else if ((arg.startsWith("-") && !arg.equals(STDOUTFILENAME))
+              || arg.equals("open"))
       {
         d = true;
+        if (mixedExamples[0] == null)
+        {
+          mixedExamples[0] = arg;
+        }
       }
     }
-    if (d && !dd)
+    if (d)
+    {
+      if (dd)
+      {
+        mixedArguments = true;
+      }
+      else
+      {
+        oldArguments = true;
+      }
+    }
+
+    if (oldArguments || mixedArguments)
     {
       // leave it to the old style -- parse an empty list
       parse(new ArrayList<String>(), false, false);
       return;
     }
+
     if (bsa != null)
+    {
       this.bootstrapArgs = bsa;
+    }
     else
+    {
       this.bootstrapArgs = BootstrapArgs.getBootstrapArgs(args);
+    }
     parse(args, initsubstitutions, allowPrivate);
   }
 
@@ -260,27 +332,30 @@ public class ArgParser
           boolean allowPrivate)
   {
     this.substitutions = initsubstitutions;
-    boolean openEachInitialFilenames = true;
-    for (int i = 0; i < args.size(); i++)
-    {
-      String arg = args.get(i);
 
-      // If the first arguments do not start with "--" or "-" or is not "open"
-      // and` is a filename that exists it is probably a file/list of files to
-      // open so we fake an Arg.OPEN argument and when adding files only add the
-      // single arg[i] and increment the defaultLinkedIdCounter so that each of
-      // these files is opened separately.
-      if (openEachInitialFilenames && !arg.startsWith(DOUBLEDASH)
-              && !arg.startsWith("-") && !arg.equals("open")
-              && (new File(arg).exists()
-                      || HttpUtils.startsWithHttpOrHttps(arg)))
-      {
-        arg = Arg.OPEN.argString();
-      }
-      else
+    /*
+     *  If the first argument does not start with "--" or "-" or is not "open",
+     *  and is a filename that exists or a URL, it is probably a file/list of
+     *  files to open so we insert an Arg.OPEN argument before it. This will
+     *  mean the list of files at the start of the arguments are all opened
+     *  separately.
+     */
+    if (args.size() > 0)
+    {
+      String arg0 = args.get(0);
+      if (arg0 != null
+              && (!arg0.startsWith(DOUBLEDASH) && !arg0.startsWith("-")
+                      && !arg0.equals("open") && (new File(arg0).exists()
+                              || HttpUtils.startsWithHttpOrHttps(arg0))))
       {
-        openEachInitialFilenames = false;
+        // insert "--open" at the start
+        args.add(0, Arg.OPEN.argString());
       }
+    }
+
+    for (int i = 0; i < args.size(); i++)
+    {
+      String arg = args.get(i);
 
       // look for double-dash, e.g. --arg
       if (arg.startsWith(DOUBLEDASH))
@@ -371,10 +446,12 @@ public class ArgParser
         {
           // arg not found
           Console.error("Argument '" + arg + "' not recognised.  Exiting.");
-          Jalview.exit("Invalid argument used." + System.lineSeparator()
-                  + "Use" + System.lineSeparator() + "jalview "
-                  + Arg.HELP.argString() + System.lineSeparator()
-                  + "for a usage statement.", 13);
+          Jalview.exit(
+                  "Invalid argument used." + System.lineSeparator() + "Use"
+                          + System.lineSeparator() + "jalview "
+                          + Arg.HELP.argString() + System.lineSeparator()
+                          + "for a usage statement.",
+                  ExitCode.INVALID_ARGUMENT);
           continue;
         }
         if (a.hasOption(Opt.PRIVATE) && !allowPrivate)
@@ -431,7 +508,7 @@ public class ArgParser
           {
             // There is no "=" so value is next arg or args (possibly shell
             // glob-expanded)
-            if ((openEachInitialFilenames ? i : i + 1) >= args.size())
+            if (i + 1 >= args.size())
             {
               // no value to take for arg, which wants a value
               Console.error("Argument '" + a.getName()
@@ -446,8 +523,7 @@ public class ArgParser
             {
               // if this is the first argument with a file list at the start of
               // the args we add filenames from index i instead of i+1
-              globVals = getShellGlobbedFilenameValues(a, args,
-                      openEachInitialFilenames ? i : i + 1);
+              globVals = getShellGlobbedFilenameValues(a, args, i + 1);
             }
             else
             {
@@ -477,12 +553,6 @@ public class ArgParser
         else if (a == Arg.ALL)
         {
           allLinkedIds = !negated;
-          openedLinkedIds = false;
-        }
-        else if (a == Arg.OPENED)
-        {
-          openedLinkedIds = !negated;
-          allLinkedIds = false;
         }
         else if (a == Arg.ALLSTRUCTURES)
         {
@@ -509,35 +579,25 @@ public class ArgParser
         {
           if (linkedId == null)
           {
-            if (a.hasOption(Opt.OUTPUTFILE) && a.hasOption(Opt.ALLOWALL)
-                    && val.startsWith(MATCHALLLINKEDIDS))
+            if (a.hasOption(Opt.OUTPUTFILE) && a.hasOption(Opt.ALLOWMULTIID)
+                    && val.contains(MATCHALLLINKEDIDS))
             {
-              // --output=*.ext is shorthand for --all --output {basename}.ext
+              // --output=*.ext is shorthand for --output {basename}.ext
+              // --output=*/*.ext is shorthand for
+              // --output {dirname}/{basename}.ext
               // (or --image=*.ext)
-              allLinkedIds = true;
-              openedLinkedIds = false;
-              linkedId = MATCHALLLINKEDIDS;
-              val = LINKEDIDDIRNAME + File.separator + LINKEDIDBASENAME
-                      + val.substring(MATCHALLLINKEDIDS.length());
+              linkedId = allLinkedIds ? MATCHALLLINKEDIDS
+                      : MATCHOPENEDLINKEDIDS;
+              val = FileUtils.convertWildcardsToPath(val, MATCHALLLINKEDIDS,
+                      LINKEDIDDIRNAME, LINKEDIDBASENAME);
             }
-            else if (a.hasOption(Opt.OUTPUTFILE)
-                    && a.hasOption(Opt.ALLOWALL)
-                    && val.startsWith(MATCHOPENEDLINKEDIDS))
-            {
-              // --output=open*.ext is shorthand for --opened --output
-              // {basename}.ext
-              // (or --image=open*.ext)
-              openedLinkedIds = true;
-              allLinkedIds = false;
-              linkedId = MATCHOPENEDLINKEDIDS;
-              val = LINKEDIDDIRNAME + File.separator + LINKEDIDBASENAME
-                      + val.substring(MATCHOPENEDLINKEDIDS.length());
-            }
-            else if (allLinkedIds && a.hasOption(Opt.ALLOWALL))
+            else if (allLinkedIds && a.hasOption(Opt.ALLOWMULTIID))
             {
               linkedId = MATCHALLLINKEDIDS;
             }
-            else if (openedLinkedIds && a.hasOption(Opt.ALLOWALL))
+            else if (a.hasOption(Opt.ALLOWMULTIID)
+                    && this.storedLinkedIds != null
+                    && this.storedLinkedIds.size() > 0)
             {
               linkedId = MATCHOPENEDLINKEDIDS;
             }
@@ -601,10 +661,9 @@ public class ArgParser
 
         // set allstructures to all non-primary structure options in this linked
         // id if --allstructures has been set
-        if (allStructures
-                && (a.getType() == Type.STRUCTURE
-                        || a.getType() == Type.STRUCTUREIMAGE)
-                && !a.hasOption(Opt.PRIMARY))
+        if (allStructures && (a.getType() == Type.STRUCTURE
+        // || a.getType() == Type.STRUCTUREIMAGE)
+        ) && !a.hasOption(Opt.PRIMARY))
         {
           if (!subvals.has(Arg.ALLSTRUCTURES.getName()))
           // && !subvals.has("structureid"))
@@ -661,9 +720,8 @@ public class ArgParser
         // remove the '*' or 'open*' linkedId that should be empty if it was
         // created
         if ((MATCHALLLINKEDIDS.equals(linkedId)
+                || MATCHOPENEDLINKEDIDS.equals(linkedId))
                 && linkedArgs.containsKey(linkedId))
-                || (MATCHOPENEDLINKEDIDS.equals(linkedId)
-                        && linkedArgs.containsKey(linkedId)))
         {
           linkedArgs.remove(linkedId);
         }
@@ -710,6 +768,12 @@ public class ArgParser
 
   public String makeSubstitutions(String val, String linkedId)
   {
+    return makeSubstitutions(val, linkedId, false);
+  }
+
+  public String makeSubstitutions(String val, String linkedId,
+          boolean onthefly)
+  {
     if (!this.substitutions || val == null)
       return val;
 
@@ -729,14 +793,20 @@ public class ArgParser
       rest = val;
     }
     if (rest.contains(LINKEDIDAUTOCOUNTER))
+    {
       rest = rest.replace(LINKEDIDAUTOCOUNTER,
               String.valueOf(linkedIdAutoCounter));
+    }
     if (rest.contains(INCREMENTLINKEDIDAUTOCOUNTER))
+    {
       rest = rest.replace(INCREMENTLINKEDIDAUTOCOUNTER,
               String.valueOf(++linkedIdAutoCounter));
+    }
     if (rest.contains(DEFAULTLINKEDIDCOUNTER))
+    {
       rest = rest.replace(DEFAULTLINKEDIDCOUNTER,
               String.valueOf(defaultLinkedIdCounter));
+    }
     ArgValuesMap avm = linkedArgs.get(linkedId);
     if (avm != null)
     {
@@ -766,6 +836,32 @@ public class ArgParser
                 FileUtils.getDirname(new File(argFile)));
       }
     }
+    if (onthefly)
+    {
+      if (rest.contains(ONTHEFLYCOUNTER))
+      {
+        rest = rest.replace(ONTHEFLYCOUNTER,
+                String.valueOf(ontheflyCounter));
+      }
+      if (rest.contains(INCREMENTONTHEFLYCOUNTER))
+      {
+        rest = rest.replace(INCREMENTONTHEFLYCOUNTER,
+                String.valueOf(++ontheflyCounter));
+      }
+      if (currentStructureFilename != null)
+      {
+        if (rest.contains(STRUCTUREBASENAME))
+        {
+          rest = rest.replace(STRUCTUREBASENAME, FileUtils
+                  .getBasename(new File(currentStructureFilename)));
+        }
+        if (rest.contains(STRUCTUREDIRNAME))
+        {
+          rest = rest.replace(STRUCTUREDIRNAME,
+                  FileUtils.getDirname(new File(currentStructureFilename)));
+        }
+      }
+    }
 
     return new StringBuilder(subvals).append(rest).toString();
   }
@@ -908,7 +1004,7 @@ public class ArgParser
       {
         String message = Arg.ARGFILE.argString() + EQUALS + "\""
                 + argFile.getPath() + "\": File does not exist.";
-        Jalview.exit(message, 2);
+        Jalview.exit(message, ExitCode.FILE_NOT_FOUND);
       }
       try
       {
@@ -922,7 +1018,7 @@ public class ArgParser
       {
         String message = Arg.ARGFILE.argString() + "=\"" + argFile.getPath()
                 + "\": File could not be read.";
-        Jalview.exit(message, 3);
+        Jalview.exit(message, ExitCode.FILE_NOT_READABLE);
       }
     }
     // Third param "true" uses Opt.PRIVATE args --setargile=argfile and
@@ -948,167 +1044,12 @@ public class ArgParser
         String message = Arg.ARGFILE.argString() + "=\"" + argFile.getPath()
                 + "\": File could not be read.";
         Console.debug(message, e);
-        Jalview.exit(message, 3);
+        Jalview.exit(message, ExitCode.FILE_NOT_READABLE);
       }
     }
     return args;
   }
 
-  public static enum Position
-  {
-    FIRST, BEFORE, AFTER
-  }
-
-  /**
-   * get from following Arg of type a or subval of same name (lowercase)
-   */
-  public static String getValueFromSubValOrArg(ArgValuesMap avm,
-          ArgValue av, Arg a, SubVals sv)
-  {
-    return getFromSubValArgOrPref(avm, av, a, sv, null, null, null);
-  }
-
-  /**
-   * get from following Arg of type a or subval key or preference pref or
-   * default def
-   */
-  public static String getFromSubValArgOrPref(ArgValuesMap avm, ArgValue av,
-          Arg a, SubVals sv, String key, String pref, String def)
-  {
-    return getFromSubValArgOrPref(avm, a, Position.AFTER, av, sv, key, pref,
-            def);
-  }
-
-  /**
-   * get from following(AFTER), first occurence of (FIRST) or previous (BEFORE)
-   * Arg of type a or subval key or preference pref or default def
-   */
-  public static String getFromSubValArgOrPref(ArgValuesMap avm, Arg a,
-          Position pos, ArgValue av, SubVals sv, String key, String pref,
-          String def)
-  {
-    return getFromSubValArgOrPrefWithSubstitutions(null, avm, a, pos, av,
-            sv, key, pref, def);
-  }
-
-  public static String getFromSubValArgOrPrefWithSubstitutions(ArgParser ap,
-          ArgValuesMap avm, Arg a, Position pos, ArgValue av, SubVals sv,
-          String key, String pref, String def)
-  {
-    if (key == null)
-      key = a.getName();
-    String value = null;
-    if (sv != null && sv.has(key) && sv.get(key) != null)
-    {
-      value = ap == null ? sv.get(key)
-              : sv.getWithSubstitutions(ap, avm.getLinkedId(), key);
-    }
-    else if (avm != null && avm.containsArg(a))
-    {
-      if (pos == Position.FIRST && avm.getValue(a) != null)
-        value = avm.getValue(a);
-      else if (pos == Position.BEFORE
-              && avm.getClosestPreviousArgValueOfArg(av, a) != null)
-        value = avm.getClosestPreviousArgValueOfArg(av, a).getValue();
-      else if (pos == Position.AFTER
-              && avm.getClosestNextArgValueOfArg(av, a) != null)
-        value = avm.getClosestNextArgValueOfArg(av, a).getValue();
-
-      // look for allstructures subval for Type.STRUCTURE*
-      Arg arg = av.getArg();
-      if (value == null && arg.hasOption(Opt.PRIMARY)
-              && arg.getType() == Type.STRUCTURE
-              && !a.hasOption(Opt.PRIMARY) && (a.getType() == Type.STRUCTURE
-                      || a.getType() == Type.STRUCTUREIMAGE))
-      {
-        ArgValue av2 = avm.getArgValueOfArgWithSubValKey(a,
-                Arg.ALLSTRUCTURES.getName());
-        if (av2 != null)
-        {
-          value = av2.getValue();
-        }
-      }
-    }
-    if (value == null)
-    {
-      value = pref != null ? Cache.getDefault(pref, def) : def;
-    }
-    return value;
-  }
-
-  public static boolean getBoolFromSubValOrArg(ArgValuesMap avm, Arg a,
-          SubVals sv)
-  {
-    return getFromSubValArgOrPref(avm, a, sv, null, null, false);
-  }
-
-  public static boolean getFromSubValArgOrPref(ArgValuesMap avm, Arg a,
-          SubVals sv, String key, String pref, boolean def)
-  {
-    return getFromSubValArgOrPref(avm, a, sv, key, pref, def, false);
-  }
-
-  public static boolean getFromSubValArgOrPref(ArgValuesMap avm, Arg a,
-          SubVals sv, String key, String pref, boolean def,
-          boolean invertPref)
-  {
-    if ((key == null && a == null) || (sv == null && a == null))
-      return false;
-
-    boolean usingArgKey = false;
-    if (key == null)
-    {
-      key = a.getName();
-      usingArgKey = true;
-    }
-
-    String nokey = ArgParser.NEGATESTRING + key;
-
-    // look for key or nokey in subvals first (if using Arg check options)
-    if (sv != null)
-    {
-      // check for true boolean
-      if (sv.has(key) && sv.get(key) != null)
-      {
-        if (usingArgKey)
-        {
-          if (!(a.hasOption(Opt.BOOLEAN) || a.hasOption(Opt.UNARY)))
-          {
-            Console.debug(
-                    "Looking for boolean in subval from non-boolean/non-unary Arg "
-                            + a.getName());
-            return false;
-          }
-        }
-        return sv.get(key).toLowerCase(Locale.ROOT).equals("true");
-      }
-
-      // check for negative boolean (subval "no..." will be "true")
-      if (sv.has(nokey) && sv.get(nokey) != null)
-      {
-        if (usingArgKey)
-        {
-          if (!(a.hasOption(Opt.BOOLEAN)))
-          {
-            Console.debug(
-                    "Looking for negative boolean in subval from non-boolean Arg "
-                            + a.getName());
-            return false;
-          }
-        }
-        return !sv.get(nokey).toLowerCase(Locale.ROOT).equals("true");
-      }
-    }
-
-    // check argvalues
-    if (avm != null && avm.containsArg(a))
-      return avm.getBoolean(a);
-
-    // return preference or default
-    boolean prefVal = pref != null ? Cache.getDefault(pref, def) : false;
-    return pref != null ? (invertPref ? !prefVal : prefVal) : def;
-  }
-
   // the following methods look for the "*" linkedId and add the argvalue to all
   // linkedId ArgValues if it does.
   /**
@@ -1121,13 +1062,6 @@ public class ArgParser
             argIndex, doSubs);
   }
 
-  private void addValue(String linkedId, Type type, ArgValues avs, String v,
-          int argIndex, boolean doSubs)
-  {
-    this.argValueOperation(Op.ADDVALUE, linkedId, type, avs, null, v, false,
-            argIndex, doSubs);
-  }
-
   private void setBoolean(String linkedId, Type type, ArgValues avs,
           boolean b, int argIndex)
   {
@@ -1195,7 +1129,7 @@ public class ArgParser
     Arg a = avs.arg();
 
     List<String> wildcardLinkedIds = null;
-    if (a.hasOption(Opt.ALLOWALL))
+    if (a.hasOption(Opt.ALLOWMULTIID))
     {
       switch (linkedId)
       {
@@ -1226,7 +1160,9 @@ public class ArgParser
         // skip incorrectly stored wildcard ids!
         if (id == null || MATCHALLLINKEDIDS.equals(id)
                 || MATCHOPENEDLINKEDIDS.equals(id))
+        {
           continue;
+        }
         ArgValuesMap avm = linkedArgs.get(id);
         // don't set an output if there isn't an input
         if (a.hasOption(Opt.REQUIREINPUT)
@@ -1334,4 +1270,24 @@ public class ArgParser
     return linkedArgs.get(linkedId);
   }
 
+  public boolean isOldStyle()
+  {
+    return oldArguments;
+  }
+
+  public boolean isMixedStyle()
+  {
+    return mixedArguments;
+  }
+
+  public String[] getMixedExamples()
+  {
+    return mixedExamples;
+  }
+
+  public void setStructureFilename(String s)
+  {
+    this.currentStructureFilename = s;
+  }
+
 }
\ No newline at end of file
index f25fc9a..2b9061c 100644 (file)
@@ -151,9 +151,9 @@ public class ArgValues
   protected void addArgValue(ArgValue av, boolean beingSetByWildcard)
   {
     // allow a non-wildcard value to overwrite a wildcard set single value
-    boolean overwrite = !arg.hasOption(Opt.MULTI) && setByWildcard
+    boolean overwrite = !arg.hasOption(Opt.MULTIVALUE) && setByWildcard
             && !beingSetByWildcard;
-    if ((!arg.hasOption(Opt.MULTI) && argValueList.size() > 0)
+    if ((!arg.hasOption(Opt.MULTIVALUE) && argValueList.size() > 0)
             && !overwrite)
       return;
     if (arg.hasOption(Opt.NODUPLICATEVALUES)
@@ -182,7 +182,7 @@ public class ArgValues
 
   protected ArgValue getArgValue()
   {
-    if (arg.hasOption(Opt.MULTI))
+    if (arg.hasOption(Opt.MULTIVALUE))
       Console.warn("Requesting single value for multi value argument");
     return argValueList.size() > 0 ? argValueList.get(0) : null;
   }
index ab6fcc1..99a4836 100644 (file)
@@ -2,12 +2,17 @@ package jalview.bin.argparser;
 
 import java.io.File;
 import java.util.ArrayList;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.List;
+import java.util.Locale;
 import java.util.Map;
 import java.util.Set;
 
+import jalview.bin.Cache;
+import jalview.bin.Console;
 import jalview.bin.argparser.Arg.Opt;
+import jalview.bin.argparser.Arg.Type;
 import jalview.util.FileUtils;
 
 /**
@@ -16,6 +21,8 @@ import jalview.util.FileUtils;
  */
 public class ArgValuesMap
 {
+  private List<ArgInfo> argInfoList = new ArrayList<>();
+
   protected Map<Arg, ArgValues> m;
 
   private String linkedId;
@@ -165,7 +172,8 @@ public class ArgValuesMap
     return closestAv;
   }
 
-  public ArgValue getClosestNextArgValueOfArg(ArgValue thisAv, Arg a)
+  public ArgValue getClosestNextArgValueOfArg(ArgValue thisAv, Arg a,
+          boolean withinType)
   {
     // this looks for the *next* arg that *might* be referring back to
     // a thisAv. Such an arg would have no subValues (if it does it should
@@ -185,6 +193,35 @@ public class ArgValuesMap
         closestAv = av;
       }
     }
+
+    // check if withinType this closestAv doesn't belong to the next primary arg
+    // of this type
+    if (withinType && closestAv != null)
+    {
+      int nextPrimaryArgOfSameTypeIndex = Integer.MAX_VALUE;
+      for (Arg tmpA : this.getArgKeys())
+      {
+        // interested in Opt.PRIMARY args of the same type
+        if (tmpA.getType() == a.getType() && tmpA.hasOption(Opt.PRIMARY))
+        {
+          for (ArgValue tmpAv : getArgValueList(tmpA))
+          {
+            int tmpArgIndex = tmpAv.getArgIndex();
+            if (tmpArgIndex > thisArgIndex
+                    && tmpArgIndex < nextPrimaryArgOfSameTypeIndex)
+            {
+              nextPrimaryArgOfSameTypeIndex = tmpArgIndex;
+            }
+          }
+        }
+      }
+      if (nextPrimaryArgOfSameTypeIndex < closestAv.getArgIndex())
+      {
+        // looks licke closestAv actually belongs to a different primary Arg
+        return null;
+      }
+    }
+
     return closestAv;
   }
 
@@ -226,7 +263,7 @@ public class ArgValuesMap
    */
   public String getBasename()
   {
-    return getDirBasenameOrExtension(false, false);
+    return getDirBasenameOrExtension(false, false, false);
   }
 
   /*
@@ -235,7 +272,7 @@ public class ArgValuesMap
    */
   public String getExtension()
   {
-    return getDirBasenameOrExtension(false, true);
+    return getDirBasenameOrExtension(false, true, false);
   }
 
   /*
@@ -244,11 +281,11 @@ public class ArgValuesMap
    */
   public String getDirname()
   {
-    return getDirBasenameOrExtension(true, false);
+    return getDirBasenameOrExtension(true, false, false);
   }
 
   public String getDirBasenameOrExtension(boolean dirname,
-          boolean extension)
+          boolean extension, boolean absoluteDirname)
   {
     String filename = null;
     String appendVal = getValue(Arg.APPEND);
@@ -281,4 +318,226 @@ public class ArgValuesMap
     }
     return false;
   }
+
+  /*
+   * ArgInfo is a more straightforward list of arguments and their info
+   */
+
+  public void addArgInfo(Arg arg, String value, SubVals subVals,
+          int argIndex)
+  {
+    argInfoList.add(new ArgInfo(arg, value, subVals, argIndex));
+  }
+
+  public List<ArgInfo> getArgInfoList()
+  {
+    Collections.sort(argInfoList);
+    return argInfoList;
+  }
+
+  /**
+   * get from following Arg of type a or subval of same name (lowercase)
+   */
+  public String getValueFromSubValOrArg(ArgValue av, Arg a, SubVals sv)
+  {
+    return getFromSubValArgOrPref(av, a, sv, null, null, null);
+  }
+
+  /**
+   * get from following Arg of type a or subval key or preference pref or
+   * default def
+   */
+  public String getFromSubValArgOrPref(ArgValue av, Arg a, SubVals sv,
+          String key, String pref, String def)
+  {
+    return getFromSubValArgOrPref(a, ArgValuesMap.Position.AFTER, av, sv,
+            key, pref, def);
+  }
+
+  /**
+   * get from following(AFTER), first occurence of (FIRST) or previous (BEFORE)
+   * Arg of type a or subval key or preference pref or default def
+   */
+  public String getFromSubValArgOrPref(Arg a, ArgValuesMap.Position pos,
+          ArgValue av, SubVals sv, String key, String pref, String def)
+  {
+    return getFromSubValArgOrPrefWithSubstitutions(null, a, pos, av, sv,
+            key, pref, def);
+  }
+
+  public String getFromSubValArgOrPrefWithSubstitutions(ArgParser ap, Arg a,
+          ArgValuesMap.Position pos, ArgValue av, SubVals sv, String key,
+          String pref, String def)
+  {
+    return getFromSubValArgOrPrefWithSubstitutionsWithinType(ap, a, pos, av,
+            sv, key, pref, def, true);
+  }
+
+  public String getFromSubValArgOrPrefWithSubstitutionsWithinType(
+          ArgParser ap, Arg a, ArgValuesMap.Position pos, ArgValue av,
+          SubVals sv, String key, String pref, String def,
+          boolean withinType)
+  {
+    if (key == null)
+      key = a.getName();
+    String value = null;
+    if (sv != null && sv.has(key) && sv.get(key) != null)
+    {
+      value = ap == null ? sv.get(key)
+              : sv.getWithSubstitutions(ap, getLinkedId(), key);
+    }
+    else if (containsArg(a))
+    {
+      if (pos == ArgValuesMap.Position.FIRST && getValue(a) != null)
+        value = getValue(a);
+      else if (pos == ArgValuesMap.Position.BEFORE
+              && getClosestPreviousArgValueOfArg(av, a) != null)
+        value = getClosestPreviousArgValueOfArg(av, a).getValue();
+      else if (pos == ArgValuesMap.Position.AFTER
+              && getClosestNextArgValueOfArg(av, a, withinType) != null)
+        value = getClosestNextArgValueOfArg(av, a, withinType).getValue();
+
+      // look for allstructures subval for Type.STRUCTURE
+      Arg arg = av.getArg();
+      if (value == null && arg.hasOption(Opt.PRIMARY)
+              && arg.getType() == Type.STRUCTURE
+              && !a.hasOption(Opt.PRIMARY) && (a.getType() == Type.STRUCTURE
+              // || a.getType() == Type.STRUCTUREIMAGE))
+              ))
+      {
+        ArgValue av2 = getArgValueOfArgWithSubValKey(a,
+                Arg.ALLSTRUCTURES.getName());
+        if (av2 != null)
+        {
+          value = av2.getValue();
+        }
+      }
+    }
+    if (value == null)
+    {
+      value = pref != null ? Cache.getDefault(pref, def) : def;
+    }
+    return value;
+  }
+
+  public boolean getBoolFromSubValOrArg(Arg a, SubVals sv)
+  {
+    return getFromSubValArgOrPref(a, sv, null, null, false);
+  }
+
+  public boolean getFromSubValArgOrPref(Arg a, SubVals sv, String key,
+          String pref, boolean def)
+  {
+    return getFromSubValArgOrPref(a, sv, key, pref, def, false);
+  }
+
+  public boolean getFromSubValArgOrPref(Arg a, SubVals sv, String key,
+          String pref, boolean def, boolean invertPref)
+  {
+    if ((key == null && a == null) || (sv == null && a == null))
+      return false;
+
+    boolean usingArgKey = false;
+    if (key == null)
+    {
+      key = a.getName();
+      usingArgKey = true;
+    }
+
+    String nokey = ArgParser.NEGATESTRING + key;
+
+    // look for key or nokey in subvals first (if using Arg check options)
+    if (sv != null)
+    {
+      // check for true boolean
+      if (sv.has(key) && sv.get(key) != null)
+      {
+        if (usingArgKey)
+        {
+          if (!(a.hasOption(Opt.BOOLEAN) || a.hasOption(Opt.UNARY)))
+          {
+            Console.debug(
+                    "Looking for boolean in subval from non-boolean/non-unary Arg "
+                            + a.getName());
+            return false;
+          }
+        }
+        return sv.get(key).toLowerCase(Locale.ROOT).equals("true");
+      }
+
+      // check for negative boolean (subval "no..." will be "true")
+      if (sv.has(nokey) && sv.get(nokey) != null)
+      {
+        if (usingArgKey)
+        {
+          if (!(a.hasOption(Opt.BOOLEAN)))
+          {
+            Console.debug(
+                    "Looking for negative boolean in subval from non-boolean Arg "
+                            + a.getName());
+            return false;
+          }
+        }
+        return !sv.get(nokey).toLowerCase(Locale.ROOT).equals("true");
+      }
+    }
+
+    // check argvalues
+    if (containsArg(a))
+      return getBoolean(a);
+
+    // return preference or default
+    boolean prefVal = pref != null ? Cache.getDefault(pref, def) : false;
+    return pref != null ? (invertPref ? !prefVal : prefVal) : def;
+  }
+
+  public class ArgInfo implements Comparable<ArgInfo>
+  {
+    private Arg arg;
+
+    private String value;
+
+    private SubVals subVals;
+
+    private int argIndex;
+
+    public ArgInfo(Arg arg, String value, SubVals subVals, int argIndex)
+    {
+      this.arg = arg;
+      this.value = value;
+      this.subVals = subVals;
+      this.argIndex = argIndex;
+    }
+
+    public Arg arg()
+    {
+      return arg;
+    }
+
+    public String value()
+    {
+      return value;
+    }
+
+    public SubVals subVals()
+    {
+      return subVals;
+    }
+
+    public int argIndex()
+    {
+      return argIndex;
+    }
+
+    @Override
+    public int compareTo(ArgInfo ai2)
+    {
+      return Integer.compare(this.argIndex(), ai2.argIndex());
+    }
+  }
+
+  public static enum Position
+  {
+    FIRST, BEFORE, AFTER
+  }
 }
index 4b7b180..5c21d03 100644 (file)
@@ -28,6 +28,8 @@ public class BootstrapArgs
 
   private Set<Type> argsTypes = new HashSet<>();
 
+  private boolean outputToStdout = false;
+
   public static BootstrapArgs getBootstrapArgs(String[] args)
   {
     List<String> argList = new ArrayList<>(Arrays.asList(args));
@@ -53,7 +55,7 @@ public class BootstrapArgs
     {
       if (argFiles.contains(inArgFile))
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Looped argfiles detected: '" + inArgFile.getPath() + "'");
         return;
       }
@@ -127,11 +129,6 @@ public class BootstrapArgs
           }
         }
 
-        if (ArgParser.argMap.containsKey(argName) && val == null)
-        {
-          val = "true";
-        }
-
         Arg a = ArgParser.argMap.get(argName);
 
         if (a != null)
@@ -152,7 +149,27 @@ public class BootstrapArgs
 
         if (a == null || !a.hasOption(Opt.BOOTSTRAP))
         {
-          // not a valid bootstrap arg
+          // not a bootstrap arg
+
+          // make a check for an output going to stdout
+          if (a != null && a.hasOption(Opt.OUTPUTFILE)
+                  && a.hasOption(Opt.STDOUT))
+          {
+            if (val == null && i + 1 < args.size())
+            {
+              val = args.get(i + 1);
+            }
+            if (val.startsWith("[") && val.indexOf(']') > 0)
+            {
+              val = val.substring(val.indexOf(']') + 1);
+            }
+
+            if (ArgParser.STDOUTFILENAME.equals(val))
+            {
+              this.outputToStdout = true;
+            }
+          }
+
           continue;
         }
 
@@ -188,10 +205,22 @@ public class BootstrapArgs
         }
         else
         {
+          if (val == null)
+          {
+            val = "true";
+          }
+
           add(a, type, val);
         }
       }
     }
+
+    // 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)
@@ -270,7 +299,7 @@ public class BootstrapArgs
   private void add(Arg a, Type t, String s)
   {
     List<Map.Entry<Type, String>> l = getOrCreateList(a);
-    if (a.hasOption(Opt.MULTI) || l.size() == 0)
+    if (a.hasOption(Opt.MULTIVALUE) || l.size() == 0)
     {
       l.add(entry(t, s));
     }
@@ -279,7 +308,7 @@ public class BootstrapArgs
   private void addAll(Arg a, Type t, List<String> al)
   {
     List<Map.Entry<Type, String>> l = getOrCreateList(a);
-    if (a.hasOption(Opt.MULTI))
+    if (a.hasOption(Opt.MULTIVALUE))
     {
       for (String s : al)
       {
@@ -362,7 +391,7 @@ public class BootstrapArgs
     }
     else if (this.contains(Arg.HEADLESS))
     {
-      // --headless, --noheadless specified => use value
+      // --headless has been specified on the command line => headless
       isHeadless = this.getBoolean(Arg.HEADLESS);
     }
     else if (this.argsHaveOption(Opt.OUTPUTFILE))
@@ -373,4 +402,9 @@ public class BootstrapArgs
     }
     return isHeadless;
   }
+
+  public boolean outputToStdout()
+  {
+    return this.outputToStdout;
+  }
 }
diff --git a/src/jalview/bin/groovy/JalviewObject.java b/src/jalview/bin/groovy/JalviewObject.java
new file mode 100644 (file)
index 0000000..e271c3c
--- /dev/null
@@ -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 (file)
index 0000000..f365d30
--- /dev/null
@@ -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();
+}
index 62ef660..c15bbf8 100644 (file)
@@ -473,7 +473,7 @@ public class EditCommand implements CommandI
     {
       command.seqs[s].insertCharAt(command.position, command.number,
               command.gapChar);
-      // System.out.println("pos: "+command.position+" number:
+      // jalview.bin.Console.outPrintln("pos: "+command.position+" number:
       // "+command.number);
     }
 
@@ -486,7 +486,7 @@ public class EditCommand implements CommandI
   //
   // for (int s = 0; s < command.seqs.length; s++)
   // {
-  // System.out.println("pos: "+command.position+" number: "+command.number);
+  // jalview.bin.Console.outPrintln("pos: "+command.position+" number: "+command.number);
   // command.seqs[s].insertCharAt(command.position, command.number,'A');
   // }
   //
@@ -1433,7 +1433,7 @@ public class EditCommand implements CommandI
           }
           else
           {
-            System.err.println("Can't undo edit action " + action);
+            jalview.bin.Console.errPrintln("Can't undo edit action " + action);
             // throw new IllegalStateException("Can't undo edit action " +
             // action);
           }
index f5154ec..cb74a66 100644 (file)
@@ -707,7 +707,7 @@ public class AlignedCodonFrame
             ds.setSequenceFeatures(dna.getSequenceFeatures());
             // dnaSeqs[i] = ds;
             ssm.fromSeq = ds;
-            System.out.println("Realised mapped sequence " + ds.getName());
+            jalview.bin.Console.outPrintln("Realised mapped sequence " + ds.getName());
           }
         }
       }
index 514a326..375e6b4 100755 (executable)
@@ -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);
@@ -2069,6 +2069,10 @@ public class Alignment implements AlignmentI, AutoCloseable
   @Override
   public ContactListI getContactListFor(AlignmentAnnotation _aa, int column)
   {
+    if (_aa.annotations==null || column>=_aa.annotations.length || column<0)
+    {
+      return null;
+    }
     ContactListI cl = cmholder.getContactListFor(_aa, column);
     if (cl == null && _aa.groupRef != null)
     {
index de98c64..7e6b904 100755 (executable)
@@ -126,7 +126,7 @@ public class AlignmentAnnotation
       invalidrnastruc = -1;
     } catch (WUSSParseException px)
     {
-      // DEBUG System.out.println(px);
+      // DEBUG jalview.bin.Console.outPrintln(px);
       invalidrnastruc = px.getProblemPos();
     }
     if (invalidrnastruc > -1)
@@ -142,7 +142,7 @@ public class AlignmentAnnotation
       scaleColLabel = true;
       _markRnaHelices();
     }
-    // System.out.println("featuregroup " + _rnasecstr[0].getFeatureGroup());
+    // jalview.bin.Console.outPrintln("featuregroup " + _rnasecstr[0].getFeatureGroup());
 
   }
 
@@ -156,10 +156,10 @@ public class AlignmentAnnotation
     {
 
       /*
-       * System.out.println(this.annotation._rnasecstr[x] + " Begin" +
+       * jalview.bin.Console.outPrintln(this.annotation._rnasecstr[x] + " Begin" +
        * this.annotation._rnasecstr[x].getBegin());
        */
-      // System.out.println(this.annotation._rnasecstr[x].getFeatureGroup());
+      // jalview.bin.Console.outPrintln(this.annotation._rnasecstr[x].getFeatureGroup());
       int val = 0;
       try
       {
@@ -386,7 +386,7 @@ public class AlignmentAnnotation
     char firstChar = 0;
     for (int i = 0; i < annotations.length; i++)
     {
-      // DEBUG System.out.println(i + ": " + annotations[i]);
+      // DEBUG jalview.bin.Console.outPrintln(i + ": " + annotations[i]);
       if (annotations[i] == null)
       {
         continue;
@@ -394,14 +394,14 @@ public class AlignmentAnnotation
       if (annotations[i].secondaryStructure == 'H'
               || annotations[i].secondaryStructure == 'E')
       {
-        // DEBUG System.out.println( "/H|E/ '" +
+        // DEBUG jalview.bin.Console.outPrintln( "/H|E/ '" +
         // annotations[i].secondaryStructure + "'");
         hasIcons |= true;
       }
       else
       // Check for RNA secondary structure
       {
-        // DEBUG System.out.println( "/else/ '" +
+        // DEBUG jalview.bin.Console.outPrintln( "/else/ '" +
         // annotations[i].secondaryStructure + "'");
         // TODO: 2.8.2 should this ss symbol validation check be a function in
         // RNA/ResidueProperties ?
@@ -446,7 +446,7 @@ public class AlignmentAnnotation
         }
       }
 
-      // System.out.println("displaychar " + annotations[i].displayCharacter);
+      // jalview.bin.Console.outPrintln("displaychar " + annotations[i].displayCharacter);
 
       if (annotations[i].displayCharacter == null
               || annotations[i].displayCharacter.length() == 0)
index e6604d1..6ab71c7 100644 (file)
@@ -1128,11 +1128,11 @@ public class AlignmentView
   public static void testSelectionViews(AlignmentI alignment,
           HiddenColumns hidden, SequenceGroup selection)
   {
-    System.out.println("Testing standard view creation:\n");
+    jalview.bin.Console.outPrintln("Testing standard view creation:\n");
     AlignmentView view = null;
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View with no hidden columns, no limit to selection, no groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, false, false,
               false);
@@ -1141,12 +1141,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection but no groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View with no hidden columns, no limit to selection, and all groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, false, false,
               true);
@@ -1154,12 +1154,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection marked but no groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View with no hidden columns, limited to selection and no groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, false, true,
               false);
@@ -1167,12 +1167,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection restricted but no groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View with no hidden columns, limited to selection, and all groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, false, true,
               true);
@@ -1180,12 +1180,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection restricted and groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View *with* hidden columns, no limit to selection, no groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, true, false,
               false);
@@ -1193,12 +1193,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection but no groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View *with* hidden columns, no limit to selection, and all groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, true, false,
               true);
@@ -1206,12 +1206,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection marked but no groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View *with* hidden columns, limited to selection and no groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, true, true,
               false);
@@ -1219,12 +1219,12 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection restricted but no groups marked.");
     }
     try
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "View *with* hidden columns, limited to selection, and all groups to be collected:");
       view = new AlignmentView(alignment, hidden, selection, true, true,
               true);
@@ -1232,7 +1232,7 @@ public class AlignmentView
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to generate alignment with selection restricted and groups marked.");
     }
 
index 4a38ec0..b427739 100644 (file)
@@ -340,10 +340,12 @@ public class ColumnSelection
 
   /**
    * Returns a read-only view of the (possibly empty) list of selected columns
+   * (base 1)
    * <p>
-   * The list contains no duplicates but is not necessarily ordered. It also may
-   * include columns hidden from the current view. To modify (for example sort)
-   * the list, you should first make a copy.
+   * The list contains no duplicates but is not necessarily ordered. Columns are
+   * reported in alignment coordinates (base 1), so may also include columns
+   * hidden from the current view. To modify (for example sort) the list, you
+   * should first make a copy.
    * <p>
    * The list is not thread-safe: iterating over it could result in
    * ConcurrentModificationException if it is modified by another thread.
index bb31c5d..7058ac7 100644 (file)
@@ -88,7 +88,7 @@ public class ContactListImpl implements ContactListI
         }
       }
     }
-    if (tot > 0)
+    if (tot > 0 && to_column>from_column)
     {
       cr.setMean(tot / (1 + to_column - from_column));
     }
index af083dd..3a64917 100644 (file)
@@ -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<ContactMatrixI>(contactmaps.values());
     }
     return Collections.EMPTY_LIST;
   }
index 48b6e6b..2e12a91 100644 (file)
@@ -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<Float> 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<Float> 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())
     {
index 925025f..4261519 100644 (file)
@@ -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 (file)
index 0000000..5fb156f
--- /dev/null
@@ -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 (file)
index 0000000..faeb7c0
--- /dev/null
@@ -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;
+  }
+
+}
index b5efeb4..e2ef318 100755 (executable)
@@ -159,7 +159,7 @@ public class HiddenSequences
 
     if (alignmentIndex < 0 || hiddenSequences[alignmentIndex] != null)
     {
-      System.out.println("ERROR!!!!!!!!!!!");
+      jalview.bin.Console.outPrintln("ERROR!!!!!!!!!!!");
       return;
     }
 
@@ -239,7 +239,7 @@ public class HiddenSequences
           }
           else
           {
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     seq.getName() + " has been deleted whilst hidden");
           }
         }
index 661ad6c..dedb960 100644 (file)
@@ -57,4 +57,13 @@ public interface SearchResultMatchI
    * @return
    */
   boolean contains(SequenceI seq, int start, int end);
+
+  /**
+   *
+   * @param seq
+   * @param from - first position to highlight
+   * @param to - last position to highlight (assumed higher than from)
+   * @return true iff from-to intersects or marks positions either side of start/end
+   */
+  boolean adjacent(SequenceI seq, int from, int to);
 }
\ No newline at end of file
index 909a0fe..546dd6f 100755 (executable)
@@ -35,13 +35,13 @@ public class SearchResults implements SearchResultsI
 {
   private int count;
 
-  private List<SearchResultMatchI> matches = new ArrayList<>();
+  private ArrayList<SearchResultMatchI> matches = new ArrayList<>();
 
   /**
    * One match consists of a sequence reference, start and end positions.
    * Discontiguous ranges in a sequence require two or more Match objects.
    */
-  public class Match implements SearchResultMatchI
+  public class Match implements SearchResultMatchI, Comparable<SearchResultMatchI>
   {
     final SequenceI sequence;
 
@@ -160,6 +160,39 @@ public class SearchResults implements SearchResultsI
     {
       return (sequence == seq && start <= from && end >= to);
     }
+    @Override
+    public boolean adjacent(SequenceI seq, int from, int to)
+    {
+      return (sequence == seq && ((start <= from && end >= to) || (from<=(end+1) && to >=(end+1)) || (from<=(start-1) && to>=(start-1))));
+    }
+
+    @Override
+    public int compareTo(SearchResultMatchI o)
+    {
+      if (start<o.getStart())
+      {
+        return -1;
+      }
+      if (start > o.getStart())
+      {
+        return +1;
+      }
+      if (end < o.getEnd())
+      {
+        return -1;
+      }
+      if (end > o.getEnd())
+      {
+        return +1;
+      }
+      if (sequence!=o.getSequence())
+      {
+        int hashc =sequence.hashCode(),oseq=o.getSequence().hashCode();
+        return (hashc < oseq) ? -1 : 1;
+      }
+      return 0;
+    }
+    
   }
 
   @Override
@@ -191,8 +224,56 @@ public class SearchResults implements SearchResultsI
       count = beforeCount + 1;
     }
   }
+  
 
   @Override
+  public boolean appendResult(SequenceI sequence, int start, int end)
+  {
+
+    Match m = new Match(sequence, start, end);
+    
+    boolean appending=false;
+    
+    // we dynamically maintain an interval to add as we test each range in the list
+    
+    int cstart=start,cend=end;
+    List<SearchResultMatchI> toRemove=new ArrayList<>();
+    for (SearchResultMatchI thatm:matches)
+    {
+      if (thatm.getSequence()==sequence)
+      {
+        if (thatm.contains(sequence,cstart,cend))
+        {
+          // found a match containing the current range. nothing else to do except report if we operated on the list
+          return appending;
+        }
+        if (thatm.adjacent(sequence, cstart, cend))
+        {
+          // update the match to add with the adjacent start/end
+          start = Math.min(m.start, thatm.getStart());
+          end = Math.max(m.end, thatm.getEnd());
+          // and check if we keep or remove the old one
+          if (thatm.getStart()!=start || thatm.getEnd()!=end)
+          { 
+            toRemove.add(thatm);
+            count--;
+            cstart = start;
+            cend = end;
+            appending=true;
+          } else {
+            return false;
+          }
+        }
+      }
+    }
+    matches.removeAll(toRemove);
+    {
+      matches.add(new Match(sequence,cstart,cend));
+      count++;
+    }
+    return appending;
+  }
+  @Override
   public boolean involvesSequence(SequenceI sequence)
   {
     final int start = sequence.getStart();
@@ -269,7 +350,7 @@ public class SearchResults implements SearchResultsI
         else
         {
           // debug
-          // System.err.println("Outwith bounds!" + matchStart+">"+end +" or "
+          // jalview.bin.Console.errPrintln("Outwith bounds!" + matchStart+">"+end +" or "
           // + matchEnd+"<"+start);
         }
       }
@@ -393,4 +474,5 @@ public class SearchResults implements SearchResultsI
     }
     return seqs;
   }
+
 }
index 7946824..d682de1 100644 (file)
@@ -51,6 +51,19 @@ public interface SearchResultsI
    */
   void addResult(SequenceI seq, int[] positions);
 
+
+  /**
+   * Adds the given start/end region to this search result. If sequence already
+   * has a search result and the range is adjacent to already highlighted
+   * positions, they will be merged
+   * 
+   * @param sequence
+   * @param start
+   * @param end
+   * @return true if an existing range was updated with this one
+   */
+  boolean appendResult(SequenceI sequence, int start, int end);
+
   /**
    * adds all match results in the argument to this set
    * 
index f8fd750..b04ac13 100644 (file)
@@ -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);
   }
index 5bb55e5..7a5d5bc 100755 (executable)
@@ -174,7 +174,7 @@ public class Sequence extends ASequence implements SequenceI
   {
     if (name == null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "POSSIBLE IMPLEMENTATION ERROR: null sequence name passed to constructor.");
       name = "";
     }
@@ -387,7 +387,7 @@ public class Sequence extends ASequence implements SequenceI
   {
     if (sf.getType() == null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "SequenceFeature type may not be null: " + sf.toString());
       return false;
     }
index 326793d..9837104 100755 (executable)
@@ -644,7 +644,7 @@ public class SequenceGroup implements AnnotatedCollectionI
     } catch (java.lang.OutOfMemoryError err)
     {
       // TODO: catch OOM
-      System.out.println("Out of memory loading groups: " + err);
+      jalview.bin.Console.outPrintln("Out of memory loading groups: " + err);
     }
     return upd;
   }
index 65cba0d..124909c 100644 (file)
@@ -147,7 +147,7 @@ public class FeatureMatcher implements FeatureMatcherI
       int nextQuotePos = descriptor.indexOf(QUOTE, 1);
       if (nextQuotePos == -1)
       {
-        System.err.println(invalidFormat);
+        jalview.bin.Console.errPrintln(invalidFormat);
         return null;
       }
       firstField = descriptor.substring(1, nextQuotePos);
@@ -159,7 +159,7 @@ public class FeatureMatcher implements FeatureMatcherI
       int nextSpacePos = descriptor.indexOf(SPACE);
       if (nextSpacePos == -1)
       {
-        System.err.println(invalidFormat);
+        jalview.bin.Console.errPrintln(invalidFormat);
         return null;
       }
       firstField = descriptor.substring(0, nextSpacePos);
@@ -193,7 +193,7 @@ public class FeatureMatcher implements FeatureMatcherI
       cond = Condition.fromString(leftToParse);
       if (cond == null || cond.needsAPattern())
       {
-        System.err.println(invalidFormat);
+        jalview.bin.Console.errPrintln(invalidFormat);
         return null;
       }
     }
@@ -214,7 +214,7 @@ public class FeatureMatcher implements FeatureMatcherI
         else
         {
           // unbalanced quote
-          System.err.println(invalidFormat);
+          jalview.bin.Console.errPrintln(invalidFormat);
           return null;
         }
       }
index a5efe5d..eae3664 100644 (file)
@@ -93,7 +93,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI
         if (spacePos == -1)
         {
           // trailing junk after a match condition
-          System.err.println(invalid);
+          jalview.bin.Console.errPrintln(invalid);
           return null;
         }
         String conjunction = leftToParse.substring(0, spacePos);
@@ -109,7 +109,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI
         else
         {
           // not an AND or an OR - invalid
-          System.err.println(invalid);
+          jalview.bin.Console.errPrintln(invalid);
           return null;
         }
       }
@@ -123,7 +123,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI
         int closePos = leftToParse.indexOf(CLOSE_BRACKET);
         if (closePos == -1)
         {
-          System.err.println(invalid);
+          jalview.bin.Console.errPrintln(invalid);
           return null;
         }
         nextCondition = leftToParse.substring(1, closePos);
@@ -137,7 +137,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI
       FeatureMatcher fm = FeatureMatcher.fromString(nextCondition);
       if (fm == null)
       {
-        System.err.println(invalid);
+        jalview.bin.Console.errPrintln(invalid);
         return null;
       }
       try
@@ -154,7 +154,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI
       } catch (IllegalStateException e)
       {
         // thrown if OR and AND are mixed
-        System.err.println(invalid);
+        jalview.bin.Console.errPrintln(invalid);
         return null;
       }
 
index eb5688c..c19d782 100644 (file)
@@ -401,7 +401,7 @@ public class FeatureStore
       SequenceFeature sf = contactFeatureEnds.get(index);
       if (!sf.isContactFeature())
       {
-        System.err.println("Error! non-contact feature type " + sf.getType()
+        jalview.bin.Console.errPrintln("Error! non-contact feature type " + sf.getType()
                 + " in contact features list");
         index++;
         continue;
@@ -454,7 +454,7 @@ public class FeatureStore
       SequenceFeature sf = contactFeatureStarts.get(index);
       if (!sf.isContactFeature())
       {
-        System.err.println("Error! non-contact feature " + sf.toString()
+        jalview.bin.Console.errPrintln("Error! non-contact feature " + sf.toString()
                 + " in contact features list");
         index++;
         continue;
index 905fd8b..ed4474e 100644 (file)
@@ -88,7 +88,7 @@ public class SequenceFeatures implements SequenceFeaturesI
     String type = sf.getType();
     if (type == null)
     {
-      System.err.println("Feature type may not be null: " + sf.toString());
+      jalview.bin.Console.errPrintln("Feature type may not be null: " + sf.toString());
       return false;
     }
 
index 75a7154..391fd6f 100644 (file)
@@ -226,7 +226,7 @@ public class EnsemblGene extends EnsemblSeqProxy
         return true;
       } catch (NumberFormatException e)
       {
-        System.err.println("Bad integers in description " + description);
+        jalview.bin.Console.errPrintln("Bad integers in description " + description);
       }
     }
     return false;
index 0813ba8..e188986 100644 (file)
@@ -222,7 +222,7 @@ public class EnsemblLookup extends EnsemblRestClient
               ids, -1, MODE_MAP, null);
     } catch (IOException | ParseException e)
     {
-      System.err.println("Error parsing " + identifier + " lookup response "
+      jalview.bin.Console.errPrintln("Error parsing " + identifier + " lookup response "
               + e.getMessage());
       return null;
     }
index f2ab195..1fd9a23 100644 (file)
@@ -157,7 +157,7 @@ public class EnsemblMap extends EnsemblRestClient
       return (parseAssemblyMappingResponse(url));
     } catch (Throwable t)
     {
-      System.out.println("Error calling " + url + ": " + t.getMessage());
+      jalview.bin.Console.outPrintln("Error calling " + url + ": " + t.getMessage());
       return null;
     }
   }
@@ -265,7 +265,7 @@ public class EnsemblMap extends EnsemblRestClient
       return null;
     } catch (Throwable t)
     {
-      System.out.println("Error calling " + url + ": " + t.getMessage());
+      jalview.bin.Console.outPrintln("Error calling " + url + ": " + t.getMessage());
       return null;
     }
   }
@@ -342,7 +342,7 @@ public class EnsemblMap extends EnsemblRestClient
         String ass = mapped.get("assembly_name").toString();
         if (assembly != null && !assembly.equals(ass))
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "EnsemblMap found multiple assemblies - can't resolve");
           return null;
         }
@@ -350,7 +350,7 @@ public class EnsemblMap extends EnsemblRestClient
         String chr = mapped.get("seq_region_name").toString();
         if (chromosome != null && !chromosome.equals(chr))
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "EnsemblMap found multiple chromosomes - can't resolve");
           return null;
         }
index 4a5544e..540fc98 100644 (file)
@@ -211,7 +211,7 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
       return pingString != null;
     } catch (Throwable t)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error connecting to " + pingUrl + ": " + t.getMessage());
     } finally
     {
@@ -313,7 +313,7 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
        * note: a GET request for an invalid id returns an error code e.g. 415
        * but POST request returns 200 and an empty Fasta response 
        */
-      System.err.println("Response code " + responseCode);// + " for " + url);
+      jalview.bin.Console.errPrintln("Response code " + responseCode);// + " for " + url);
       return null;
     }
 
@@ -338,7 +338,7 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
   protected HttpURLConnection tryConnection(URL url, List<String> ids,
           int readTimeout) throws IOException, ProtocolException
   {
-    // System.out.println(System.currentTimeMillis() + " " + url);
+    // jalview.bin.Console.outPrintln(System.currentTimeMillis() + " " + url);
 
     HttpURLConnection connection = (HttpURLConnection) url.openConnection();
 
@@ -387,14 +387,14 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
         int retrySecs = Integer.valueOf(retryDelay);
         if (retrySecs > 0 && retrySecs < 10)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Ensembl REST service rate limit exceeded, waiting "
                           + retryDelay + " seconds before retrying");
           Thread.sleep(1000 * retrySecs);
         }
       } catch (NumberFormatException | InterruptedException e)
       {
-        System.err.println("Error handling Retry-After: " + e.getMessage());
+        jalview.bin.Console.errPrintln("Error handling Retry-After: " + e.getMessage());
       }
     }
   }
@@ -566,7 +566,7 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
         }
       } catch (NumberFormatException e)
       {
-        System.err.println("Error in REST version: " + e.toString());
+        jalview.bin.Console.errPrintln("Error in REST version: " + e.toString());
       }
 
       /*
@@ -578,14 +578,14 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
               expected) == 1;
       if (laterVersion)
       {
-        System.err.println(String.format(
+        jalview.bin.Console.errPrintln(String.format(
                 "EnsemblRestClient expected %s REST version %s but found %s, see %s",
                 getDbSource(), expected, version, REST_CHANGE_LOG));
       }
       info.restVersion = version;
     } catch (Throwable t)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error checking Ensembl REST version: " + t.getMessage());
     }
   }
@@ -617,7 +617,7 @@ abstract class EnsemblRestClient extends EnsemblSequenceFetcher
       domainData.get(getDomain()).dataVersion = versions.get(0).toString();
     } catch (Throwable e)
     {// could be IOException | ParseException e) {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error checking Ensembl data version: " + e.getMessage());
     }
   }
index 56eda5e..949c52e 100644 (file)
@@ -155,7 +155,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
         String msg = "Aborting ID retrieval after " + v
                 + " chunks. Unexpected problem (" + r.getLocalizedMessage()
                 + ")";
-        System.err.println(msg);
+        jalview.bin.Console.errPrintln(msg);
         r.printStackTrace();
         break;
       }
@@ -240,7 +240,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
       }
     } catch (IOException e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error transferring Ensembl features: " + e.getMessage());
     }
     // Platform.timeCheck("ESP.addfeat done", Platform.TIME_MARK);
@@ -265,12 +265,12 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
     String accId = querySeq.getName();
     try
     {
-      System.out.println("Adding protein product for " + accId);
+      jalview.bin.Console.outPrintln("Adding protein product for " + accId);
       AlignmentI protein = new EnsemblProtein(getDomain())
               .getSequenceRecords(accId);
       if (protein == null || protein.getHeight() == 0)
       {
-        System.out.println("No protein product found for " + accId);
+        jalview.bin.Console.outPrintln("No protein product found for " + accId);
         return;
       }
       SequenceI proteinSeq = protein.getSequenceAt(0);
@@ -382,7 +382,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
       seq.addDBRef(xrefs.get(i));
     }
 
-    // System.out.println("primaries are " + seq.getPrimaryDBRefs().toString());
+    // jalview.bin.Console.outPrintln("primaries are " + seq.getPrimaryDBRefs().toString());
     /*
      * and add a reference to itself
      */
@@ -430,7 +430,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
 
     if (seqs.size() != ids.size())
     {
-      System.out.println(String.format(
+      jalview.bin.Console.outPrintln(String.format(
               "Only retrieved %d sequences for %d query strings",
               seqs.size(), ids.size()));
     }
@@ -508,7 +508,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
       result.add(sequence);
     } catch (ParseException | IOException e)
     {
-      System.err.println("Error processing JSON response: " + e.toString());
+      jalview.bin.Console.errPrintln("Error processing JSON response: " + e.toString());
       // ignore
     }
     // Platform.timeCheck("ENS seqproxy2", Platform.TIME_MARK);
@@ -659,7 +659,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
 
     if (regions.isEmpty())
     {
-      System.out.println("Failed to identify target sequence for " + accId
+      jalview.bin.Console.outPrintln("Failed to identify target sequence for " + accId
               + " from genomic features");
       return null;
     }
@@ -829,7 +829,7 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient
 
     boolean result = transferFeatures(sfs, targetSequence, mapping,
             accessionId);
-    // System.out.println("transferFeatures (" + (sfs.size()) + " --> "
+    // jalview.bin.Console.outPrintln("transferFeatures (" + (sfs.size()) + " --> "
     // + targetSequence.getFeatures().getFeatureCount(true) + ") to "
     // + targetSequence.getName() + " took "
     // + (System.currentTimeMillis() - start) + "ms");
index 9a985b6..8cce87a 100644 (file)
@@ -261,7 +261,7 @@ public class HtsContigDb
   {
     if (!isValid() || !refFile.isIndexed())
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Cannot read contig as file is invalid or not indexed");
       return null;
     }
index 21a19ae..9d49a93 100644 (file)
@@ -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;
@@ -163,28 +165,49 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
 
   public void createImage(String file, String type, int quality)
   {
-    System.out.println("JMOL CREATE IMAGE");
+    jalview.bin.Console.outPrintln("JMOL CREATE IMAGE");
   }
 
   @Override
   public String createImage(String fileName, String type,
           Object textOrBytes, int quality)
   {
-    System.out.println("JMOL CREATE IMAGE");
+    jalview.bin.Console.outPrintln("JMOL CREATE IMAGE");
     return null;
   }
 
   @Override
   public String eval(String strEval)
   {
-    // System.out.println(strEval);
+    // jalview.bin.Console.outPrintln(strEval);
     // "# 'eval' is implemented only for the applet.";
     return null;
   }
 
   // End StructureListener
   // //////////////////////////
-
+  
+  ////////////////////////////
+  // HETATM get
+  //
+  
+  @Override
+  public Map<String,String> getHetatmNames()
+  {
+    HashMap<String,String> hetlist=new HashMap();
+    for (int mc=0;mc<jmolViewer.ms.mc; mc++)
+    {
+      Map<String,String> hets = jmolViewer.ms.getHeteroList(mc);
+      if (hets!=null)
+      {
+        hetlist.putAll(hets);
+      }
+    }
+    return hetlist;
+  }
+  //
+  ////////////////////////////
+  
   @Override
   public float[][] functionXY(String functionName, int x, int y)
   {
@@ -267,16 +290,30 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
   {
     if (atoms != null)
     {
-      boolean useScriptWait = atoms.size() > 1;
       if (resetLastRes.length() > 0)
       {
-        jmolScript(resetLastRes.toString(), useScriptWait);
+        jmolScript(resetLastRes.toString());
         resetLastRes.setLength(0);
       }
+      StringBuilder highlightCommands=null;
       for (AtomSpec atom : atoms)
       {
-        highlightAtom(atom.getAtomIndex(), atom.getPdbResNum(),
-                atom.getChain(), atom.getPdbFile(), useScriptWait);
+        StringBuilder thisAtom = highlightAtom(atom.getAtomIndex(), atom.getPdbResNum(),
+                atom.getChain(), atom.getPdbFile());
+        if (thisAtom!=null) {
+          if (highlightCommands==null)
+          {
+            highlightCommands=thisAtom;                  
+          } else {
+            highlightCommands.append(thisAtom);
+          }
+        }
+      }
+      if (highlightCommands!=null)
+      {
+        jmolHistory(false);
+        jmolScript(highlightCommands.toString());
+        jmolHistory(true);
       }
       // Highlight distances between atoms with a 'measure' command - not yet
       // working
@@ -306,17 +343,15 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
   }
 
   // jmol/ssm only
-  public void highlightAtom(int atomIndex, int pdbResNum, String chain,
-          String pdbfile, boolean useScriptWait)
+  private StringBuilder highlightAtom(int atomIndex, int pdbResNum, String chain,
+          String pdbfile)
   {
     String modelId = getModelIdForFile(pdbfile);
     if (modelId.isEmpty())
     {
-      return;
+      return null;
     }
 
-    jmolHistory(false, useScriptWait);
-
     StringBuilder selection = new StringBuilder(32);
     StringBuilder cmd = new StringBuilder(64);
     selection.append("select ").append(String.valueOf(pdbResNum));
@@ -333,8 +368,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
     resetLastRes.append(selection).append(";wireframe 0;").append(selection)
             .append(" and not hetero; spacefill 0;");
 
-    jmolScript(cmd.toString(), useScriptWait);
-    jmolHistory(true, useScriptWait);
+    return cmd;
   }
 
   private boolean debug = true;
@@ -476,7 +510,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
     lastMessage = strInfo;
     if (data != null)
     {
-      System.err.println("Ignoring additional hover info: " + data
+      jalview.bin.Console.errPrintln("Ignoring additional hover info: " + data
               + " (other info: '" + strInfo + "' pos " + atomIndex + ")");
     }
     mouseOverStructure(atomIndex, strInfo);
@@ -497,7 +531,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
      */
     if (strData != null)
     {
-      System.err.println("Ignoring additional pick data string " + strData);
+      jalview.bin.Console.errPrintln("Ignoring additional pick data string " + strData);
     }
     int chainSeparator = strInfo.indexOf(":");
     int p = 0;
@@ -599,7 +633,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
                 (data == null) ? ((String) null) : (String) data[1]);
         break;
       case ERROR:
-        // System.err.println("Ignoring error callback.");
+        // jalview.bin.Console.errPrintln("Ignoring error callback.");
         break;
       case SYNC:
       case RESIZE:
@@ -609,13 +643,13 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
 
       case CLICK:
       default:
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Unhandled callback " + type + " " + data[1].toString());
         break;
       }
     } catch (Exception e)
     {
-      System.err.println("Squashed Jmol callback handler error:");
+      jalview.bin.Console.errPrintln("Squashed Jmol callback handler error:");
       e.printStackTrace();
     }
   }
@@ -864,7 +898,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
   public void setCallbackFunction(String callbackType,
           String callbackFunction)
   {
-    System.err.println("Ignoring set-callback request to associate "
+    jalview.bin.Console.errPrintln("Ignoring set-callback request to associate "
             + callbackType + " with function " + callbackFunction);
 
   }
@@ -938,7 +972,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
           String buttonsToShow)
   {
 
-    System.err.println("Allocating Jmol Viewer: " + commandOptions);
+    jalview.bin.Console.errPrintln("Allocating Jmol Viewer: " + commandOptions);
 
     if (commandOptions == null)
     {
@@ -956,7 +990,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel
       console = createJmolConsole(consolePanel, buttonsToShow);
     } catch (Throwable e)
     {
-      System.err.println("Could not create Jmol application console. "
+      jalview.bin.Console.errPrintln("Could not create Jmol application console. "
               + e.getMessage());
       e.printStackTrace();
     }
index 19d64f0..106d458 100644 (file)
@@ -316,7 +316,38 @@ public class JmolCommands extends StructureCommandsBase
     return new StructureCommand(
             "load FILES \"" + Platform.escapeBackslashes(file) + "\"");
   }
+  @Override
+  public StructureCommandI restoreSession(String filePath)
+  {
+    return new StructureCommand(
+            "restore STATE \"" + Platform.escapeBackslashes(filePath) + "\"");
+  }
 
+  @Override
+  public List<StructureCommandI> showHetatms(List<String> 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
index 57b406e..0ca2ba8 100644 (file)
@@ -338,7 +338,7 @@ public class JmolParser extends StructureFile implements JmolStatusListener
       }
     } catch (OutOfMemoryError er)
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "OUT OF MEMORY LOADING TRANSFORMING JMOL MODEL TO JALVIEW MODEL");
       throw new IOException(MessageManager
               .getString("exception.outofmemory_loading_mmcif_file"));
@@ -391,7 +391,7 @@ public class JmolParser extends StructureFile implements JmolStatusListener
           org.jmol.modelset.Atom prevAtom,
           HashMap<String, org.jmol.modelset.Atom> chainTerMap)
   {
-    // System.out.println("Atom: " + curAtom.getAtomNumber()
+    // jalview.bin.Console.outPrintln("Atom: " + curAtom.getAtomNumber()
     // + " Last atom index " + curAtom.group.lastAtomIndex);
     if (chainTerMap == null || prevAtom == null)
     {
index de1d90c..3817ee9 100644 (file)
@@ -229,7 +229,7 @@ class RvalsIterator implements Iterator, AutoCloseable
 
     if (sval == null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "DEVELOPER WARNING: Annotate3d didn't return a '2D' tag in its response. Consider checking output of server. Response was :"
                       + val.toString());
 
index 7dfdb0c..ddc8d84 100644 (file)
@@ -158,7 +158,7 @@ public class PymolManager
           boolean getReply)
   {
     String postBody = getPostRequest(command);
-    // System.out.println(postBody);// debug
+    // jalview.bin.Console.outPrintln(postBody);// debug
     String rpcUrl = "http://127.0.0.1:" + this.pymolXmlRpcPort;
     PrintWriter out = null;
     BufferedReader in = null;
index 40b0ff0..af31b78 100644 (file)
@@ -126,12 +126,12 @@ public class ChimeraListener extends AbstractRequestHandler
       }
       else if (message.startsWith(MODEL_CHANGED))
       {
-        System.err.println(message);
+        jalview.bin.Console.errPrintln(message);
         processModelChanged(message.substring(MODEL_CHANGED.length()));
       }
       else
       {
-        System.err.println("Unexpected chimeraNotification: " + message);
+        jalview.bin.Console.errPrintln("Unexpected chimeraNotification: " + message);
       }
     }
   }
@@ -143,7 +143,7 @@ public class ChimeraListener extends AbstractRequestHandler
    */
   protected void processModelChanged(String message)
   {
-    // System.out.println(message + " (not implemented in Jalview)");
+    // jalview.bin.Console.outPrintln(message + " (not implemented in Jalview)");
   }
 
   /**
index aebfede..a292e88 100644 (file)
@@ -207,7 +207,7 @@ public abstract class JalviewChimeraBinding extends AAStructureBindingModel
       startListening(chimeraListener.getUri());
     } catch (BindException e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Failed to start Chimera listener: " + e.getMessage());
     }
   }
@@ -568,7 +568,7 @@ public abstract class JalviewChimeraBinding extends AAStructureBindingModel
 
   private void log(String message)
   {
-    System.err.println("## Chimera log: " + message);
+    jalview.bin.Console.errPrintln("## Chimera log: " + message);
   }
 
   /**
@@ -627,7 +627,7 @@ public abstract class JalviewChimeraBinding extends AAStructureBindingModel
       executeCommand(false, null, command);
     } catch (IOException e)
     {
-      System.err.println("Sending commands to Chimera via file failed with "
+      jalview.bin.Console.errPrintln("Sending commands to Chimera via file failed with "
               + e.getMessage());
     }
   }
index 0971235..86b8c7d 100644 (file)
@@ -94,7 +94,7 @@ public class FTSDataColumnPreferences extends JScrollPane
     int x = 0;
     for (FTSDataColumnI field : allFTSDataColumns)
     {
-      // System.out.println("allFTSDataColumns==" + allFTSDataColumns);
+      // jalview.bin.Console.outPrintln("allFTSDataColumns==" + allFTSDataColumns);
       if (field.getName().equalsIgnoreCase("all"))
       {
         continue;
@@ -106,7 +106,7 @@ public class FTSDataColumnPreferences extends JScrollPane
         data[x++] = new Object[] { ftsRestClient
                 .getAllDefaultDisplayedFTSDataColumns().contains(field),
             field.getName(), field.getGroup() };
-        // System.out.println(" PUIS " + field.getName() + " ET AUSSI " +
+        // jalview.bin.Console.outPrintln(" PUIS " + field.getName() + " ET AUSSI " +
         // field.getGroup() + "X = " + x);
         break;
       case STRUCTURE_CHOOSER:
index 7e95dd2..a631902 100644 (file)
@@ -118,7 +118,7 @@ public class AlphafoldRestClient
           } catch (Exception e)
           {
             e.printStackTrace();
-            System.out.println("offending value:" + fieldData);
+            jalview.bin.Console.outPrintln("offending value:" + fieldData);
           }
         }
       }
index 796bc0e..5619075 100644 (file)
@@ -175,7 +175,7 @@ public class PDBFTSRestClient extends FTSRestClient
 
       URI uri = webResource.getURI();
 
-      System.out.println(uri);
+      jalview.bin.Console.outPrintln(uri);
       ClientResponse clientResponse = null;
       int responseStatus = -1;
       // Get the JSON string from the response object or directly from the
@@ -183,7 +183,7 @@ public class PDBFTSRestClient extends FTSRestClient
       Map<String, Object> jsonObj = null;
       String responseString = null;
 
-      System.out.println("query >>>>>>> " + pdbRestRequest.toString());
+      jalview.bin.Console.outPrintln("query >>>>>>> " + pdbRestRequest.toString());
 
       if (!isMocked())
       {
@@ -413,10 +413,10 @@ public class PDBFTSRestClient extends FTSRestClient
 
     for (FTSDataColumnI field : diplayFields)
     {
-      // System.out.println("Field " + field);
+      // jalview.bin.Console.outPrintln("Field " + field);
       String fieldData = (pdbJsonDoc.get(field.getCode()) == null) ? ""
               : pdbJsonDoc.get(field.getCode()).toString();
-      // System.out.println("Field Data : " + fieldData);
+      // jalview.bin.Console.outPrintln("Field Data : " + fieldData);
       if (field.isPrimaryKeyColumn())
       {
         primaryKey = fieldData;
@@ -440,7 +440,7 @@ public class PDBFTSRestClient extends FTSRestClient
         } catch (Exception e)
         {
           e.printStackTrace();
-          System.out.println("offending value:" + fieldData);
+          jalview.bin.Console.outPrintln("offending value:" + fieldData);
         }
       }
     }
index 3045d3d..4e1b2b0 100644 (file)
@@ -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);
+  }
 
 }
index 253de42..dfb39cb 100644 (file)
@@ -277,7 +277,7 @@ public class TDBeaconsFTSPanel extends GFTSPanel
   @Override
   protected void showHelp()
   {
-    System.out.println("No help implemented yet.");
+    jalview.bin.Console.outPrintln("No help implemented yet.");
 
   }
 
index d7f534e..c275bda 100644 (file)
@@ -101,7 +101,7 @@ public class TDBeaconsFTSRestClient extends FTSRestClient
       webResource = client.resource(DEFAULT_THREEDBEACONS_DOMAIN + query);
 
       URI uri = webResource.getURI();
-      System.out.println(uri.toString());
+      jalview.bin.Console.outPrintln(uri.toString());
 
       // Execute the REST request
       ClientResponse clientResponse;
@@ -269,7 +269,7 @@ public class TDBeaconsFTSRestClient extends FTSRestClient
       String fieldData = (tdbJsonStructure.get(field.getCode()) == null)
               ? " "
               : tdbJsonStructure.get(field.getCode()).toString();
-      // System.out.println("Field : " + field + " Data : " + fieldData);
+      // jalview.bin.Console.outPrintln("Field : " + field + " Data : " + fieldData);
       if (field.isPrimaryKeyColumn())
       {
         primaryKey = fieldData;
@@ -293,7 +293,7 @@ public class TDBeaconsFTSRestClient extends FTSRestClient
         } catch (Exception e)
         {
           // e.printStackTrace();
-          System.out.println("offending value:" + fieldData + fieldData);
+          jalview.bin.Console.outPrintln("offending value:" + fieldData + fieldData);
         }
       }
     }
index 1827293..df48c0d 100644 (file)
@@ -219,7 +219,7 @@ public class UniProtFTSRestClient extends FTSRestClient
               .getEntity(String.class);
       // Make redundant objects eligible for garbage collection to conserve
       // memory
-      // System.out.println(">>>>> response : "
+      // jalview.bin.Console.outPrintln(">>>>> response : "
       // + uniProtTabDelimittedResponseString);
       if (clientResponse.getStatus() != 200)
       {
@@ -307,7 +307,7 @@ public class UniProtFTSRestClient extends FTSRestClient
           firstRow = false;
           continue;
         }
-        // System.out.println(dataRow);
+        // jalview.bin.Console.outPrintln(dataRow);
         result.add(getFTSData(dataRow, uniprotRestRequest));
       }
       searchResult.setNumberOfItemsFound(xTotalResults);
@@ -389,7 +389,7 @@ public class UniProtFTSRestClient extends FTSRestClient
           } catch (Exception e)
           {
             e.printStackTrace();
-            System.out.println("offending value:" + fieldData);
+            jalview.bin.Console.outPrintln("offending value:" + fieldData);
           }
         }
       } catch (Exception e)
index c776d82..6ca21c7 100644 (file)
@@ -32,6 +32,7 @@ import javax.swing.JPanel;
 
 import jalview.api.AlignExportSettingsI;
 import jalview.api.AlignViewportI;
+import jalview.bin.Jalview;
 import jalview.io.FileFormatI;
 import jalview.util.MessageManager;
 
@@ -72,12 +73,9 @@ public class AlignExportOptions extends JPanel
   public static boolean isNeeded(AlignViewportI viewport,
           FileFormatI format)
   {
-    if (viewport.hasHiddenColumns() || viewport.hasHiddenRows()
-            || format.isComplexAlignFile())
-    {
-      return true;
-    }
-    return false;
+    return !Jalview.getInstance().isHeadlessMode()
+            && (viewport.hasHiddenColumns() || viewport.hasHiddenRows()
+                    || format.isComplexAlignFile());
   }
 
   /**
index 49bd4e9..4f13a78 100644 (file)
@@ -49,6 +49,7 @@ import java.beans.PropertyChangeEvent;
 import java.io.File;
 import java.io.FileWriter;
 import java.io.IOException;
+import java.io.OutputStreamWriter;
 import java.io.PrintWriter;
 import java.net.URL;
 import java.util.ArrayList;
@@ -94,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;
@@ -157,7 +159,6 @@ import jalview.viewmodel.AlignmentViewport;
 import jalview.viewmodel.ViewportRanges;
 import jalview.ws.DBRefFetcher;
 import jalview.ws.DBRefFetcher.FetchFinishedListenerI;
-import jalview.ws.datamodel.alphafold.PAEContactMatrix;
 import jalview.ws.jws1.Discoverer;
 import jalview.ws.jws2.Jws2Discoverer;
 import jalview.ws.jws2.jabaws2.Jws2Instance;
@@ -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);
       }
     });
 
@@ -624,12 +625,12 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         // if (viewport.cursorMode)
         // {
         // alignPanel.seqPanel.insertNucAtCursor(false,"A");
-        // //System.out.println("A");
+        // //jalview.bin.Console.outPrintln("A");
         // }
         // break;
         /*
          * case KeyEvent.VK_CLOSE_BRACKET: if (viewport.cursorMode) {
-         * System.out.println("closing bracket"); } break;
+         * jalview.bin.Console.outPrintln("closing bracket"); } break;
          */
         case KeyEvent.VK_DELETE:
         case KeyEvent.VK_BACK_SPACE:
@@ -830,7 +831,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
               @Override
               public void propertyChange(PropertyChangeEvent evt)
               {
-                // // System.out.println("Discoverer property change.");
+                // // jalview.bin.Console.outPrintln("Discoverer property
+                // change.");
                 // if (evt.getPropertyName().equals("services"))
                 {
                   SwingUtilities.invokeLater(new Runnable()
@@ -839,7 +841,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                     @Override
                     public void run()
                     {
-                      System.err.println(
+                      jalview.bin.Console.errPrintln(
                               "Rebuild WS Menu for service change");
                       BuildWebServiceMenu();
                     }
@@ -854,7 +856,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       public void internalFrameClosed(
               javax.swing.event.InternalFrameEvent evt)
       {
-        // System.out.println("deregistering discoverer listener");
+        // jalview.bin.Console.outPrintln("deregistering discoverer listener");
         Desktop.instance.removeJalviewPropertyChangeListener("services",
                 thisListener);
         closeMenuItem_actionPerformed(true);
@@ -1251,8 +1253,17 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
    */
   public void saveAlignment(String file, FileFormatI format)
   {
+    saveAlignment(file, format, false, false);
+  }
+
+  public void saveAlignment(String file, FileFormatI format, boolean stdout,
+          boolean forceBackup)
+  {
     lastSaveSuccessful = true;
-    lastFilenameSaved = file;
+    if (!stdout)
+    {
+      lastFilenameSaved = file;
+    }
     lastFormatSaved = format;
 
     if (FileFormat.Jalview.equals(format))
@@ -1263,6 +1274,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         shortName = shortName
                 .substring(shortName.lastIndexOf(File.separatorChar) + 1);
       }
+      // TODO deal with stdout=true
       lastSaveSuccessful = new Jalview2XML().saveAlignment(this, file,
               shortName);
 
@@ -1298,7 +1310,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       else
       {
         // create backupfiles object and get new temp filename destination
-        boolean doBackup = BackupFiles.getEnabled();
+        boolean doBackup = forceBackup
+                || (BackupFiles.getEnabled() && !stdout);
         BackupFiles backupfiles = null;
         if (doBackup)
         {
@@ -1310,7 +1323,9 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           String tempFilePath = doBackup ? backupfiles.getTempFilePath()
                   : file;
           Console.trace("ALIGNFRAME setting PrintWriter");
-          PrintWriter out = new PrintWriter(new FileWriter(tempFilePath));
+          PrintWriter out = stdout
+                  ? new PrintWriter(new OutputStreamWriter(System.out))
+                  : new PrintWriter(new FileWriter(tempFilePath));
 
           if (backupfiles != null)
           {
@@ -1319,13 +1334,28 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           }
 
           out.print(output);
-          Console.trace("ALIGNFRAME about to close file");
-          out.close();
-          Console.trace("ALIGNFRAME closed file");
-          AlignFrame.this.setTitle(file);
-          statusBar.setText(MessageManager.formatMessage(
-                  "label.successfully_saved_to_file_in_format", new Object[]
-                  { fileName, format.getName() }));
+          out.flush();
+          if (!stdout)
+          {
+            Console.trace("ALIGNFRAME about to close file");
+            out.close();
+            Console.trace("ALIGNFRAME closed file");
+          }
+          AlignFrame.this.setTitle(stdout ? "STDOUT" : file);
+          if (stdout)
+          {
+            statusBar.setText(MessageManager.formatMessage(
+                    "label.successfully_printed_to_stdout_in_format",
+                    new Object[]
+                    { format.getName() }));
+          }
+          else
+          {
+            statusBar.setText(MessageManager.formatMessage(
+                    "label.successfully_saved_to_file_in_format",
+                    new Object[]
+                    { fileName, format.getName() }));
+          }
           lastSaveSuccessful = true;
         } catch (IOException e)
         {
@@ -1456,9 +1486,11 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   protected void htmlMenuItem_actionPerformed(ActionEvent e)
   {
     HtmlSvgOutput htmlSVG = new HtmlSvgOutput(alignPanel);
-    try {
+    try
+    {
       htmlSVG.exportHTML(null);
-    } catch (ImageOutputException x) {
+    } catch (ImageOutputException x)
+    {
       // report problem to console and raise dialog
     }
   }
@@ -1467,51 +1499,64 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   public void bioJSMenuItem_actionPerformed(ActionEvent e)
   {
     BioJsHTMLOutput bjs = new BioJsHTMLOutput(alignPanel);
-    try {
-    bjs.exportHTML(null);
-  } catch (ImageOutputException x) {
-    // report problem to console and raise dialog
-  }
+    try
+    {
+      bjs.exportHTML(null);
+    } catch (ImageOutputException x)
+    {
+      // report problem to console and raise dialog
+    }
   }
 
   public void createImageMap(File file, String image)
   {
-    try {
-    alignPanel.makePNGImageMap(file, image);
-    } catch (ImageOutputException x) {
+    try
+    {
+      alignPanel.makePNGImageMap(file, image);
+    } catch (ImageOutputException x)
+    {
       // report problem to console and raise dialog
     }
   }
 
   @Override
-  public void createPNG_actionPerformed(ActionEvent e) {
-    try{
+  public void createPNG_actionPerformed(ActionEvent e)
+  {
+    try
+    {
       createPNG(null);
     } catch (ImageOutputException ioex)
     {
       // raise dialog, and report via console
     }
   }
+
   @Override
-  public void createEPS_actionPerformed(ActionEvent e) {
-    try{
+  public void createEPS_actionPerformed(ActionEvent e)
+  {
+    try
+    {
       createEPS(null);
     } catch (ImageOutputException ioex)
     {
       // raise dialog, and report via console
     }
-    
+
   }
+
   @Override
-  public void createSVG_actionPerformed(ActionEvent e) {
-    try{
+  public void createSVG_actionPerformed(ActionEvent e)
+  {
+    try
+    {
       createSVG(null);
     } catch (ImageOutputException ioex)
     {
       // raise dialog, and report via console
     }
-    
+
   }
+
   /**
    * Creates a PNG image of the alignment and writes it to the given file. If
    * the file is null, the user is prompted to choose a file.
@@ -1520,10 +1565,11 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
    */
   public void createPNG(File f) throws ImageOutputException
   {
-    createPNG(f, null, BitmapImageSizing.nullBitmapImageSizing());
+    createPNG(f, null, BitmapImageSizing.defaultBitmapImageSizing());
   }
 
-  public void createPNG(File f, String renderer, BitmapImageSizing userBis) throws ImageOutputException
+  public void createPNG(File f, String renderer, BitmapImageSizing userBis)
+          throws ImageOutputException
   {
     alignPanel.makeAlignmentImage(TYPE.PNG, f, renderer, userBis);
   }
@@ -1534,7 +1580,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
    * 
    * @param f
    */
-  public void createEPS(File f)  throws ImageOutputException
+  public void createEPS(File f) throws ImageOutputException
   {
     createEPS(f, null);
   }
@@ -1550,7 +1596,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
    * 
    * @param f
    */
-  public void createSVG(File f)  throws ImageOutputException
+  public void createSVG(File f) throws ImageOutputException
   {
     createSVG(f, null);
   }
@@ -1626,6 +1672,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       closeAllTabs = true;
     }
 
+    Desktop.closeModal(this);
+
     try
     {
       if (alignPanels != null)
@@ -1655,6 +1703,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           featureSettings.close();
           featureSettings = null;
         }
+
         /*
          * this will raise an INTERNAL_FRAME_CLOSED event and this method will
          * be called recursively, with the frame now in 'closed' state
@@ -1748,7 +1797,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
    * 
    * @return alignment objects for all views
    */
-  AlignmentI[] getViewAlignments()
+  public AlignmentI[] getViewAlignments()
   {
     if (alignPanels != null)
     {
@@ -2341,12 +2390,14 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
             // annotation was duplicated earlier
             alignment.addAnnotation(sequences[i].getAnnotation()[a]);
             // take care of contact matrix too
-            ContactMatrixI cm=sequences[i].getContactMatrixFor(sequences[i].getAnnotation()[a]);
-            if (cm!=null)
+            ContactMatrixI cm = sequences[i]
+                    .getContactMatrixFor(sequences[i].getAnnotation()[a]);
+            if (cm != null)
             {
-              alignment.addContactListFor(sequences[i].getAnnotation()[a], cm);
+              alignment.addContactListFor(sequences[i].getAnnotation()[a],
+                      cm);
             }
-            
+
             alignment.setAnnotationIndex(sequences[i].getAnnotation()[a],
                     a);
           }
@@ -2454,7 +2505,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     } catch (Exception ex)
     {
       ex.printStackTrace();
-      System.out.println("Exception whilst pasting: " + ex);
+      jalview.bin.Console.outPrintln("Exception whilst pasting: " + ex);
       // could be anything being pasted in here
     }
 
@@ -2502,7 +2553,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     } catch (Exception ex)
     {
       ex.printStackTrace();
-      System.out.println("Exception whilst pasting: " + ex);
+      jalview.bin.Console.outPrintln("Exception whilst pasting: " + ex);
       // could be anything being pasted in here
     } catch (OutOfMemoryError oom)
     {
@@ -3138,11 +3189,20 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   @Override
   public void wrapMenuItem_actionPerformed(ActionEvent e)
   {
-    scaleAbove.setVisible(wrapMenuItem.isSelected());
-    scaleLeft.setVisible(wrapMenuItem.isSelected());
-    scaleRight.setVisible(wrapMenuItem.isSelected());
-    viewport.setWrapAlignment(wrapMenuItem.isSelected());
+    setWrapFormat(wrapMenuItem.isSelected(), false);
+  }
+
+  public void setWrapFormat(boolean b, boolean setMenuItem)
+  {
+    scaleAbove.setVisible(b);
+    scaleLeft.setVisible(b);
+    scaleRight.setVisible(b);
+    viewport.setWrapAlignment(b);
     alignPanel.updateLayout();
+    if (setMenuItem)
+    {
+      wrapMenuItem.setSelected(b);
+    }
   }
 
   @Override
@@ -3480,7 +3540,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     }
 
     JInternalFrame frame = new JInternalFrame();
-
+    frame.setFrameIcon(null);
     frame.getContentPane().add(new JScrollPane(pane));
 
     Desktop.addInternalFrame(frame, MessageManager
@@ -3508,12 +3568,12 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       return alignPanel.overviewPanel;
     }
     JInternalFrame frame = new JInternalFrame();
+    frame.setFrameIcon(null);
     final OverviewPanel overview = new OverviewPanel(alignPanel, frame,
             showHidden);
     frame.setContentPane(overview);
     Desktop.addInternalFrame(frame, "", true, frame.getWidth(),
             frame.getHeight(), true, true);
-    frame.setFrameIcon(null);
     frame.pack();
     frame.setLayer(JLayeredPane.PALETTE_LAYER);
     final AlignmentPanel thePanel = this.alignPanel;
@@ -3787,6 +3847,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     else
     {
       JInternalFrame frame = new JInternalFrame();
+      frame.setFrameIcon(null);
       frame.setContentPane(new PairwiseAlignPanel(viewport));
       Desktop.addInternalFrame(frame,
               MessageManager.getString("action.pairwise_alignment"), 600,
@@ -4239,8 +4300,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     return tp;
   }
 
-  public void showContactMapTree(AlignmentAnnotation aa,
-          ContactMatrixI cm)
+  public void showContactMapTree(AlignmentAnnotation aa, ContactMatrixI cm)
   {
     int x = 4, y = 5;
     int w = 400, h = 500;
@@ -4249,8 +4309,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     {
       NewickFile fin = new NewickFile(
               new FileParse(cm.getNewick(), DataSourceType.PASTE));
-      String title = aa.label + " "
-              + cm.getTreeMethod() + " tree" + (aa.sequenceRef != null
+      String title = aa.label + " " + cm.getTreeMethod() + " tree"
+              + (aa.sequenceRef != null
                       ? (" for " + aa.sequenceRef.getDisplayId(false))
                       : "");
 
@@ -4303,7 +4363,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     {
       try
       {
-        System.err.println("Waiting for building menu to finish.");
+        jalview.bin.Console
+                .errPrintln("Waiting for building menu to finish.");
         Thread.sleep(10);
       } catch (Exception e)
       {
@@ -4319,7 +4380,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         final List<JMenuItem> legacyItems = new ArrayList<>();
         try
         {
-          // System.err.println("Building ws menu again "
+          // jalview.bin.Console.errPrintln("Building ws menu again "
           // + Thread.currentThread());
           // TODO: add support for context dependent disabling of services based
           // on
@@ -4757,7 +4818,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
              * Object[] { String,SequenceI}
              */
             ArrayList<Object[]> filesmatched = new ArrayList<>();
-            ArrayList<Object> filesnotmatched = new ArrayList<>();
+            ArrayList<Object[]> filesnotmatched = new ArrayList<>();
             for (int i = 0; i < files.size(); i++)
             {
               // BH 2018
@@ -4803,9 +4864,9 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                   }
                   mtch = idm.findAllIdMatches(pdbfn);
                 }
+                FileFormatI type=null;
                 if (mtch != null)
                 {
-                  FileFormatI type;
                   try
                   {
                     type = new IdentifyFile().identify(file, protocol);
@@ -4821,7 +4882,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                 }
                 // File wasn't named like one of the sequences or wasn't a PDB
                 // file.
-                filesnotmatched.add(file);
+                filesnotmatched.add(new Object[] { file, protocol, type});
               }
             }
             int assocfiles = 0;
@@ -4857,7 +4918,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                                     Desktop.instance);
                     if (pe != null)
                     {
-                      System.err.println("Associated file : "
+                      jalview.bin.Console.errPrintln("Associated file : "
                               + (fm[0].toString()) + " with "
                               + toassoc.getDisplayId(true));
                       assocfiles++;
@@ -4875,7 +4936,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                  */
                 for (Object[] o : filesmatched)
                 {
-                  filesnotmatched.add(o[0]);
+                  filesnotmatched.add(new Object[] { o[0], o[1]});
                 }
               }
             }
@@ -4897,9 +4958,9 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
               {
                 return;
               }
-              for (Object fn : filesnotmatched)
+              for (Object[] fn : filesnotmatched)
               {
-                loadJalviewDataFile(fn, null, null, null);
+                loadJalviewDataFile(fn[0], (DataSourceType) fn[1], (FileFormatI)fn[2], null);
               }
 
             }
@@ -4995,7 +5056,19 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           {
             format = new IdentifyFile().identify(file, sourceType);
           }
-          if (FileFormat.ScoreMatrix == format)
+          if (FileFormat.FeatureSettings == format)
+          {
+            if (featureSettings != null)
+            {
+              featureSettings.load(file, sourceType);
+            }
+            else
+            {
+              FeatureSettings.loadFeatureSettingsFile(getFeatureRenderer(),
+                      fileObject, sourceType);
+            }
+          }
+          else if (FileFormat.ScoreMatrix == format)
           {
             ScoreMatrixFile sm = new ScoreMatrixFile(
                     new FileParse(file, sourceType));
@@ -5781,6 +5854,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       }
     }
     alignPanel.validateAnnotationDimensions(true);
+    // TODO this triggers relayout of annotation panel - otherwise annotation label height is different to panel height
+    alignPanel.fontChanged();
     alignPanel.alignmentChanged();
   }
 
@@ -5890,7 +5965,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
               viewport.getAlignment()));
     } catch (Exception ex)
     {
-      System.err.println(ex.getMessage());
+      jalview.bin.Console.errPrintln(ex.getMessage());
       return;
     }
   }
@@ -5903,16 +5978,17 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   @Override
   protected void runGroovy_actionPerformed()
   {
-    Jalview.setCurrentAlignFrame(this);
-    groovy.ui.Console console = Desktop.getGroovyConsole();
+    Jalview.getInstance().setCurrentAlignFrame(this);
+    groovy.console.ui.Console console = Desktop.getGroovyConsole();
     if (console != null)
     {
       try
       {
+        console.setVariable(JalviewObjectI.currentAlFrameName, this);
         console.runScript();
       } catch (Exception ex)
       {
-        System.err.println((ex.toString()));
+        jalview.bin.Console.errPrintln((ex.toString()));
         JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 MessageManager.getString("label.couldnt_run_groovy_script"),
                 MessageManager.getString("label.groovy_support_failed"),
@@ -5921,7 +5997,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     }
     else
     {
-      System.err.println("Can't run Groovy script as console not found");
+      jalview.bin.Console
+              .errPrintln("Can't run Groovy script as console not found");
     }
   }
 
index 5613f16..a8bc815 100644 (file)
@@ -45,7 +45,6 @@ import jalview.bin.Console;
 import jalview.commands.CommandI;
 import jalview.datamodel.AlignedCodonFrame;
 import jalview.datamodel.Alignment;
-import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.ColumnSelection;
 import jalview.datamodel.ContactMatrixI;
@@ -998,7 +997,7 @@ public class AlignViewport extends AlignmentViewport
    */
   protected boolean noReferencesTo(AlignedCodonFrame acf)
   {
-    AlignFrame[] frames = Desktop.getAlignFrames();
+    AlignFrame[] frames = Desktop.getDesktopAlignFrames();
     if (frames == null)
     {
       return true;
index aa28a8c..fe6477e 100644 (file)
@@ -50,6 +50,7 @@ import jalview.api.AlignmentViewPanel;
 import jalview.bin.Cache;
 import jalview.bin.Console;
 import jalview.bin.Jalview;
+import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.HiddenColumns;
 import jalview.datamodel.SearchResultsI;
@@ -255,8 +256,10 @@ public class AlignmentPanel extends GAlignmentPanel implements
 
   /**
    * Calculates the width of the alignment labels based on the displayed names
-   * and any bounds on label width set in preferences. The calculated width is
-   * also set as a property of the viewport.
+   * and any bounds on label width set in preferences.
+   * 
+   * The calculated width is set as a property of the viewport and the layout is
+   * updated.
    * 
    * @return Dimension giving the maximum width of the alignment label panel
    *         that should be used.
@@ -269,10 +272,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     Dimension r = null;
     if (av.getIdWidth() < 0)
     {
-      int afwidth = (alignFrame != null ? alignFrame.getWidth() : 300);
-      int idWidth = Math.min(afwidth - 200, 2 * afwidth / 3);
-      int maxwidth = Math.max(IdwidthAdjuster.MIN_ID_WIDTH, idWidth);
-      r = calculateIdWidth(maxwidth);
+      r = calculateDefaultAlignmentIdWidth();
       av.setIdWidth(r.width);
     }
     else
@@ -294,9 +294,30 @@ public class AlignmentPanel extends GAlignmentPanel implements
     return r;
   }
 
+  public Dimension calculateDefaultAlignmentIdWidth()
+  {
+    return calculateIdWidth(-1, false, false);
+  }
+  /**
+   * pre 2.11.3 Id width calculation - used when importing old projects only
+   * @return
+   */
+  public int getLegacyIdWidth()
+  {
+    int afwidth = (alignFrame != null ? alignFrame.getWidth() : 300);
+    int idWidth = Math.min(afwidth - 200, 2 * afwidth / 3);
+    int maxwidth = Math.max(IdwidthAdjuster.MIN_ID_WIDTH, idWidth);
+    Dimension w = calculateIdWidthOrLegacy(true, maxwidth, false, false);
+    return w.width;
+  }
+
   /**
    * Calculate the width of the alignment labels based on the displayed names
-   * and any bounds on label width set in preferences.
+   * and any bounds on label width set in preferences. Also includes annotations
+   * not actually visible.
+   * 
+   * FIXME JAL-244 JAL-4091 - doesn't include sequence associated annotation
+   * label decorators and only called during tests
    * 
    * @param maxwidth
    *          -1 or maximum width allowed for IdWidth
@@ -305,6 +326,36 @@ public class AlignmentPanel extends GAlignmentPanel implements
    */
   protected Dimension calculateIdWidth(int maxwidth)
   {
+    return calculateIdWidth(maxwidth, true, false);
+  }
+  /**
+   * Calculate the width of the alignment labels based on the displayed names
+   * and any bounds on label width set in preferences.
+   * 
+   * @param maxwidth
+   *          -1 or maximum width allowed for IdWidth
+   * @param includeAnnotations - when true includes width of any additional marks in annotation id panel 
+   * @param visibleOnly - when true, ignore label widths for hidden annotation rows 
+   * @return Dimension giving the maximum width of the alignment label panel
+   *         that should be used.
+   */
+  public Dimension calculateIdWidth(int maxwidth,
+          boolean includeAnnotations, boolean visibleOnly)
+  {
+    return calculateIdWidthOrLegacy(false, maxwidth, includeAnnotations, visibleOnly);
+  }
+  
+  /**
+   * legacy mode or post 2.11.3 ID width calculation
+   * @param legacy - uses annotation labels, not rendered label width (excludes additional decorators)
+   * @param maxwidth
+   * @param includeAnnotations
+   * @param visibleOnly
+   * @return
+   */
+  private Dimension calculateIdWidthOrLegacy(boolean legacy, int maxwidth,
+          boolean includeAnnotations, boolean visibleOnly)
+  {
     Container c = new Container();
 
     FontMetrics fm = c.getFontMetrics(
@@ -324,18 +375,30 @@ public class AlignmentPanel extends GAlignmentPanel implements
     }
 
     // Also check annotation label widths
-    i = 0;
-
-    if (al.getAlignmentAnnotation() != null)
+    if (includeAnnotations && al.getAlignmentAnnotation() != null)
     {
       fm = c.getFontMetrics(getAlabels().getFont());
 
-      while (i < al.getAlignmentAnnotation().length)
+      if (!legacy || Jalview.isHeadlessMode())
       {
-        String label = al.getAlignmentAnnotation()[i].label;
-        int stringWidth = fm.stringWidth(label);
+        AnnotationLabels aal = getAlabels();
+        int stringWidth = aal.drawLabels(null, false, idWidth, false, false,
+                fm, !visibleOnly);
         idWidth = Math.max(idWidth, stringWidth);
-        i++;
+      }
+      else
+      {
+        for (i = 0; i < al.getAlignmentAnnotation().length; i++)
+        {
+          AlignmentAnnotation aa = al.getAlignmentAnnotation()[i];
+          if (visibleOnly && !aa.visible)
+          {
+            continue;
+          }
+          String label = aa.label;
+          int stringWidth = fm.stringWidth(label);
+          idWidth = Math.max(idWidth, stringWidth);
+        }
       }
     }
 
@@ -543,7 +606,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     // this is called after loading new annotation onto alignment
     if (alignFrame.getHeight() == 0)
     {
-      System.out.println("NEEDS FIXING");
+      jalview.bin.Console.error("adjustAnnotationHeight called with zero height alignment window");
     }
     validateAnnotationDimensions(true);
     addNotify();
@@ -567,21 +630,29 @@ public class AlignmentPanel extends GAlignmentPanel implements
     // not be called directly by programs.
     // I note that addNotify() is called in several areas of Jalview.
 
-    int annotationHeight = getAnnotationPanel().adjustPanelHeight();
-    annotationHeight = getAnnotationPanel()
-            .adjustForAlignFrame(adjustPanelHeight, annotationHeight);
+    AnnotationPanel ap = getAnnotationPanel();
+    int annotationHeight = ap.adjustPanelHeight();
+    annotationHeight = ap.adjustForAlignFrame(adjustPanelHeight,
+            annotationHeight);
 
     hscroll.addNotify();
-    annotationScroller.setPreferredSize(
-            new Dimension(annotationScroller.getWidth(), annotationHeight));
-
     Dimension e = idPanel.getSize();
-    alabels.setSize(new Dimension(e.width, annotationHeight));
+    int idWidth = e.width;
+    boolean manuallyAdjusted = this.getIdPanel().getIdCanvas()
+            .isManuallyAdjusted();
+    annotationScroller.setPreferredSize(new Dimension(
+            manuallyAdjusted ? idWidth : annotationScroller.getWidth(),
+            annotationHeight));
+
+    alabels.setPreferredSize(new Dimension(idWidth, annotationHeight));
 
     annotationSpaceFillerHolder.setPreferredSize(new Dimension(
-            annotationSpaceFillerHolder.getWidth(), annotationHeight));
+            manuallyAdjusted ? idWidth
+                    : annotationSpaceFillerHolder.getWidth(),
+            annotationHeight));
     annotationScroller.validate();
     annotationScroller.addNotify();
+    ap.validate();
   }
 
   /**
@@ -597,9 +668,10 @@ public class AlignmentPanel extends GAlignmentPanel implements
     boolean wrap = av.getWrapAlignment();
     ViewportRanges ranges = av.getRanges();
     ranges.setStartSeq(0);
-    scalePanelHolder.setVisible(!wrap);
+    // scalePanelHolder.setVisible(!wrap);
     hscroll.setVisible(!wrap);
-    idwidthAdjuster.setVisible(!wrap);
+    // Allow idPanel width adjustment in wrap mode
+    idwidthAdjuster.setVisible(true);
 
     if (wrap)
     {
@@ -633,7 +705,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
       }
     }
 
-    idSpaceFillerPanel1.setVisible(!wrap);
+    // idSpaceFillerPanel1.setVisible(!wrap);
 
     repaint();
   }
@@ -854,10 +926,27 @@ public class AlignmentPanel extends GAlignmentPanel implements
   public void paintComponent(Graphics g)
   {
     invalidate(); // needed so that the id width adjuster works correctly
-
     Dimension d = getIdPanel().getIdCanvas().getPreferredSize();
-    idPanelHolder.setPreferredSize(d);
-    hscrollFillerPanel.setPreferredSize(new Dimension(d.width, 12));
+    int idWidth = d.width;
+
+    // check wrapped alignment as at least 1 residue width
+    if (av.getWrapAlignment())
+    {
+      SeqCanvas sc = this.getSeqPanel().seqCanvas;
+      if (sc != null && sc.getWidth() < sc.getMinimumWrappedCanvasWidth())
+      {
+        // need to make some adjustments
+        idWidth -= (sc.getMinimumWrappedCanvasWidth() - sc.getWidth());
+        av.setIdWidth(idWidth);
+        av.getAlignPanel().getIdPanel().getIdCanvas()
+                .setManuallyAdjusted(true);
+
+        validateAnnotationDimensions(false);
+      }
+    }
+
+    idPanelHolder.setPreferredSize(new Dimension(idWidth, d.height));
+    hscrollFillerPanel.setPreferredSize(new Dimension(idWidth, 12));
 
     validate(); // needed so that the id width adjuster works correctly
 
@@ -948,8 +1037,16 @@ public class AlignmentPanel extends GAlignmentPanel implements
           Graphics idGraphics, Graphics alignmentGraphics)
           throws PrinterException
   {
-    final int idWidth = getVisibleIdWidth(false);
-
+    final int idWidth, idWidthForGui;
+    // otherwise calculate it
+    idWidth = getVisibleIdWidth(false);
+//    if (getIdPanel()!=null && getIdPanel().getWidth()>0)
+//    {
+//      // use the current IdPanel's width, if its set and non-zero
+//      idWidthForGui = getIdPanel().getWidth();
+//    } else {
+//      idWidthForGui=0;
+//    }
     /*
      * Get the horizontal offset to where we draw the sequences.
      * This is idWidth if using a single Graphics context, else zero.
@@ -998,6 +1095,9 @@ public class AlignmentPanel extends GAlignmentPanel implements
     }
     final int alignmentDrawnHeight = (endSeq - startSeq) * charHeight + 3;
 
+    alignmentGraphics.setColor(Color.white);
+    alignmentGraphics.fillRect(0, 0, pageWidth, pageHeight+scaleHeight);
+
     /*
      * draw the Scale at horizontal offset, then reset to top left (0, 0)
      */
@@ -1014,8 +1114,9 @@ public class AlignmentPanel extends GAlignmentPanel implements
     IdCanvas idCanvas = getIdPanel().getIdCanvas();
     List<SequenceI> selection = av.getSelectionGroup() == null ? null
             : av.getSelectionGroup().getSequences(null);
+    
     idCanvas.drawIds((Graphics2D) idGraphics, av, startSeq, endSeq - 1,
-            selection);
+            selection, false,idWidth);
 
     idGraphics.setFont(av.getFont());
     idGraphics.translate(0, -scaleHeight);
@@ -1039,7 +1140,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
       int offset = getAlabels().getScrollOffset();
       idGraphics.translate(0, -offset);
       idGraphics.translate(0, alignmentDrawnHeight);
-      getAlabels().drawComponent(idGraphics, idWidth);
+      getAlabels().drawComponentNotGUI(idGraphics, idWidth);
       idGraphics.translate(0, -alignmentDrawnHeight);
 
       /*
@@ -1120,7 +1221,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
      * draw sequence ids and annotation labels (if shown)
      */
     IdCanvas idCanvas = getIdPanel().getIdCanvas();
-    idCanvas.drawIdsWrapped((Graphics2D) g, av, 0, totalHeight);
+    idCanvas.drawIdsWrappedNoGUI((Graphics2D) g, av, 0, totalHeight);
 
     g.translate(idWidth, 0);
 
@@ -1162,7 +1263,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     // see if rendering offscreen - check preferences and calc width accordingly
     if (!onscreen && Cache.getDefault("FIGURE_AUTOIDWIDTH", false))
     {
-      return calculateIdWidth(-1).width;
+      return calculateIdWidth(-1,true,true).width;
     }
     Integer idwidth = onscreen ? null
             : Cache.getIntegerProperty("FIGURE_FIXEDIDWIDTH");
@@ -1172,6 +1273,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     }
 
     int w = getIdPanel().getWidth();
+    w = calculateIdWidth(-1, true, true).width;
     return (w > 0 ? w : calculateIdWidth().width);
   }
 
@@ -1179,7 +1281,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
           throws ImageOutputException
   {
     makeAlignmentImage(type, file, renderer,
-            BitmapImageSizing.nullBitmapImageSizing());
+            BitmapImageSizing.defaultBitmapImageSizing());
   }
 
   /**
@@ -1197,6 +1299,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     final int borderBottomOffset = 5;
 
     AlignmentDimension aDimension = getAlignmentDimension();
+
     // todo use a lambda function in place of callback here?
     ImageWriterI writer = new ImageWriterI()
     {
@@ -1410,8 +1513,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
   {
     int seqPanelWidth = getSeqPanel().seqCanvas.getWidth();
 
-    if (System.getProperty("java.awt.headless") != null
-            && System.getProperty("java.awt.headless").equals("true"))
+    if (Jalview.isHeadlessMode())
     {
       seqPanelWidth = alignFrame.getWidth() - getVisibleIdWidth()
               - vscroll.getPreferredSize().width
@@ -1799,5 +1901,4 @@ public class AlignmentPanel extends GAlignmentPanel implements
       overviewPanel = null;
     }
   }
-
 }
index 28065c3..08a25ba 100755 (executable)
@@ -20,6 +20,7 @@
  */
 package jalview.gui;
 
+import java.awt.Canvas;
 import java.awt.Color;
 import java.awt.Cursor;
 import java.awt.Dimension;
@@ -50,6 +51,8 @@ import javax.swing.ToolTipManager;
 
 import jalview.analysis.AlignSeq;
 import jalview.analysis.AlignmentUtils;
+import jalview.bin.Cache;
+import jalview.bin.Jalview;
 import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Annotation;
@@ -85,7 +88,7 @@ public class AnnotationLabels extends JPanel
   /**
    * height in pixels for allowing height adjuster to be active
    */
-  private static int HEIGHT_ADJUSTER_HEIGHT = 10;
+  public static int HEIGHT_ADJUSTER_HEIGHT = 10;
 
   private static final Font font = new Font("Arial", Font.PLAIN, 11);
 
@@ -113,6 +116,8 @@ public class AnnotationLabels extends JPanel
   private static final String COPYCONS_SEQ = MessageManager
           .getString("label.copy_consensus_sequence");
 
+  private static final String ADJUST_ANNOTATION_LABELS_WIDTH_PREF = "ADJUST_ANNOTATION_LABELS_WIDTH";
+
   private final boolean debugRedraw = false;
 
   private AlignmentPanel ap;
@@ -131,6 +136,10 @@ public class AnnotationLabels extends JPanel
 
   private boolean resizePanel = false;
 
+  private int annotationIdWidth = -1;
+
+  public static final String RESIZE_MARGINS_MARK_PREF = "RESIZE_MARGINS_MARK";
+
   /**
    * Creates a new AnnotationLabels object
    * 
@@ -138,7 +147,6 @@ public class AnnotationLabels extends JPanel
    */
   public AnnotationLabels(AlignmentPanel ap)
   {
-
     this.ap = ap;
     av = ap.av;
     ToolTipManager.sharedInstance().registerComponent(this);
@@ -418,65 +426,74 @@ public class AnnotationLabels extends JPanel
         pop.add(consclipbrd);
       }
 
-      addColourOrFilterByOptions(ap,aa[selectedRow],pop);
-      
+      addColourOrFilterByOptions(ap, aa[selectedRow], pop);
+
       if (aa[selectedRow].graph == AlignmentAnnotation.CONTACT_MAP)
       {
-        addContactMatrixOptions(ap,aa[selectedRow],pop);
-          // Set/adjust threshold for grouping ?
-          // colour alignment by this [type]
-          // select/hide columns by this row
-          
-        }
+        addContactMatrixOptions(ap, aa[selectedRow], pop);
+        // Set/adjust threshold for grouping ?
+        // colour alignment by this [type]
+        // select/hide columns by this row
+
       }
-    
+    }
+
     pop.show(this, evt.getX(), evt.getY());
   }
 
   static void addColourOrFilterByOptions(final AlignmentPanel ap,
-          final AlignmentAnnotation alignmentAnnotation, final JPopupMenu pop)
+          final AlignmentAnnotation alignmentAnnotation,
+          final JPopupMenu pop)
   {
     JMenuItem item;
-    item = new JMenuItem(MessageManager.getString("label.colour_by_annotation"));
+    item = new JMenuItem(
+            MessageManager.getString("label.colour_by_annotation"));
     item.addActionListener(new ActionListener()
     {
-      
+
       @Override
       public void actionPerformed(ActionEvent e)
       {
-        AnnotationColourChooser.displayFor(ap.av, ap,alignmentAnnotation,false);
+        AnnotationColourChooser.displayFor(ap.av, ap, alignmentAnnotation,
+                false);
       };
     });
     pop.add(item);
-    if (alignmentAnnotation.sequenceRef!=null)
+    if (alignmentAnnotation.sequenceRef != null)
     {
-      item = new JMenuItem(MessageManager.getString("label.colour_by_annotation")+" ("+MessageManager.getString("label.per_seq")+")");
+      item = new JMenuItem(
+              MessageManager.getString("label.colour_by_annotation") + " ("
+                      + MessageManager.getString("label.per_seq") + ")");
       item.addActionListener(new ActionListener()
       {
         @Override
         public void actionPerformed(ActionEvent e)
         {
-          AnnotationColourChooser.displayFor(ap.av, ap,alignmentAnnotation,true);
+          AnnotationColourChooser.displayFor(ap.av, ap, alignmentAnnotation,
+                  true);
         };
       });
       pop.add(item);
     }
-    item = new JMenuItem(MessageManager.getString("action.select_by_annotation"));
+    item = new JMenuItem(
+            MessageManager.getString("action.select_by_annotation"));
     item.addActionListener(new ActionListener()
     {
-      
+
       @Override
       public void actionPerformed(ActionEvent e)
       {
-        AnnotationColumnChooser.displayFor(ap.av,ap,alignmentAnnotation);
+        AnnotationColumnChooser.displayFor(ap.av, ap, alignmentAnnotation);
       };
     });
     pop.add(item);
   }
+
   static void addContactMatrixOptions(final AlignmentPanel ap,
-          final AlignmentAnnotation alignmentAnnotation, final JPopupMenu pop)
+          final AlignmentAnnotation alignmentAnnotation,
+          final JPopupMenu pop)
   {
-    
+
     final ContactMatrixI cm = ap.av.getContactMatrix(alignmentAnnotation);
     JMenuItem item;
     if (cm != null)
@@ -485,10 +502,13 @@ public class AnnotationLabels extends JPanel
 
       if (cm.hasGroups())
       {
-        JCheckBoxMenuItem chitem = new JCheckBoxMenuItem(MessageManager.getString("action.show_groups_on_matrix"));
-        chitem.setToolTipText(MessageManager.getString("action.show_groups_on_matrix_tooltip"));
-        boolean showGroups = alignmentAnnotation.isShowGroupsForContactMatrix();
-        final AlignmentAnnotation sel_row=alignmentAnnotation;
+        JCheckBoxMenuItem chitem = new JCheckBoxMenuItem(
+                MessageManager.getString("action.show_groups_on_matrix"));
+        chitem.setToolTipText(MessageManager
+                .getString("action.show_groups_on_matrix_tooltip"));
+        boolean showGroups = alignmentAnnotation
+                .isShowGroupsForContactMatrix();
+        final AlignmentAnnotation sel_row = alignmentAnnotation;
         chitem.setState(showGroups);
         chitem.addActionListener(new ActionListener()
         {
@@ -507,8 +527,10 @@ public class AnnotationLabels extends JPanel
       }
       if (cm.hasTree())
       {
-        item = new JMenuItem(MessageManager.getString("action.show_tree_for_matrix"));
-        item.setToolTipText(MessageManager.getString("action.show_tree_for_matrix_tooltip"));
+        item = new JMenuItem(
+                MessageManager.getString("action.show_tree_for_matrix"));
+        item.setToolTipText(MessageManager
+                .getString("action.show_tree_for_matrix_tooltip"));
         item.addActionListener(new ActionListener()
         {
 
@@ -524,8 +546,10 @@ public class AnnotationLabels extends JPanel
       }
       else
       {
-        item = new JMenuItem(MessageManager.getString("action.cluster_matrix"));
-        item.setToolTipText(MessageManager.getString("action.cluster_matrix_tooltip"));
+        item = new JMenuItem(
+                MessageManager.getString("action.cluster_matrix"));
+        item.setToolTipText(
+                MessageManager.getString("action.cluster_matrix_tooltip"));
         item.addActionListener(new ActionListener()
         {
           @Override
@@ -537,7 +561,11 @@ public class AnnotationLabels extends JPanel
               public void run()
               {
                 final long progBar;
-                ap.alignFrame.setProgressBar(MessageManager.formatMessage("action.clustering_matrix_for",cm.getAnnotDescr(),5f), progBar = System.currentTimeMillis());
+                ap.alignFrame.setProgressBar(
+                        MessageManager.formatMessage(
+                                "action.clustering_matrix_for",
+                                cm.getAnnotDescr(), 5f),
+                        progBar = System.currentTimeMillis());
                 cm.setGroupSet(GroupSet.makeGroups(cm, true));
                 cm.randomlyReColourGroups();
                 cm.transferGroupColorsTo(alignmentAnnotation);
@@ -1140,8 +1168,7 @@ public class AnnotationLabels extends JPanel
               RenderingHints.VALUE_ANTIALIAS_ON);
     }
 
-    drawComponent(g2, true, width);
-
+    drawComponent(g2, true, width, true);
   }
 
   /**
@@ -1156,7 +1183,7 @@ public class AnnotationLabels extends JPanel
    */
   public void drawComponent(Graphics g, int width)
   {
-    drawComponent(g, false, width);
+    drawComponent(g, false, width, true);
   }
 
   /**
@@ -1171,32 +1198,148 @@ public class AnnotationLabels extends JPanel
    * @param width
    *          Width for scaling labels
    */
-  public void drawComponent(Graphics g, boolean clip, int width)
+  public void drawComponent(Graphics g, boolean clip, int givenWidth, boolean forGUI)
   {
-    if (av.getFont().getSize() < 10)
+    int width = givenWidth;
+    IdwidthAdjuster iwa = null;
+    if (ap != null)
     {
-      g.setFont(font);
+      iwa = ap.idwidthAdjuster;
+      if ((Cache.getDefault(ADJUST_ANNOTATION_LABELS_WIDTH_PREF, true)
+              || Jalview.isHeadlessMode()))
+      {
+        Graphics2D g2d = (Graphics2D) g;
+        Graphics dummy = g2d.create();
+        int newAnnotationIdWidth = drawLabels(dummy, clip, width, false, forGUI,
+                null, false);
+        dummy.dispose();
+        Dimension d = ap.calculateDefaultAlignmentIdWidth();
+        int alignmentIdWidth = d.width;
+        if (iwa != null && !iwa.manuallyAdjusted())
+        {
+          // If no manual adjustment to ID column with has been made then adjust
+          // width match widest of alignment or annotation id widths
+          boolean allowShrink = Cache.getDefault("ALLOW_SHRINK_ID_WIDTH",
+                  false);
+          width = Math.max(alignmentIdWidth, newAnnotationIdWidth);
+          if (clip && width < givenWidth && !allowShrink)
+          {
+            width = givenWidth;
+          }
+        }
+        else if (newAnnotationIdWidth != annotationIdWidth
+                && newAnnotationIdWidth > givenWidth
+                && newAnnotationIdWidth > alignmentIdWidth)
+        {
+          // otherwise if the annotation id width has become larger than the
+          // current id width, increase
+          width = newAnnotationIdWidth;
+          annotationIdWidth = newAnnotationIdWidth;
+        }
+        // set the width if it's changed
+        if (width != ap.av.getIdWidth())
+        {
+          iwa.setWidth(width);
+        }
+      }
     }
     else
     {
-      g.setFont(av.getFont());
+      int newAnnotationIdWidth = drawLabels(g, clip, width, false, forGUI, null, false);
+      width = newAnnotationIdWidth<givenWidth ? givenWidth: Math.min(newAnnotationIdWidth, givenWidth);
+    }
+    drawLabels(g, clip, width, true, forGUI, null, false);
+  }
+
+  /**
+   * Render the full set of annotation Labels for the alignment at the given
+   * cursor. If actuallyDraw is false or g is null then no actual drawing will
+   * occur, but the widest label width will be returned. If g is null then
+   * fmetrics must be supplied.
+   * 
+   * @param g
+   *          Graphics2D instance (used for rendering and font scaling if no fmetrics supplied) 
+   * @param clip
+   *          - true indicates that only current visible area needs to be
+   *          rendered
+   * @param width
+   *          Width for scaling labels
+   * @param actuallyDraw - when false, no graphics are rendered to g0
+   * @param forGUI - when false, GUI relevant marks like indicators for dragging annotation panel height are not rendered
+   * @param fmetrics
+   *          FontMetrics if Graphics object g is null
+   * @param includeHidden - when true returned width includes labels in hidden row width calculation 
+   * @return the width of the annotation labels.
+   */
+  public int drawLabels(Graphics g0, boolean clip, int width,
+          boolean actuallyDraw, boolean forGUI, FontMetrics fmetrics, boolean includeHidden)
+  {
+    if (clip)
+    {
+      clip = Cache.getDefault("MOVE_SEQUENCE_ID_WITH_VISIBLE_ANNOTATIONS",
+              true);
+    }
+    Graphics g = null;
+    // create a dummy Graphics object if not drawing and one is supplied
+    if (g0 != null)
+    {
+      if (!actuallyDraw)
+      {
+        Graphics2D g2d = (Graphics2D) g0;
+        g = g2d.create();
+      }
+      else
+      {
+        g = g0;
+      }
+    }
+    int actualWidth = 0;
+    if (g != null)
+    {
+      if (av.getFont().getSize() < 10)
+      {
+        g.setFont(font);
+      }
+      else
+      {
+        g.setFont(av.getFont());
+      }
     }
 
-    FontMetrics fm = g.getFontMetrics(g.getFont());
-    g.setColor(Color.white);
-    g.fillRect(0, 0, getWidth(), getHeight());
+    FontMetrics fm = fmetrics == null ? g.getFontMetrics(g.getFont())
+            : fmetrics;
+    if (actuallyDraw)
+    {
+      g.setColor(Color.white);
+      g.fillRect(0, 0, getWidth(), getHeight());
+
+      if (!Cache.getDefault(RESIZE_MARGINS_MARK_PREF, false)
+              && !av.getWrapAlignment() && forGUI)
+      {
+        g.setColor(Color.LIGHT_GRAY);
+        g.drawLine(0, HEIGHT_ADJUSTER_HEIGHT / 4, HEIGHT_ADJUSTER_WIDTH / 4,
+                HEIGHT_ADJUSTER_HEIGHT / 4);
+        g.drawLine(0, 3 * HEIGHT_ADJUSTER_HEIGHT / 4,
+                HEIGHT_ADJUSTER_WIDTH / 4, 3 * HEIGHT_ADJUSTER_HEIGHT / 4);
+
+      }
+    }
 
-    g.translate(0, getScrollOffset());
-    g.setColor(Color.black);
+    if (actuallyDraw)
+    {
+      g.translate(0, getScrollOffset());
+      g.setColor(Color.black);
+    }
     SequenceI lastSeqRef = null;
     String lastLabel = null;
     AlignmentAnnotation[] aa = av.getAlignment().getAlignmentAnnotation();
-    int fontHeight = g.getFont().getSize();
+    int fontHeight = g != null ? g.getFont().getSize()
+            : fm.getFont().getSize();
     int y = 0;
     int x = 0;
     int graphExtras = 0;
     int offset = 0;
-    Font baseFont = g.getFont();
+    Font baseFont = g != null ? g.getFont() : fm.getFont();
     FontMetrics baseMetrics = fm;
     int ofontH = fontHeight;
     int sOffset = 0;
@@ -1218,7 +1361,7 @@ public class AnnotationLabels extends JPanel
       for (int i = 0; i < aa.length; i++)
       {
         visible = true;
-        if (!aa[i].visible)
+        if (!aa[i].visible && !includeHidden)
         {
           hasHiddenRows = true;
           continue;
@@ -1226,7 +1369,7 @@ public class AnnotationLabels extends JPanel
         olY = y;
         // look ahead to next annotation
         for (nexAA = i + 1; nexAA < aa.length
-                && !aa[nexAA].visible; nexAA++)
+                && (!aa[nexAA].visible && includeHidden); nexAA++)
           ;
         y += aa[i].height;
         if (clip)
@@ -1237,7 +1380,7 @@ public class AnnotationLabels extends JPanel
             {
               if (debugRedraw)
               {
-                System.out.println("before vis: " + i);
+                jalview.bin.Console.outPrintln("before vis: " + i);
               }
               before = true;
             }
@@ -1251,7 +1394,7 @@ public class AnnotationLabels extends JPanel
             {
               if (debugRedraw)
               {
-                System.out.println(
+                jalview.bin.Console.outPrintln(
                         "Scroll offset: " + sOffset + " after vis: " + i);
               }
               after = true;
@@ -1260,8 +1403,10 @@ public class AnnotationLabels extends JPanel
             continue;
           }
         }
-        g.setColor(Color.black);
-
+        if (actuallyDraw && g != null)
+        {
+          g.setColor(Color.black);
+        }
         offset = -aa[i].height / 2;
 
         if (aa[i].hasText)
@@ -1306,7 +1451,9 @@ public class AnnotationLabels extends JPanel
             vertBar = true;
           }
         }
-        x = width - fm.stringWidth(label) - 3;
+
+        int labelWidth = fm.stringWidth(label) + 3;
+        x = width - labelWidth;
 
         if (aa[i].graphGroup > -1)
         {
@@ -1339,10 +1486,15 @@ public class AnnotationLabels extends JPanel
               s = ((float) fontHeight) / (float) ofontH;
               Font f = baseFont
                       .deriveFont(AffineTransform.getScaleInstance(s, s));
-              g.setFont(f);
-              fm = g.getFontMetrics();
-              graphExtras = (aa[i].height - (groupSize * (fontHeight + 8)))
-                      / 2;
+              Canvas c = new Canvas();
+              fm = c.getFontMetrics(f);
+              if (actuallyDraw && g != null)
+              {
+                g.setFont(f);
+                // fm = g.getFontMetrics();
+                graphExtras = (aa[i].height
+                        - (groupSize * (fontHeight + 8))) / 2;
+              }
             }
           }
           if (visible)
@@ -1351,58 +1503,81 @@ public class AnnotationLabels extends JPanel
             {
               if (aa[gg].graphGroup == aa[i].graphGroup)
               {
-                x = width - fm.stringWidth(aa[gg].label) - 3;
-                g.drawString(aa[gg].label, x, y - graphExtras);
-
-                if (aa[gg]._linecolour != null)
+                labelWidth = fm.stringWidth(aa[gg].label) + 3;
+                x = width - labelWidth;
+                if (actuallyDraw && g != null)
                 {
+                  g.drawString(aa[gg].label, x, y - graphExtras);
 
-                  g.setColor(aa[gg]._linecolour);
-                  g.drawLine(x, y - graphExtras + 3,
-                          x + fm.stringWidth(aa[gg].label),
-                          y - graphExtras + 3);
-                }
+                  if (aa[gg]._linecolour != null)
+                  {
+
+                    g.setColor(aa[gg]._linecolour);
+                    g.drawLine(x, y - graphExtras + 3,
+                            x + fm.stringWidth(aa[gg].label),
+                            y - graphExtras + 3);
+                  }
 
-                g.setColor(Color.black);
+                  g.setColor(Color.black);
+                }
                 graphExtras += fontHeight + 8;
               }
             }
           }
-          g.setFont(baseFont);
+          if (actuallyDraw && g != null)
+          {
+            g.setFont(baseFont);
+          }
           fm = baseMetrics;
           fontHeight = ofontH;
         }
         else
         {
-          if (vertBar)
+          if (actuallyDraw && g != null)
           {
-            g.drawLine(width - 3, y + offset - fontHeight, width - 3,
-                    (int) (y - 1.5 * aa[i].height - offset - fontHeight));
-            // g.drawLine(20, y + offset, x - 20, y + offset);
+            if (vertBar)
+            {
+              g.drawLine(width - 3, y + offset - fontHeight, width - 3,
+                      (int) (y - 1.5 * aa[i].height - offset - fontHeight));
+              // g.drawLine(20, y + offset, x - 20, y + offset);
 
+            }
+            g.drawString(label, x, y + offset);
           }
-          g.drawString(label, x, y + offset);
         }
         lastSeqRef = aa[i].sequenceRef;
+
+        if (labelWidth > actualWidth)
+        {
+          actualWidth = labelWidth;
+        }
       }
     }
 
-    if (!resizePanel && dragEvent != null && aa != null)
+    if (!resizePanel && dragEvent != null && aa != null && selectedRow>-1 && selectedRow<aa.length)
     {
-      g.setColor(Color.lightGray);
-      g.drawString(
-              (aa[selectedRow].sequenceRef == null ? ""
-                      : aa[selectedRow].sequenceRef.getName())
-                      + aa[selectedRow].label,
-              dragEvent.getX(), dragEvent.getY() - getScrollOffset());
+      if (actuallyDraw && g != null)
+      {
+        g.setColor(Color.lightGray);
+        g.drawString(
+                (aa[selectedRow].sequenceRef == null ? ""
+                        : aa[selectedRow].sequenceRef.getName())
+                        + aa[selectedRow].label,
+                dragEvent.getX(), dragEvent.getY() - getScrollOffset());
+      }
     }
 
     if (!av.getWrapAlignment() && ((aa == null) || (aa.length < 1)))
     {
-      g.drawString(MessageManager.getString("label.right_click"), 2, 8);
-      g.drawString(MessageManager.getString("label.to_add_annotation"), 2,
-              18);
+      if (actuallyDraw && g != null)
+      {
+        g.drawString(MessageManager.getString("label.right_click"), 2, 8);
+        g.drawString(MessageManager.getString("label.to_add_annotation"), 2,
+                18);
+      }
     }
+
+    return actualWidth;
   }
 
   public int getScrollOffset()
@@ -1414,4 +1589,9 @@ public class AnnotationLabels extends JPanel
   public void mouseEntered(MouseEvent e)
   {
   }
+
+  public void drawComponentNotGUI(Graphics idGraphics, int idWidth)
+  {
+    drawComponent(idGraphics, false, idWidth, false);
+  }
 }
index 8321741..6c9cb6c 100755 (executable)
@@ -68,6 +68,7 @@ import jalview.renderer.AwtRenderPanelI;
 import jalview.renderer.ContactGeometry;
 import jalview.schemes.ResidueProperties;
 import jalview.util.Comparison;
+import jalview.util.Format;
 import jalview.util.MessageManager;
 import jalview.util.Platform;
 import jalview.viewmodel.ViewportListenerI;
@@ -630,7 +631,12 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
       return false;
     }
     int yOffset = rowIndex[1];
-
+    AlignmentAnnotation[] allAnnotation = av.getAlignment()
+            .getAlignmentAnnotation();
+    if (allAnnotation==null || rowIndex[0]<0 || rowIndex[0]>=allAnnotation.length)
+    {
+      return false;
+    }
     AlignmentAnnotation clicked = av.getAlignment()
             .getAlignmentAnnotation()[rowIndex[0]];
     if (clicked.graph != AlignmentAnnotation.CONTACT_MAP)
@@ -647,144 +653,152 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
     {
       ContactGeometry cXcgeom = new ContactGeometry(forCurrentX,
               clicked.graphHeight);
-      ContactGeometry.contactInterval cXci = cXcgeom.mapFor(yOffset,
-              yOffset);
-      /**
-       * start and end range corresponding to the row range under the mouse at
-       * column currentX
-       */
-      int fr, to;
-      fr = Math.min(cXci.cStart, cXci.cEnd);
-      to = Math.max(cXci.cStart, cXci.cEnd);
-
-      // double click selects the whole group
-      if (evt.getClickCount() == 2)
+      ContactGeometry.contactInterval cXci = cXcgeom.mapFor(yOffset);
+      if (cXci != null)
       {
-        ContactMatrixI matrix = av.getContactMatrix(clicked);
+        /**
+         * start and end range corresponding to the row range under the mouse at
+         * column currentX
+         */
+        int fr, to;
+        fr = Math.min(cXci.cStart, cXci.cEnd);
+        to = Math.max(cXci.cStart, cXci.cEnd);
 
-        if (matrix != null)
+        // double click selects the whole group
+        if (evt.getClickCount() == 2)
         {
-          // simplest approach is to select all group containing column
-          if (matrix.hasGroups())
+          ContactMatrixI matrix = av.getContactMatrix(clicked);
+
+          if (matrix != null)
           {
-            SequenceI rseq = clicked.sequenceRef;
-            BitSet grp = new BitSet();
-            grp.or(matrix.getGroupsFor(currentX));
-            // TODO: cXci needs to be mapped to real groups
-            for (int c = fr; c <= to; c++)
+            // simplest approach is to select all group containing column
+            if (matrix.hasGroups())
             {
-              BitSet additionalGrp = matrix.getGroupsFor(c);
-              grp.or(additionalGrp);
-            }
+              SequenceI rseq = clicked.sequenceRef;
+              BitSet grp = new BitSet();
+              grp.or(matrix.getGroupsFor(currentX));
+              // TODO: cXci needs to be mapped to real groups
+              for (int c = fr; c <= to; c++)
+              {
+                BitSet additionalGrp = matrix.getGroupsFor(c);
+                grp.or(additionalGrp);
+              }
 
-            HiddenColumns hc = av.getAlignment().getHiddenColumns();
-            ColumnSelection cs = av.getColumnSelection();
-            
-            for (int p=grp.nextSetBit(0); p >= 0; p = grp
-                    .nextSetBit(p + 1))
-            {
-              if (matrix instanceof MappableContactMatrixI)
+              HiddenColumns hc = av.getAlignment().getHiddenColumns();
+              ColumnSelection cs = av.getColumnSelection();
+
+              for (int p = grp.nextSetBit(0); p >= 0; p = grp
+                      .nextSetBit(p + 1))
               {
-                // find the end of this run of set bits
-                int nextp = grp.nextClearBit(p)-1;
-                int[] pos = ((MappableContactMatrixI)matrix).getMappedPositionsFor(rseq, p,nextp);
-                p=nextp;
-                
-                if (pos!=null)
+                if (matrix instanceof MappableContactMatrixI)
                 {
-                  for (int pos_p = pos[0];pos_p<=pos[1];pos_p++)
+                  // find the end of this run of set bits
+                  int nextp = grp.nextClearBit(p) - 1;
+                  int[] pos = ((MappableContactMatrixI) matrix)
+                          .getMappedPositionsFor(rseq, p, nextp);
+                  p = nextp;
+
+                  if (pos != null)
                   {
-                    int col = rseq.findIndex(pos_p)-1;
-                    if (col>=0 && (!av.hasHiddenColumns() || hc.isVisible(col)))
+                    for (int pos_p = pos[0]; pos_p <= pos[1]; pos_p++)
                     {
-                      cs.addElement(col);
+                      int col = rseq.findIndex(pos_p) - 1;
+                      if (col >= 0 && (!av.hasHiddenColumns()
+                              || hc.isVisible(col)))
+                      {
+                        cs.addElement(col);
+                      }
                     }
                   }
                 }
-              } else {
-                int offp = (rseq != null)
-                        ? rseq.findIndex(rseq.getStart() - 1 + p)
-                        : p;
-  
-                if (!av.hasHiddenColumns() || hc.isVisible(offp))
+                else
                 {
-                  cs.addElement(offp);
+                  int offp = (rseq != null)
+                          ? rseq.findIndex(rseq.getStart() - 1 + p)
+                          : p;
+
+                  if (!av.hasHiddenColumns() || hc.isVisible(offp))
+                  {
+                    cs.addElement(offp);
+                  }
                 }
               }
             }
-          }
-          // possible alternative for interactive selection - threshold
-          // gives 'ceiling' for forming a cluster
-          // when a row+column is selected, farthest common ancestor less
-          // than thr is used to compute cluster
+            // possible alternative for interactive selection - threshold
+            // gives 'ceiling' for forming a cluster
+            // when a row+column is selected, farthest common ancestor less
+            // than thr is used to compute cluster
 
-        }
-      }
-      else
-      {
-        // select corresponding range in segment under mouse
-        {
-          int[] rng = forCurrentX.getMappedPositionsFor(fr, to);
-          if (rng != null)
-          {
-            av.getColumnSelection().addRangeOfElements(rng, true);
           }
-          av.getColumnSelection().addElement(currentX);
         }
-        // PAE SPECIFIC
-        // and also select everything lower than the max range adjacent
-        // (kind of works)
-        if (evt.isControlDown()
-                && PAEContactMatrix.PAEMATRIX.equals(clicked.getCalcId()))
+        else
         {
-          int c = fr;
-          ContactRange cr = forCurrentX.getRangeFor(fr, to);
-          double cval;
-          // TODO: could use GraphLine instead of arbitrary picking
-          // TODO: could report mean/median/variance for partitions
-          // (contiguous selected vs unselected regions and inter-contig
-          // regions)
-          // controls feathering - what other elements in row/column
-          // should we select
-          double thresh = cr.getMean() + (cr.getMax() - cr.getMean()) * .15;
-          while (c >= 0)
+          // select corresponding range in segment under mouse
           {
-            cval = forCurrentX.getContactAt(c);
-            if (// cr.getMin() <= cval &&
-            cval <= thresh)
+            int[] rng = forCurrentX.getMappedPositionsFor(fr, to);
+            if (rng != null)
             {
-              int[] cols = forCurrentX.getMappedPositionsFor(c, c);
-              if (cols != null)
-              {
-                av.getColumnSelection().addRangeOfElements(cols, true);
-              }
-              else
-              {
-                break;
-              }
+              av.getColumnSelection().addRangeOfElements(rng, true);
             }
-            c--;
+            av.getColumnSelection().addElement(currentX);
           }
-          c = to;
-          while (c < forCurrentX.getContactHeight())
+          // PAE SPECIFIC
+          // and also select everything lower than the max range adjacent
+          // (kind of works)
+          if (evt.isControlDown()
+                  && PAEContactMatrix.PAEMATRIX.equals(clicked.getCalcId()))
           {
-            cval = forCurrentX.getContactAt(c);
-            if (// cr.getMin() <= cval &&
-            cval <= thresh)
+            int c = fr;
+            ContactRange cr = forCurrentX.getRangeFor(fr, to);
+            double cval;
+            // TODO: could use GraphLine instead of arbitrary picking
+            // TODO: could report mean/median/variance for partitions
+            // (contiguous selected vs unselected regions and inter-contig
+            // regions)
+            // controls feathering - what other elements in row/column
+            // should we select
+            double thresh = cr.getMean()
+                    + (cr.getMax() - cr.getMean()) * .15;
+            while (c >= 0)
             {
-              int[] cols = forCurrentX.getMappedPositionsFor(c, c);
-              if (cols != null)
+              cval = forCurrentX.getContactAt(c);
+              if (// cr.getMin() <= cval &&
+              cval <= thresh)
               {
-                av.getColumnSelection().addRangeOfElements(cols, true);
+                int[] cols = forCurrentX.getMappedPositionsFor(c, c);
+                if (cols != null)
+                {
+                  av.getColumnSelection().addRangeOfElements(cols, true);
+                }
+                else
+                {
+                  break;
+                }
               }
+              c--;
             }
-            else
+            c = to;
+            while (c < forCurrentX.getContactHeight())
             {
-              break;
-            }
-            c++;
+              cval = forCurrentX.getContactAt(c);
+              if (// cr.getMin() <= cval &&
+              cval <= thresh)
+              {
+                int[] cols = forCurrentX.getMappedPositionsFor(c, c);
+                if (cols != null)
+                {
+                  av.getColumnSelection().addRangeOfElements(cols, true);
+                }
+              }
+              else
+              {
+                break;
+              }
+              c++;
 
+            }
           }
+
         }
       }
     }
@@ -1075,23 +1089,21 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
 
     if (forFromX != null && forToX != null)
     {
-      ContactGeometry lastXcgeom = new ContactGeometry(forFromX,
-              cma.graphHeight);
-      ContactGeometry.contactInterval lastXci = lastXcgeom
-              .mapFor(rowIndex[1], rowIndex[1] + deltaY);
-
-      ContactGeometry cXcgeom = new ContactGeometry(forToX,
+      // FIXME will need two ContactGeometry objects when handling contact matrices with differing numbers of rows at each
+      // column
+      ContactGeometry xcgeom = new ContactGeometry(forFromX,
               cma.graphHeight);
-      ContactGeometry.contactInterval cXci = cXcgeom.mapFor(rowIndex[1],
-              rowIndex[1] + deltaY);
+      ContactGeometry.contactInterval lastXci = xcgeom
+              .mapFor(rowIndex[1]);
+      ContactGeometry.contactInterval cXci = xcgeom.mapFor(rowIndex[1] + deltaY);
 
       // mark rectangular region formed by drag
       jalview.bin.Console.trace("Matrix Selection from last(" + fromXc
               + ",[" + lastXci.cStart + "," + lastXci.cEnd + "]) to cur("
               + toXc + ",[" + cXci.cStart + "," + cXci.cEnd + "])");
       int fr, to;
-      fr = Math.min(lastXci.cStart, lastXci.cEnd);
-      to = Math.max(lastXci.cStart, lastXci.cEnd);
+      fr = Math.min(lastXci.cStart, cXci.cStart);
+      to = Math.max(lastXci.cEnd, cXci.cEnd);
       int[] mappedPos = forFromX.getMappedPositionsFor(fr, to);
       if (mappedPos != null)
       {
@@ -1109,33 +1121,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
           // }
           // else
           {
-            av.getColumnSelection().addElement(c);
-          }
-        }
-      }
-      // and again for most recent corner of drag
-      fr = Math.min(cXci.cStart, cXci.cEnd);
-      to = Math.max(cXci.cStart, cXci.cEnd);
-      mappedPos = forFromX.getMappedPositionsFor(fr, to);
-      if (mappedPos != null)
-      {
-        for (int pair = 0; pair < mappedPos.length; pair += 2)
-        {
-          jalview.bin.Console.trace("Marking " + fr + " to " + to
-                  + " mapping to sequence positions " + mappedPos[pair]
-                  + " to " + mappedPos[pair + 1]);
-          for (int c = mappedPos[pair]; c <= mappedPos[pair + 1]; c++)
-          {
-            // if (cma.sequenceRef != null)
-            // {
-            // int col =
-            // cma.sequenceRef.findIndex(cma.sequenceRef.getStart()+c);
-            // av.getColumnSelection().addElement(col);
-            // }
-            // else
-            {
-              av.getColumnSelection().addElement(c);
-            }
+            av.getColumnSelection().addElement(c-1);
           }
         }
       }
@@ -1311,9 +1297,11 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
         ContactGeometry cgeom = new ContactGeometry(clist, ann.graphHeight);
         ContactGeometry.contactInterval ci = cgeom.mapFor(rowAndOffset);
         ContactRange cr = clist.getRangeFor(ci.cStart, ci.cEnd);
-        tooltip = "Contact from " + clist.getPosition() + ", [" + ci.cStart
-                + " - " + ci.cEnd + "]" + "<br/>Mean:" + cr.getMean();
-
+        StringBuilder tooltipb = new StringBuilder();
+        tooltipb.append("Contact from ")
+        .append(clist.getPosition()).append(", [").append(ci.cStart).append(" - ").append(ci.cEnd).append("]").append("<br/>Mean:");
+        Format.appendPercentage(tooltipb, (float)cr.getMean(),2);
+        tooltip = tooltipb.toString();
         int col = ann.sequenceRef.findPosition(column);
         int[][] highlightPos;
         int[] mappedPos = clist.getMappedPositionsFor(ci.cStart, ci.cEnd);
@@ -1507,7 +1495,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
           tried = true;
         } catch (IllegalArgumentException exc)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Serious issue with viewport geometry imgWidth requested was "
                           + imgWidth);
           return;
@@ -1650,7 +1638,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
               && (fadedImage == null || fadedImage.getWidth() != imgWidth
                       || fadedImage.getHeight() != image.getHeight()))
       {
-        // System.err.println("redraw faded image ("+(fadedImage==null ?
+        // jalview.bin.Console.errPrintln("redraw faded image ("+(fadedImage==null ?
         // "null image" : "") + " lastGood="+lastImageGood+")");
         fadedImage = new BufferedImage(imgWidth, image.getHeight(),
                 BufferedImage.TYPE_INT_RGB);
index 49eae98..ba4eb9c 100644 (file)
@@ -28,16 +28,10 @@ import java.awt.Graphics;
 import java.awt.Graphics2D;
 import java.awt.RenderingHints;
 import java.io.File;
-import java.lang.reflect.InvocationTargetException;
 import java.util.List;
 import java.util.Locale;
 import java.util.Map;
-import java.util.concurrent.Callable;
-import java.util.concurrent.CompletableFuture;
-import java.util.concurrent.ExecutorService;
 import java.util.concurrent.Executors;
-import java.util.concurrent.Future;
-import java.util.concurrent.FutureTask;
 
 import javax.swing.JPanel;
 import javax.swing.JSplitPane;
@@ -270,6 +264,8 @@ public class AppJmol extends StructureViewerBase
     }
     jmb.executeCommand(new StructureCommand(command), false);
     jmb.executeCommand(new StructureCommand("set hoverDelay=0.1"), false);
+    jmb.executeCommand(new StructureCommand("set antialiasdisplay on"),
+            false);
     jmb.setFinishedInit(true);
   }
 
@@ -371,9 +367,10 @@ public class AppJmol extends StructureViewerBase
       }
       if (waitTotal > waitMax)
       {
-        System.err.println("Timed out waiting for Jmol to load files after "
-                + waitTotal + "ms");
-        // System.err.println("finished: " + jmb.isFinishedInit()
+        jalview.bin.Console.errPrintln(
+                "Timed out waiting for Jmol to load files after "
+                        + waitTotal + "ms");
+        // jalview.bin.Console.errPrintln("finished: " + jmb.isFinishedInit()
         // + "; loaded: " + Arrays.toString(jmb.getPdbFile())
         // + "; files: " + files.toString());
         jmb.getStructureFiles();
@@ -434,11 +431,14 @@ public class AppJmol extends StructureViewerBase
   @Override
   public void makePDBImage(ImageMaker.TYPE type)
   {
-    try {
-    makePDBImage(null, type, null,
-            BitmapImageSizing.nullBitmapImageSizing());
-    } catch (ImageOutputException ioex) {
-      Console.error("Unexpected error whilst writing "+type.toString(),ioex);
+    try
+    {
+      makePDBImage(null, type, null,
+              BitmapImageSizing.defaultBitmapImageSizing());
+    } catch (ImageOutputException ioex)
+    {
+      Console.error("Unexpected error whilst writing " + type.toString(),
+              ioex);
     }
   }
 
@@ -450,9 +450,9 @@ public class AppJmol extends StructureViewerBase
 
     BitmapImageSizing bis = ImageMaker.getScaleWidthHeight(width, height,
             userBis);
-    float usescale = bis.scale;
-    int usewidth = bis.width;
-    int useheight = bis.height;
+    float usescale = bis.scale();
+    int usewidth = bis.width();
+    int useheight = bis.height();
 
     ImageWriterI writer = new ImageWriterI()
     {
@@ -472,7 +472,6 @@ public class AppJmol extends StructureViewerBase
           }
         }
 
-        jmb.jmolViewer.antialiased = true;
         jmb.jmolViewer.requestRepaintAndWait("image export");
         jmb.jmolViewer.renderScreenImage(ig2, usewidth, useheight);
       }
@@ -481,29 +480,33 @@ public class AppJmol extends StructureViewerBase
             .toLowerCase(Locale.ROOT);
     final ImageExporter exporter = new ImageExporter(writer,
             getProgressIndicator(), type, getTitle());
-    
+
     final Throwable[] exceptions = new Throwable[1];
     exceptions[0] = null;
     final AppJmol us = this;
     try
     {
-      Thread runner = Executors.defaultThreadFactory().newThread(new Runnable()
-      {
-        @Override
-        public void run()
-        {
-          try
-          {
-            exporter.doExport(file, us, width, height, view, renderer,
-                    userBis);
-          } catch (Throwable t)
-          {
-            exceptions[0] = t;
-          }
-        }
-      });
+      Thread runner = Executors.defaultThreadFactory()
+              .newThread(new Runnable()
+              {
+                @Override
+                public void run()
+                {
+                  try
+                  {
+                    exporter.doExport(file, us, width, height, view,
+                            renderer, userBis);
+                  } catch (Throwable t)
+                  {
+                    exceptions[0] = t;
+                  }
+                }
+              });
       runner.start();
-      do { Thread.sleep(25); } while (runner.isAlive());
+      do
+      {
+        Thread.sleep(25);
+      } while (runner.isAlive());
     } catch (Throwable e)
     {
       throw new ImageOutputException(
@@ -532,7 +535,8 @@ public class AppJmol extends StructureViewerBase
               .openURL("http://wiki.jmol.org");// http://jmol.sourceforge.net/docs/JmolUserGuide/");
     } catch (Exception ex)
     {
-      System.err.println("Show Jmol help failed with: " + ex.getMessage());
+      jalview.bin.Console
+              .errPrintln("Show Jmol help failed with: " + ex.getMessage());
     }
   }
 
index 3f8175d..158bb54 100644 (file)
@@ -34,7 +34,7 @@ import org.openscience.jmol.app.jmolpanel.console.AppConsole;
 import jalview.api.AlignmentViewPanel;
 import jalview.api.structures.JalviewStructureDisplayI;
 import jalview.bin.Console;
-import jalview.datamodel.AlignmentI;
+import jalview.bin.Jalview;
 import jalview.datamodel.PDBEntry;
 import jalview.datamodel.SequenceI;
 import jalview.ext.jmol.JalviewJmolBinding;
@@ -42,9 +42,6 @@ import jalview.io.DataSourceType;
 import jalview.structure.StructureSelectionManager;
 import jalview.util.MessageManager;
 import jalview.util.Platform;
-import jalview.ws.dbsources.EBIAlfaFold;
-import jalview.ws.dbsources.Pdb;
-import jalview.ws.utils.UrlDownloadClient;
 import javajs.util.BS;
 
 public class AppJmolBinding extends JalviewJmolBinding
@@ -156,7 +153,7 @@ public class AppJmolBinding extends JalviewJmolBinding
   {
     jmolViewer.setJmolCallbackListener(this);
     // BH comment: can't do this yet [for JS only, or generally?]
-    return Platform.isJS() ? null
+    return Platform.isJS() || Jalview.isHeadlessMode() ? null
             : new AppConsole(jmolViewer, consolePanel, buttonsToShow);
   }
 
index 6fac8fc..eb2368d 100644 (file)
@@ -476,7 +476,7 @@ public class AppVarna extends JInternalFrame
       if (shift != null)
       {
         int i = shift.shift(newBase.getIndex());
-        // System.err.println("shifted "+(arg1.getIndex())+" to "+i);
+        // jalview.bin.Console.errPrintln("shifted "+(arg1.getIndex())+" to "+i);
         ssm.mouseOverVamsasSequence(seq, i, this);
       }
       else
index 5cfe72a..8951df0 100644 (file)
@@ -574,7 +574,7 @@ public class AppVarnaBinding extends JalviewVarnaBinding
     } catch (ExceptionNAViewAlgorithm e)
     {
       // only throwable for draw mode = 3 NAView
-      System.err.println("Error drawing RNA: " + e.getMessage());
+      jalview.bin.Console.errPrintln("Error drawing RNA: " + e.getMessage());
     }
   }
 }
index af59ca7..c120a1b 100644 (file)
@@ -772,7 +772,7 @@ public class BlogReader extends JPanel
       String formattedDate = Cache.setDateProperty(
               "JALVIEW_NEWS_RSS_LASTMODIFIED", lastread.getTime());
       BlogReader me = new BlogReader();
-      System.out.println("Set last date to " + formattedDate);
+      jalview.bin.Console.outPrintln("Set last date to " + formattedDate);
       if (me.isNewsNew())
       {
         Console.debug("There is news to read.");
index cc6a785..f13e151 100644 (file)
@@ -343,7 +343,7 @@ public class ChimeraViewFrame extends StructureViewerBase
       boolean opened = jmb.openSession(chimeraSessionFile);
       if (!opened)
       {
-        System.err.println("An error occurred opening Chimera session file "
+        jalview.bin.Console.errPrintln("An error occurred opening Chimera session file "
                 + chimeraSessionFile);
       }
     }
index c1c75f1..574ba28 100644 (file)
@@ -304,7 +304,7 @@ public class ColourMenuHelper
         }
       } catch (Exception ex)
       {
-        System.out.println("Error loading User ColourFile\n" + ex);
+        jalview.bin.Console.outPrintln("Error loading User ColourFile\n" + ex);
       }
     }
 
index 5a23048..921a418 100644 (file)
@@ -50,6 +50,7 @@ import javax.swing.JLabel;
 import javax.swing.JPanel;
 import javax.swing.JScrollPane;
 import javax.swing.JTextArea;
+import javax.swing.SwingUtilities;
 import javax.swing.border.Border;
 import javax.swing.text.DefaultCaret;
 
@@ -106,7 +107,7 @@ public class Console extends WindowAdapter
 
   private JComboBox<LogLevel> logLevelCombo = new JComboBox<LogLevel>();
 
-  protected LogLevel startingLogLevel = LogLevel.INFO;
+  protected LogLevel startingLogLevel = null;
 
   public Console()
   {
@@ -147,6 +148,7 @@ public class Console extends WindowAdapter
     scrollPane.setBorder(noBorder);
     textArea.addMouseListener(new MouseAdapter()
     {
+      @Override
       public void mouseClicked(MouseEvent e)
       {
         if (e.getButton() == MouseEvent.BUTTON1)
@@ -172,6 +174,7 @@ public class Console extends WindowAdapter
             MessageManager.getString("label.copy_to_clipboard"));
     copyToClipboardButton.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         copyConsoleTextToClipboard();
@@ -183,12 +186,14 @@ public class Console extends WindowAdapter
 
       private Color fg = textArea.getForeground();
 
+      @Override
       public void mousePressed(MouseEvent e)
       {
         textArea.setBackground(textArea.getSelectionColor());
         textArea.setForeground(textArea.getSelectedTextColor());
       }
 
+      @Override
       public void mouseReleased(MouseEvent e)
       {
         textArea.setBackground(bg);
@@ -212,11 +217,19 @@ public class Console extends WindowAdapter
     // logLevelCombo.addItem(LogLevel.ERROR);
     // logLevelCombo.addItem(LogLevel.OFF);
     // set startingLogLevel
-    startingLogLevel = jalview.bin.Console.log == null ? LogLevel.INFO
-            : jalview.bin.Console.log.getLevel();
+    
+    if (jalview.bin.Console.getLogger() == null)
+    {
+      startingLogLevel = jalview.bin.Console.getCachedLogLevel();
+    }
+    else
+    {
+      startingLogLevel = jalview.bin.Console.getLogger().getLevel();
+    }
     setChosenLogLevelCombo();
     logLevelCombo.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         if (jalview.bin.Console.log != null)
@@ -313,7 +326,7 @@ public class Console extends WindowAdapter
         boolean added = false;
         for (int i = 0; i < logLevelCombo.getItemCount(); i++)
         {
-          LogLevel l = (LogLevel) logLevelCombo.getItemAt(i);
+          LogLevel l = logLevelCombo.getItemAt(i);
           if (l.compareTo(setLogLevel) >= 0)
           {
             logLevelCombo.insertItemAt(setLogLevel, i);
@@ -433,20 +446,20 @@ public class Console extends WindowAdapter
     // you may omit this part for your application
     //
 
-    System.out.println("Hello World 2");
-    System.out.println("All fonts available to Graphic2D:\n");
+    jalview.bin.Console.outPrintln("Hello World 2");
+    jalview.bin.Console.outPrintln("All fonts available to Graphic2D:\n");
     GraphicsEnvironment ge = GraphicsEnvironment
             .getLocalGraphicsEnvironment();
     String[] fontNames = ge.getAvailableFontFamilyNames();
     for (int n = 0; n < fontNames.length; n++)
     {
-      System.out.println(fontNames[n]);
+      jalview.bin.Console.outPrintln(fontNames[n]);
     }
     // Testing part: simple an error thrown anywhere in this JVM will be printed
     // on the Console
     // We do it with a seperate Thread becasue we don't wan't to break a Thread
     // used by the Console.
-    System.out.println("\nLets throw an error on this console");
+    jalview.bin.Console.outPrintln("\nLets throw an error on this console");
     errorThrower = new Thread(this);
     errorThrower.setDaemon(true);
     errorThrower.start();
@@ -475,36 +488,32 @@ public class Console extends WindowAdapter
    */
   public Console(Desktop desktop)
   {
-    this(desktop, true);
-  }
-
-  /**
-   * attach a console to the desktop - the desktop will open it if requested.
-   * 
-   * @param desktop
-   * @param showjconsole
-   *          - if true, then redirect stdout immediately
-   */
-  public Console(Desktop desktop, boolean showjconsole)
-  {
     parent = desktop;
     // window name - get x,y,width, height possibly scaled
-    Rectangle bounds = desktop.getLastKnownDimensions("JAVA_CONSOLE_");
-    if (bounds == null)
+    Rectangle bounds = parent == null ? null
+            : parent.getLastKnownDimensions("JAVA_CONSOLE_");
+    if (bounds != null)
     {
       frame = initFrame(
               ChannelProperties.getProperty("app_name") + " Java Console",
-              desktop.getWidth() / 2, desktop.getHeight() / 4,
-              desktop.getX(), desktop.getY());
+              bounds.width, bounds.height, bounds.x, bounds.y);
+    }
+    else if (parent != null && parent.getWidth() > 0
+            && parent.getHeight() > 0)
+    {
+      frame = initFrame(
+              ChannelProperties.getProperty("app_name") + " Java Console",
+              parent.getWidth() / 2, parent.getHeight() / 4, parent.getX(),
+              parent.getY());
     }
     else
     {
       frame = initFrame(
               ChannelProperties.getProperty("app_name") + " Java Console",
-              bounds.width, bounds.height, bounds.x, bounds.y);
+              MIN_WIDTH, MIN_HEIGHT, 10, 10);
     }
     frame.setMinimumSize(new Dimension(MIN_WIDTH, MIN_HEIGHT));
-    // desktop.add(frame);
+    // parent.add(frame);
     initConsole(false);
     LogLevel level = (LogLevel) logLevelCombo.getSelectedItem();
     if (!Platform.isJS())
@@ -537,6 +546,7 @@ public class Console extends WindowAdapter
         pin.close();
       } catch (Exception e)
       {
+        jalview.bin.Console.debug("pin.close() error", e);
       }
       try
       {
@@ -544,12 +554,14 @@ public class Console extends WindowAdapter
         pin2.close();
       } catch (Exception e)
       {
+        jalview.bin.Console.debug("pin2.close() error", e);
       }
       try
       {
         textAppender.join(10);
       } catch (Exception e)
       {
+        jalview.bin.Console.debug("textAppender.join(10) error", e);
       }
     }
     /*
@@ -610,12 +622,9 @@ public class Console extends WindowAdapter
           try
           {
             this.wait(100);
-            if (pin.available() == 0)
-            {
-              trimBuffer(false);
-            }
           } catch (InterruptedException ie)
           {
+            jalview.bin.Console.debug("pin.available() error", ie);
           }
         }
 
@@ -641,13 +650,14 @@ public class Console extends WindowAdapter
         {
           try
           {
-            this.wait(100);
+            this.wait(100); // ##### implicated BLOCKED
             if (pin2.available() == 0)
             {
               trimBuffer(false);
             }
           } catch (InterruptedException ie)
           {
+            jalview.bin.Console.debug("pin.available() error", ie);
           }
         }
         while (pin2.available() != 0)
@@ -672,23 +682,23 @@ public class Console extends WindowAdapter
           // check string buffer - if greater than console, clear console and
           // replace with last segment of content, otherwise, append all to
           // content.
-          long count;
           while (displayPipe.length() > 0)
           {
-            count = 0;
             StringBuffer tmp = new StringBuffer(), replace;
             synchronized (displayPipe)
             {
               replace = displayPipe;
               displayPipe = tmp;
             }
-            // simply append whole buffer
-            textArea.append(replace.toString());
-            count += replace.length();
-            if (count > byteslim)
+            // Append formatted message to textarea using the Swing Thread.
+            SwingUtilities.invokeLater(new Runnable()
             {
-              trimBuffer(false);
-            }
+              public void run()
+              {
+                textArea.append(replace.toString());
+                trimBuffer(false);
+              }
+            });
           }
           if (displayPipe.length() == 0)
           {
@@ -697,10 +707,18 @@ public class Console extends WindowAdapter
               this.wait(100);
               if (displayPipe.length() == 0)
               {
-                trimBuffer(false);
+                // post a trim on Swing Thread.
+                SwingUtilities.invokeLater(new Runnable()
+                {
+                  public void run()
+                  {
+                    trimBuffer(false);
+                  }
+                });
               }
             } catch (InterruptedException e)
             {
+              jalview.bin.Console.debug("displayPipe.length() error", e);
             }
           }
         }
@@ -711,7 +729,7 @@ public class Console extends WindowAdapter
             this.wait(100);
           } catch (InterruptedException e)
           {
-
+            jalview.bin.Console.debug("this.wait(100) error", e);
           }
         }
         if (quit)
@@ -738,6 +756,7 @@ public class Console extends WindowAdapter
         this.wait(1000);
       } catch (InterruptedException ie)
       {
+        jalview.bin.Console.debug("this.wait(1000) error", ie);
       }
       throw new NullPointerException(
               MessageManager.getString("exception.application_test_npe"));
@@ -757,9 +776,7 @@ public class Console extends WindowAdapter
       @Override
       public void run()
       {
-        displayPipe.append(input); // change to stringBuffer
-        // displayPipe.flush();
-
+        displayPipe.append(input); 
       }
     });
     // stderr.println("Time taken to Spawnappend:\t" + (System.nanoTime() -
@@ -781,7 +798,7 @@ public class Console extends WindowAdapter
                 + "\nTruncated...\n";
       } catch (Exception e)
       {
-        e.printStackTrace();
+        jalview.bin.Console.warn("textArea Exception", e);
       }
     }
     // trim the buffer
@@ -805,7 +822,7 @@ public class Console extends WindowAdapter
           }
         } catch (Exception e)
         {
-          e.printStackTrace();
+          jalview.bin.Console.warn("textArea Exception", e);
         }
         // lines = textArea.getLineCount();
       }
index c15cf2d..6cb59c3 100644 (file)
@@ -432,7 +432,7 @@ public class CrossRefAction implements Runnable
                 MessageManager.getString("label.cant_map_cds"),
                 MessageManager.getString("label.operation_failed"),
                 JvOptionPane.OK_OPTION);
-        System.err.println("Failed to make CDS alignment");
+        jalview.bin.Console.errPrintln("Failed to make CDS alignment");
         return null;
       }
 
@@ -466,7 +466,7 @@ public class CrossRefAction implements Runnable
 
     if (copyAlignment.getHeight() <= 0)
     {
-      System.err.println("No Sequences generated for xRef type " + source);
+      jalview.bin.Console.errPrintln("No Sequences generated for xRef type " + source);
       return null;
     }
 
index 12ff20b..070e67d 100644 (file)
@@ -22,6 +22,7 @@ package jalview.gui;
 
 import java.awt.BorderLayout;
 import java.awt.Color;
+import java.awt.Component;
 import java.awt.Dimension;
 import java.awt.FontMetrics;
 import java.awt.Graphics;
@@ -51,6 +52,7 @@ import java.awt.event.WindowEvent;
 import java.awt.geom.AffineTransform;
 import java.beans.PropertyChangeEvent;
 import java.beans.PropertyChangeListener;
+import java.beans.PropertyVetoException;
 import java.io.File;
 import java.io.FileWriter;
 import java.io.IOException;
@@ -63,6 +65,7 @@ import java.util.Hashtable;
 import java.util.List;
 import java.util.ListIterator;
 import java.util.Locale;
+import java.util.Map;
 import java.util.Vector;
 import java.util.concurrent.ExecutorService;
 import java.util.concurrent.Executors;
@@ -85,10 +88,14 @@ import javax.swing.JFrame;
 import javax.swing.JInternalFrame;
 import javax.swing.JLabel;
 import javax.swing.JMenuItem;
+import javax.swing.JOptionPane;
 import javax.swing.JPanel;
 import javax.swing.JPopupMenu;
 import javax.swing.JProgressBar;
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
 import javax.swing.JTextField;
+import javax.swing.JTextPane;
 import javax.swing.KeyStroke;
 import javax.swing.SwingUtilities;
 import javax.swing.WindowConstants;
@@ -96,6 +103,7 @@ import javax.swing.event.HyperlinkEvent;
 import javax.swing.event.HyperlinkEvent.EventType;
 import javax.swing.event.InternalFrameAdapter;
 import javax.swing.event.InternalFrameEvent;
+import javax.swing.text.JTextComponent;
 
 import org.stackoverflowusers.file.WindowsShortcut;
 
@@ -104,6 +112,10 @@ import jalview.api.AlignmentViewPanel;
 import jalview.api.structures.JalviewStructureDisplayI;
 import jalview.bin.Cache;
 import jalview.bin.Jalview;
+import jalview.bin.Jalview.ExitCode;
+import jalview.bin.argparser.Arg;
+import jalview.bin.groovy.JalviewObject;
+import jalview.bin.groovy.JalviewObjectI;
 import jalview.datamodel.Alignment;
 import jalview.datamodel.HiddenColumns;
 import jalview.datamodel.Sequence;
@@ -148,7 +160,7 @@ import jalview.ws.utils.UrlDownloadClient;
  */
 public class Desktop extends jalview.jbgui.GDesktop
         implements DropTargetListener, ClipboardOwner, IProgressIndicator,
-        jalview.api.StructureSelectionManagerProvider
+        jalview.api.StructureSelectionManagerProvider, JalviewObjectI
 {
   private static final String CITATION;
   static
@@ -439,7 +451,7 @@ public class Desktop extends jalview.jbgui.GDesktop
          * Send this message to stderr as the warning that follows (due to
          * reflection) also goes to stderr.
          */
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Linux platform only! You may have the following warning next: \"WARNING: An illegal reflective access operation has occurred\"\nThis is expected and cannot be avoided, sorry about that.");
       }
       final String awtAppClassName = "awtAppClassName";
@@ -489,7 +501,28 @@ public class Desktop extends jalview.jbgui.GDesktop
 
     boolean selmemusage = Cache.getDefault("SHOW_MEMUSAGE", false);
 
-    boolean showjconsole = Cache.getDefault("SHOW_JAVA_CONSOLE", false);
+    boolean showjconsole = Cache.getArgCacheDefault(Arg.JAVACONSOLE,
+            "SHOW_JAVA_CONSOLE", false);
+
+    // start dialogue queue for single dialogues
+    startDialogQueue();
+
+    if (!Platform.isJS())
+    /**
+     * Java only
+     * 
+     * @j2sIgnore
+     */
+    {
+      Desktop.instance.acquireDialogQueue();
+
+      jconsole = new Console(this);
+      jconsole.setHeader(Cache.getVersionDetailsForConsole());
+      showConsole(showjconsole);
+
+      Desktop.instance.releaseDialogQueue();
+    }
+
     desktop = new MyDesktopPane(selmemusage);
 
     showMemusage.setSelected(selmemusage);
@@ -536,9 +569,6 @@ public class Desktop extends jalview.jbgui.GDesktop
       setBounds(xPos, yPos, 900, 650);
     }
 
-    // start dialogue queue for single dialogues
-    startDialogQueue();
-
     if (!Platform.isJS())
     /**
      * Java only
@@ -546,10 +576,6 @@ public class Desktop extends jalview.jbgui.GDesktop
      * @j2sIgnore
      */
     {
-      jconsole = new Console(this, showjconsole);
-      jconsole.setHeader(Cache.getVersionDetailsForConsole());
-      showConsole(showjconsole);
-
       showNews.setVisible(false);
 
       experimentalFeatures.setSelected(showExperimental());
@@ -572,15 +598,16 @@ public class Desktop extends jalview.jbgui.GDesktop
       }
 
       // Thread off a new instance of the file chooser - this reduces the time
-      // it
-      // takes to open it later on.
+      // it takes to open it later on.
       new Thread(new Runnable()
       {
         @Override
         public void run()
         {
           jalview.bin.Console.debug("Filechooser init thread started.");
-          String fileFormat = Cache.getProperty("DEFAULT_FILE_FORMAT");
+          String fileFormat = FileLoader.getUseDefaultFileFormat()
+                  ? Cache.getProperty("DEFAULT_FILE_FORMAT")
+                  : null;
           JalviewFileChooser.forRead(Cache.getProperty("LAST_DIRECTORY"),
                   fileFormat);
           jalview.bin.Console.debug("Filechooser init thread finished.");
@@ -632,6 +659,7 @@ public class Desktop extends jalview.jbgui.GDesktop
       // used for jalviewjsTest
       jalview.bin.Console.info("JALVIEWJS: CREATED DESKTOP");
     }
+
   }
 
   /**
@@ -776,17 +804,17 @@ public class Desktop extends jalview.jbgui.GDesktop
         iw = (int) (iw * sw);
         iy = (int) (iy * sh);
         ih = (int) (ih * sh);
-        while (ix >= screenSize.width)
+        if (ix >= screenSize.width)
         {
           jalview.bin.Console.debug(
                   "Window geometry location recall error: shifting horizontal to within screenbounds.");
-          ix -= screenSize.width;
+          ix = ix % screenSize.width;
         }
-        while (iy >= screenSize.height)
+        if (iy >= screenSize.height)
         {
           jalview.bin.Console.debug(
                   "Window geometry location recall error: shifting vertical to within screenbounds.");
-          iy -= screenSize.height;
+          iy = iy % screenSize.height;
         }
         jalview.bin.Console.debug(
                 "Got last known dimensions for " + windowName + ": x:" + ix
@@ -873,7 +901,7 @@ public class Desktop extends jalview.jbgui.GDesktop
         }
       } catch (Exception ex)
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "Unable to paste alignment from system clipboard:\n" + ex);
       }
     }
@@ -1030,7 +1058,7 @@ public class Desktop extends jalview.jbgui.GDesktop
         {
           if (itf instanceof AlignFrame)
           {
-            Jalview.setCurrentAlignFrame((AlignFrame) itf);
+            Jalview.getInstance().setCurrentAlignFrame((AlignFrame) itf);
           }
           itf.requestFocus();
         }
@@ -1078,23 +1106,23 @@ public class Desktop extends jalview.jbgui.GDesktop
 
     setKeyBindings(frame);
 
-    // Since the latest FlatLaf patch, we occasionally have problems showing structureViewer frames...
-    int tries=3;
-    boolean shown=false;
-    Exception last=null;
+    // Since the latest FlatLaf patch, we occasionally have problems showing
+    // structureViewer frames...
+    int tries = 3;
+    boolean shown = false;
+    Exception last = null;
     do
     {
       try
       {
         desktop.add(frame);
-        shown=true;
+        shown = true;
       } catch (IllegalArgumentException iaex)
       {
-        last=iaex;
+        last = iaex;
         tries--;
-        jalview.bin.Console.info(
-                "Squashed IllegalArgument Exception (" + tries + " left) for "+frame.getTitle(),
-                iaex);
+        jalview.bin.Console.info("Squashed IllegalArgument Exception ("
+                + tries + " left) for " + frame.getTitle(), iaex);
         try
         {
           Thread.sleep(5);
@@ -1106,7 +1134,9 @@ public class Desktop extends jalview.jbgui.GDesktop
     } while (!shown && tries > 0);
     if (!shown)
     {
-      jalview.bin.Console.error("Serious Problem whilst showing window "+frame.getTitle(),last);
+      jalview.bin.Console.error(
+              "Serious Problem whilst showing window " + frame.getTitle(),
+              last);
     }
 
     windowMenu.add(menuItem);
@@ -1267,7 +1297,9 @@ public class Desktop extends jalview.jbgui.GDesktop
   @Override
   public void inputLocalFileMenuItem_actionPerformed(AlignViewport viewport)
   {
-    String fileFormat = Cache.getProperty("DEFAULT_FILE_FORMAT");
+    String fileFormat = FileLoader.getUseDefaultFileFormat()
+            ? Cache.getProperty("DEFAULT_FILE_FORMAT")
+            : null;
     JalviewFileChooser chooser = JalviewFileChooser.forRead(
             Cache.getProperty("LAST_DIRECTORY"), fileFormat,
             BackupFiles.getEnabled());
@@ -1445,62 +1477,73 @@ public class Desktop extends jalview.jbgui.GDesktop
     desktopQuit(true, false);
   }
 
-  public QuitHandler.QResponse desktopQuit(boolean ui, boolean disposeFlag)
-  {
-    final Runnable doDesktopQuit = () -> {
-      Dimension screen = Toolkit.getDefaultToolkit().getScreenSize();
-      Cache.setProperty("SCREENGEOMETRY_WIDTH", screen.width + "");
-      Cache.setProperty("SCREENGEOMETRY_HEIGHT", screen.height + "");
-      storeLastKnownDimensions("", new Rectangle(getBounds().x,
-              getBounds().y, getWidth(), getHeight()));
+  /**
+   * close everything, stash window geometries, and shut down all associated threads/workers  
+   * @param dispose - sets the dispose on close flag - JVM may terminate when set
+   * @param terminateJvm - quit with prejudice - stops the JVM.
+   */
+  public void quitTheDesktop(boolean dispose, boolean terminateJvm) {
+    Dimension screen = Toolkit.getDefaultToolkit().getScreenSize();
+    Cache.setProperty("SCREENGEOMETRY_WIDTH", screen.width + "");
+    Cache.setProperty("SCREENGEOMETRY_HEIGHT", screen.height + "");
+    storeLastKnownDimensions("", new Rectangle(getBounds().x,
+            getBounds().y, getWidth(), getHeight()));
 
-      if (jconsole != null)
-      {
-        storeLastKnownDimensions("JAVA_CONSOLE_", jconsole.getBounds());
-        jconsole.stopConsole();
-      }
+    if (jconsole != null)
+    {
+      storeLastKnownDimensions("JAVA_CONSOLE_", jconsole.getBounds());
+      jconsole.stopConsole();
+    }
 
-      if (jvnews != null)
-      {
-        storeLastKnownDimensions("JALVIEW_RSS_WINDOW_", jvnews.getBounds());
-      }
+    if (jvnews != null)
+    {
+      storeLastKnownDimensions("JALVIEW_RSS_WINDOW_", jvnews.getBounds());
+    }
 
-      // Frames should all close automatically. Keeping external
-      // viewers open should already be decided by user.
-      closeAll_actionPerformed(null);
+    // Frames should all close automatically. Keeping external
+    // viewers open should already be decided by user.
+    closeAll_actionPerformed(null);
 
-      // check for aborted quit
-      if (QuitHandler.quitCancelled())
-      {
-        jalview.bin.Console.debug("Desktop aborting quit");
-        return;
-      }
+    if (dialogExecutor != null)
+    {
+      dialogExecutor.shutdownNow();
+    }
 
-      if (dialogExecutor != null)
-      {
-        dialogExecutor.shutdownNow();
-      }
+    if (groovyConsole != null)
+    {
+      // suppress a possible repeat prompt to save script
+      groovyConsole.setDirty(false);
+      groovyConsole.exit();
+    }
 
-      if (groovyConsole != null)
-      {
-        // suppress a possible repeat prompt to save script
-        groovyConsole.setDirty(false);
-        groovyConsole.exit();
-      }
+    if (terminateJvm)
+    {
+      // note that shutdown hook will not be run
+      jalview.bin.Console.debug("Force Quit selected by user");
+      Runtime.getRuntime().halt(0);
+    }
 
-      if (QuitHandler.gotQuitResponse() == QResponse.FORCE_QUIT)
-      {
-        // note that shutdown hook will not be run
-        jalview.bin.Console.debug("Force Quit selected by user");
-        Runtime.getRuntime().halt(0);
-      }
+    jalview.bin.Console.debug("Quit selected by user");
+    if (dispose)
+    {
+      instance.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
+      // instance.dispose();
+    }
+  }
+  public QuitHandler.QResponse desktopQuit(boolean ui, boolean disposeFlag)
+  {
+    final Runnable doDesktopQuit = () -> {
 
-      jalview.bin.Console.debug("Quit selected by user");
-      if (disposeFlag)
+      // FIRST !!  check for aborted quit
+      if (QuitHandler.quitCancelled())
       {
-        instance.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
-        // instance.dispose();
+        jalview.bin.Console.debug("Quit was cancelled - Desktop aborting quit");
+        return;
       }
+      
+      // Proceed with quitting
+      quitTheDesktop(disposeFlag, QuitHandler.gotQuitResponse() == QResponse.FORCE_QUIT);
+      // and exit the JVM
       instance.quit();
     };
 
@@ -1509,7 +1552,14 @@ public class Desktop extends jalview.jbgui.GDesktop
   }
 
   /**
-   * Don't call this directly, use desktopQuit() above. Exits the program.
+   * Exits the program and the JVM. 
+   * 
+   * Don't call this directly
+   * 
+   * - use desktopQuit() above to tidy up first.
+   * 
+   * - use closeDesktop() to shutdown Jalview without shutting down the JVM 
+   * 
    */
   @Override
   public void quit()
@@ -1517,7 +1567,7 @@ public class Desktop extends jalview.jbgui.GDesktop
     // this will run the shutdownHook but QuitHandler.getQuitResponse() should
     // not run a second time if gotQuitResponse flag has been set (i.e. user
     // confirmed quit of some kind).
-    Jalview.exit("Desktop exiting.", 0);
+    Jalview.exit("Desktop exiting.", ExitCode.OK);
   }
 
   private void storeLastKnownDimensions(String string, Rectangle jc)
@@ -1630,7 +1680,8 @@ public class Desktop extends jalview.jbgui.GDesktop
       }
     } catch (Exception ex)
     {
-      System.err.println("Error opening help: " + ex.getMessage());
+      jalview.bin.Console
+              .errPrintln("Error opening help: " + ex.getMessage());
     }
   }
 
@@ -1648,7 +1699,7 @@ public class Desktop extends jalview.jbgui.GDesktop
       {
       }
     }
-    Jalview.setCurrentAlignFrame(null);
+    Jalview.getInstance().setCurrentAlignFrame(null);
     jalview.bin.Console.info("ALL CLOSED");
 
     /*
@@ -1861,7 +1912,8 @@ public class Desktop extends jalview.jbgui.GDesktop
     boolean autoSave = projectFile != null && !saveAs
             && BackupFiles.getEnabled();
 
-    // System.out.println("autoSave="+autoSave+", projectFile='"+projectFile+"',
+    // jalview.bin.Console.outPrintln("autoSave="+autoSave+",
+    // projectFile='"+projectFile+"',
     // saveAs="+saveAs+", Backups
     // "+(BackupFiles.getEnabled()?"enabled":"disabled"));
 
@@ -2106,7 +2158,7 @@ public class Desktop extends jalview.jbgui.GDesktop
       return null;
     }
     List<AlignmentPanel> aps = new ArrayList<>();
-    AlignFrame[] frames = getAlignFrames();
+    AlignFrame[] frames = Desktop.getDesktopAlignFrames();
     if (frames == null)
     {
       return null;
@@ -2143,7 +2195,7 @@ public class Desktop extends jalview.jbgui.GDesktop
     List<AlignmentViewport> viewp = new ArrayList<>();
     if (desktop != null)
     {
-      AlignFrame[] frames = Desktop.getAlignFrames();
+      AlignFrame[] frames = Desktop.getDesktopAlignFrames();
 
       for (AlignFrame afr : frames)
       {
@@ -2504,12 +2556,12 @@ public class Desktop extends jalview.jbgui.GDesktop
    * 
    * @return an array of AlignFrame, or null if none found
    */
-  public static AlignFrame[] getAlignFrames()
+  @Override
+  public AlignFrame[] getAlignFrames()
   {
-    if (Jalview.isHeadlessMode())
+    if (desktop == null)
     {
-      // Desktop.desktop is null in headless mode
-      return new AlignFrame[] { Jalview.currentAlignFrame };
+      return null;
     }
 
     JInternalFrame[] frames = Desktop.desktop.getAllFrames();
@@ -2551,6 +2603,25 @@ public class Desktop extends jalview.jbgui.GDesktop
   }
 
   /**
+   * static version
+   */
+  public static AlignFrame[] getDesktopAlignFrames()
+  {
+    if (Jalview.isHeadlessMode())
+    {
+      // Desktop.desktop is null in headless mode
+      return Jalview.getInstance().getAlignFrames();
+    }
+
+    if (instance != null && desktop != null)
+    {
+      return instance.getAlignFrames();
+    }
+
+    return null;
+  }
+
+  /**
    * Returns an array of any AppJmol frames in the Desktop (or null if none).
    * 
    * @return
@@ -2592,7 +2663,7 @@ public class Desktop extends jalview.jbgui.GDesktop
       openGroovyConsole();
     } catch (Exception ex)
     {
-      jalview.bin.Console.error("Groovy Shell Creation failed.", ex);
+      jalview.bin.Console.error("Groovy Console creation failed.", ex);
       JvOptionPane.showInternalMessageDialog(Desktop.desktop,
 
               MessageManager.getString("label.couldnt_create_groovy_shell"),
@@ -2608,8 +2679,11 @@ public class Desktop extends jalview.jbgui.GDesktop
   {
     if (groovyConsole == null)
     {
-      groovyConsole = new groovy.ui.Console();
-      groovyConsole.setVariable("Jalview", this);
+      JalviewObjectI j = new JalviewObject(this);
+      groovyConsole = new groovy.console.ui.Console();
+      groovyConsole.setVariable(JalviewObjectI.jalviewObjectName, j);
+      groovyConsole.setVariable(JalviewObjectI.currentAlFrameName,
+              getCurrentAlignFrame());
       groovyConsole.run();
 
       /*
@@ -2682,7 +2756,7 @@ public class Desktop extends jalview.jbgui.GDesktop
      */
     groovyShell.setEnabled(!enabled);
 
-    AlignFrame[] alignFrames = getAlignFrames();
+    AlignFrame[] alignFrames = getDesktopAlignFrames();
     if (alignFrames != null)
     {
       for (AlignFrame af : alignFrames)
@@ -2993,7 +3067,13 @@ public class Desktop extends jalview.jbgui.GDesktop
    */
   public static void showUrl(final String url)
   {
-    showUrl(url, Desktop.instance);
+    if (url!=null && !url.trim().equals("")) {
+      jalview.bin.Console.info("Opening URL: "+url);
+      showUrl(url, Desktop.instance);
+    } else {
+      jalview.bin.Console.warn("Ignoring attempt to show an empty URL.");
+    }
+    
   }
 
   /**
@@ -3091,7 +3171,7 @@ public class Desktop extends jalview.jbgui.GDesktop
    */
   private Semaphore block = new Semaphore(0);
 
-  private static groovy.ui.Console groovyConsole;
+  private static groovy.console.ui.Console groovyConsole;
 
   /**
    * add another dialog thread to the queue
@@ -3353,7 +3433,7 @@ public class Desktop extends jalview.jbgui.GDesktop
     myTopFrame.setDisplayedView(myTopFrame.alignPanel);
   }
 
-  public static groovy.ui.Console getGroovyConsole()
+  public static groovy.console.ui.Console getGroovyConsole()
   {
     return groovyConsole;
   }
@@ -3410,7 +3490,7 @@ public class Desktop extends jalview.jbgui.GDesktop
         {
           if (Platform.isAMacAndNotJS())
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Please ignore plist error - occurs due to problem with java 8 on OSX");
           }
         }
@@ -3644,45 +3724,51 @@ public class Desktop extends jalview.jbgui.GDesktop
   }
 
   /**
-   * closes the current instance window, disposes and forgets about it.
+   * closes the current instance window, but leaves the JVM running.
+   * Bypasses any shutdown prompts, but does not set window dispose on close in case JVM terminates.
    */
   public static void closeDesktop()
   {
     if (Desktop.instance != null)
     {
-      Desktop.instance.closeAll_actionPerformed(null);
-      Desktop.instance.setVisible(false);
       Desktop us = Desktop.instance;
-      Desktop.instance = null;
+      Desktop.instance.quitTheDesktop(false, false);
       // call dispose in a separate thread - try to avoid indirect deadlocks
-      new Thread(new Runnable() {
-        @Override
-        public void run()
+      if (us != null)
+      {
+        new Thread(new Runnable()
         {
-          ExecutorService dex = us.dialogExecutor;
-          if (dex!=null) {
-            dex.shutdownNow();
-            us.dialogExecutor=null;
-            us.block.drainPermits();
+          @Override
+          public void run()
+          {
+            ExecutorService dex = us.dialogExecutor;
+            if (dex != null)
+            {
+              dex.shutdownNow();
+              us.dialogExecutor = null;
+              us.block.drainPermits();
+            }
+            us.dispose();
           }
-          us.dispose();
-        }
-      }).start();
+        }).start();
+      }
     }
   }
 
   /**
-   * checks if any progress bars are being displayed in any of the windows managed by the desktop
+   * checks if any progress bars are being displayed in any of the windows
+   * managed by the desktop
+   * 
    * @return
    */
   public boolean operationsAreInProgress()
   {
     JInternalFrame[] frames = getAllFrames();
-    for (JInternalFrame frame:frames)
+    for (JInternalFrame frame : frames)
     {
       if (frame instanceof IProgressIndicator)
       {
-        if (((IProgressIndicator)frame).operationInProgress())
+        if (((IProgressIndicator) frame).operationInProgress())
         {
           return true;
         }
@@ -3690,4 +3776,128 @@ public class Desktop extends jalview.jbgui.GDesktop
     }
     return operationInProgress();
   }
+
+  /**
+   * keep track of modal JvOptionPanes open as modal dialogs for AlignFrames.
+   * The way the modal JInternalFrame is made means it cannot be a child of an
+   * AlignFrame, so closing the AlignFrame might leave the modal open :(
+   */
+  private static Map<AlignFrame, JInternalFrame> alignFrameModalMap = new HashMap<>();
+
+  protected static void addModal(AlignFrame af, JInternalFrame jif)
+  {
+    alignFrameModalMap.put(af, jif);
+  }
+
+  protected static void closeModal(AlignFrame af)
+  {
+    if (!alignFrameModalMap.containsKey(af))
+    {
+      return;
+    }
+    JInternalFrame jif = alignFrameModalMap.get(af);
+    if (jif != null)
+    {
+      try
+      {
+        jif.setClosed(true);
+      } catch (PropertyVetoException e)
+      {
+        e.printStackTrace();
+      }
+    }
+    alignFrameModalMap.remove(af);
+  }
+
+  public void nonBlockingDialog(String title, String message, String button,
+          int type, boolean scrollable, boolean modal)
+  {
+    nonBlockingDialog(title, message, null, button, type, scrollable, false,
+            modal, -1);
+  }
+
+  public void nonBlockingDialog(String title, String message,
+          String boxtext, String button, int type, boolean scrollable,
+          boolean html, boolean modal, int timeout)
+  {
+    nonBlockingDialog(32, 2, title, message, boxtext, button, type,
+            scrollable, html, modal, timeout);
+  }
+
+  public void nonBlockingDialog(int width, int height, String title,
+          String message, String boxtext, String button, int type,
+          boolean scrollable, boolean html, boolean modal, int timeout)
+  {
+    if (type < 0)
+    {
+      type = JvOptionPane.WARNING_MESSAGE;
+    }
+    JLabel jl = new JLabel(message);
+
+    JTextComponent jtc = null;
+    if (html)
+    {
+      JTextPane jtp = new JTextPane();
+      jtp.setContentType("text/html");
+      jtp.setEditable(false);
+      jtp.setAutoscrolls(true);
+      jtp.setText(boxtext);
+
+      jtc = jtp;
+    }
+    else
+    {
+      JTextArea jta = new JTextArea(height, width);
+      // jta.setLineWrap(true);
+      jta.setEditable(false);
+      jta.setWrapStyleWord(true);
+      jta.setAutoscrolls(true);
+      jta.setText(boxtext);
+
+      jtc = jta;
+    }
+
+    JScrollPane jsp = scrollable
+            ? new JScrollPane(jtc, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED,
+                    JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED)
+            : null;
+
+    JvOptionPane jvp = JvOptionPane.newOptionDialog(this);
+
+    JPanel jp = new JPanel();
+    jp.setLayout(new BoxLayout(jp, BoxLayout.Y_AXIS));
+
+    if (message != null)
+    {
+      jl.setAlignmentX(Component.LEFT_ALIGNMENT);
+      jp.add(jl);
+    }
+    if (boxtext != null)
+    {
+      if (scrollable)
+      {
+        jsp.setAlignmentX(Component.LEFT_ALIGNMENT);
+        jp.add(jsp);
+      }
+      else
+      {
+        jtc.setAlignmentX(Component.LEFT_ALIGNMENT);
+        jp.add(jtc);
+      }
+    }
+
+    jvp.setResponseHandler(JOptionPane.YES_OPTION, () -> {
+    });
+    jvp.setTimeout(timeout);
+    JButton jb = new JButton(button);
+    jvp.showDialogOnTopAsync(this, jp, title, JOptionPane.YES_OPTION, type,
+            null, new Object[]
+            { button }, button, modal, new JButton[] { jb }, false);
+  }
+
+  @Override
+  public AlignFrame getCurrentAlignFrame()
+  {
+    return Jalview.getInstance().getCurrentAlignFrame();
+  }
 }
index 4b8a1fd..6d5cb46 100644 (file)
@@ -129,6 +129,6 @@ public class EditNameDialog
     
     JvOptionPane.frameDialog(panel, title, JvOptionPane.PLAIN_MESSAGE,
             options, ok, actions, false);
-            */
+    */
   }
 }
index 7117508..606d843 100644 (file)
@@ -253,7 +253,7 @@ public class FeatureEditor
            */
           final String ft = features.get(featureIndex).getType();
           final String type = ft == null ? lastFeatureAdded : ft;
-          FeatureTypeSettings fcc = new FeatureTypeSettings(fr, type);
+          FeatureTypeSettings fcc = new FeatureTypeSettings(fr, type,true);
           fcc.setRequestFocusEnabled(true);
           fcc.requestFocus();
           fcc.addActionListener(new ActionListener()
index 2e9731d..57e5943 100644 (file)
@@ -45,6 +45,7 @@ import java.io.FileOutputStream;
 import java.io.InputStreamReader;
 import java.io.OutputStreamWriter;
 import java.io.PrintWriter;
+import java.io.Reader;
 import java.util.Arrays;
 import java.util.Comparator;
 import java.util.HashMap;
@@ -103,6 +104,8 @@ import jalview.datamodel.features.FeatureMatcherSet;
 import jalview.datamodel.features.FeatureMatcherSetI;
 import jalview.gui.Help.HelpId;
 import jalview.gui.JalviewColourChooser.ColourChooserListener;
+import jalview.io.DataSourceType;
+import jalview.io.FileParse;
 import jalview.io.JalviewFileChooser;
 import jalview.io.JalviewFileView;
 import jalview.schemes.FeatureColour;
@@ -955,6 +958,65 @@ public class FeatureSettings extends JPanel
     chooser.showOpenDialog(this);
   }
 
+  public static boolean loadFeatureSettingsFile(FeatureRenderer fr,
+          File file) throws Exception
+  {
+    InputStreamReader in = new InputStreamReader(new FileInputStream(file),
+            "UTF-8");
+    return loadFeatureSettingsFile(fr, in);
+  }
+
+  public static void loadFeatureSettingsFile(
+          FeatureRenderer featureRenderer, Object fileObject,
+          DataSourceType sourceType) throws Exception
+  {
+    FileParse fp = new FileParse(fileObject, sourceType);
+    loadFeatureSettingsFile(featureRenderer, fp.getReader());
+  }
+
+  private static boolean loadFeatureSettingsFile(FeatureRenderer fr,
+          Reader in) throws Exception
+  {
+    JAXBContext jc = JAXBContext.newInstance("jalview.xml.binding.jalview");
+    javax.xml.bind.Unmarshaller um = jc.createUnmarshaller();
+    XMLStreamReader streamReader = XMLInputFactory.newInstance()
+            .createXMLStreamReader(in);
+    JAXBElement<JalviewUserColours> jbe = um.unmarshal(streamReader,
+            JalviewUserColours.class);
+    JalviewUserColours jucs = jbe.getValue();
+
+    // JalviewUserColours jucs = JalviewUserColours.unmarshal(in);
+
+    /*
+     * load feature colours
+     */
+    for (int i = jucs.getColour().size() - 1; i >= 0; i--)
+    {
+      Colour newcol = jucs.getColour().get(i);
+      FeatureColourI colour = jalview.project.Jalview2XML
+              .parseColour(newcol);
+      fr.setColour(newcol.getName(), colour);
+      fr.setOrder(newcol.getName(), i / (float) jucs.getColour().size());
+    }
+
+    /*
+     * load feature filters; loaded filters will replace any that are
+     * currently defined, other defined filters are left unchanged 
+     */
+    for (int i = 0; i < jucs.getFilter().size(); i++)
+    {
+      Filter filterModel = jucs.getFilter().get(i);
+      String featureType = filterModel.getFeatureType();
+      FeatureMatcherSetI filter = jalview.project.Jalview2XML
+              .parseFilter(featureType, filterModel.getMatcherSet());
+      if (!filter.isEmpty())
+      {
+        fr.setFeatureFilter(featureType, filter);
+      }
+    }
+    return true;
+  }
+
   /**
    * Loads feature colours and filters from XML stored in the given file
    * 
@@ -962,50 +1024,21 @@ public class FeatureSettings extends JPanel
    */
   void load(File file)
   {
+    load(file, DataSourceType.FILE);
+  }
+
+  /**
+   * Loads feature colours and filters from XML at a specified source
+   * 
+   * @param file
+   *          - string or file or other object that allows FileParse to be
+   *          created
+   */
+  void load(Object file, DataSourceType sourceType)
+  {
     try
     {
-      InputStreamReader in = new InputStreamReader(
-              new FileInputStream(file), "UTF-8");
-
-      JAXBContext jc = JAXBContext
-              .newInstance("jalview.xml.binding.jalview");
-      javax.xml.bind.Unmarshaller um = jc.createUnmarshaller();
-      XMLStreamReader streamReader = XMLInputFactory.newInstance()
-              .createXMLStreamReader(in);
-      JAXBElement<JalviewUserColours> jbe = um.unmarshal(streamReader,
-              JalviewUserColours.class);
-      JalviewUserColours jucs = jbe.getValue();
-
-      // JalviewUserColours jucs = JalviewUserColours.unmarshal(in);
-
-      /*
-       * load feature colours
-       */
-      for (int i = jucs.getColour().size() - 1; i >= 0; i--)
-      {
-        Colour newcol = jucs.getColour().get(i);
-        FeatureColourI colour = jalview.project.Jalview2XML
-                .parseColour(newcol);
-        fr.setColour(newcol.getName(), colour);
-        fr.setOrder(newcol.getName(), i / (float) jucs.getColour().size());
-      }
-
-      /*
-       * load feature filters; loaded filters will replace any that are
-       * currently defined, other defined filters are left unchanged 
-       */
-      for (int i = 0; i < jucs.getFilter().size(); i++)
-      {
-        Filter filterModel = jucs.getFilter().get(i);
-        String featureType = filterModel.getFeatureType();
-        FeatureMatcherSetI filter = jalview.project.Jalview2XML
-                .parseFilter(featureType, filterModel.getMatcherSet());
-        if (!filter.isEmpty())
-        {
-          fr.setFeatureFilter(featureType, filter);
-        }
-      }
-
+      loadFeatureSettingsFile(fr, file, sourceType);
       /*
        * update feature settings table
        */
@@ -1019,7 +1052,8 @@ public class FeatureSettings extends JPanel
       }
     } catch (Exception ex)
     {
-      System.out.println("Error loading User Colour File\n" + ex);
+      jalview.bin.Console
+              .outPrintln("Error loading User Colour File\n" + ex);
     }
   }
 
@@ -1608,7 +1642,7 @@ public class FeatureSettings extends JPanel
     {
       Color newColor = gcol.getMaxColour();
       comp.setBackground(newColor);
-      // System.err.println("Width is " + w / 2);
+      // jalview.bin.Console.errPrintln("Width is " + w / 2);
       Icon ficon = new FeatureIcon(gcol, comp.getBackground(), w, h, thr);
       comp.setIcon(ficon);
       // tt+="RGB value: Max (" + newColor.getRed() + ", "
@@ -1787,11 +1821,15 @@ public class FeatureSettings extends JPanel
     {
       FeatureMatcherSetI theFilter = (FeatureMatcherSetI) filter;
       setOpaque(true);
-      String asText = theFilter.toString();
       setBackground(tbl.getBackground());
-      this.setText(asText);
       this.setIcon(null);
 
+      if (theFilter != null)
+      {
+        String asText = theFilter.toString();
+        this.setText(asText);
+      }
+
       if (isSelected)
       {
         if (selectedBorder == null)
@@ -1881,6 +1919,8 @@ public class FeatureSettings extends JPanel
            */
           String ttl = MessageManager
                   .formatMessage("label.select_colour_for", type);
+          Object last=(Boolean)table.getValueAt(selectedRow, SHOW_COLUMN);
+          table.setValueAt(Boolean.TRUE, selectedRow, SHOW_COLUMN);
           ColourChooserListener listener = new ColourChooserListener()
           {
             @Override
@@ -1888,12 +1928,14 @@ public class FeatureSettings extends JPanel
             {
               currentColor = new FeatureColour(c);
               table.setValueAt(currentColor, rowSelected, COLOUR_COLUMN);
+              table.setValueAt(Boolean.TRUE, selectedRow, SHOW_COLUMN);
               fireEditingStopped();
             }
 
             @Override
             public void cancel()
             {
+              table.setValueAt(last, selectedRow, SHOW_COLUMN);
               fireEditingStopped();
             }
           };
@@ -1905,7 +1947,9 @@ public class FeatureSettings extends JPanel
           /*
            * variable colour and filters dialog
            */
-          chooser = new FeatureTypeSettings(fr, type);
+          boolean last=(Boolean)table.getValueAt(selectedRow, SHOW_COLUMN);
+          table.setValueAt(Boolean.TRUE, selectedRow, SHOW_COLUMN);
+          chooser = new FeatureTypeSettings(fr, type,last);
           if (!Platform.isJS())
           /**
            * Java only
@@ -2031,7 +2075,9 @@ public class FeatureSettings extends JPanel
     {
       if (button == e.getSource())
       {
-        FeatureTypeSettings chooser = new FeatureTypeSettings(fr, type);
+        boolean last = fr.getFeaturesDisplayed().isVisible(type);
+        ((FeatureTableModel) table.getModel()).setValueAt(Boolean.TRUE, rowSelected, SHOW_COLUMN);
+        FeatureTypeSettings chooser = new FeatureTypeSettings(fr, type,last);
         chooser.addActionListener(this);
         chooser.setRequestFocusEnabled(true);
         chooser.requestFocus();
@@ -2063,6 +2109,8 @@ public class FeatureSettings extends JPanel
                 .getData()[rowSelected];
         data[COLOUR_COLUMN] = currentColor;
         data[FILTER_COLUMN] = currentFilter;
+        data[SHOW_COLUMN] = fr.getFeaturesDisplayed().isVisible(type);
+                
         fireEditingStopped();
         // SwingJS needs an explicit repaint() here,
         // rather than relying upon no validation having
@@ -2115,7 +2163,6 @@ public class FeatureSettings extends JPanel
     refreshDisplay();
   }
 }
-
 class FeatureIcon implements Icon
 {
   FeatureColourI gcol;
index 09bb2a3..79f4c88 100644 (file)
@@ -204,20 +204,23 @@ public class FeatureTypeSettings extends JalviewDialog
 
   private JPanel chooseFiltersPanel;
 
+  public boolean originalDisplay;
+
   /**
    * Constructor
    * 
    * @param frender
    * @param theType
+   * @param last - visibility of feature prior to adjustment
    */
-  public FeatureTypeSettings(FeatureRenderer frender, String theType)
+  public FeatureTypeSettings(FeatureRenderer frender, String theType, boolean last)
   {
     this.fr = frender;
     this.featureType = theType;
     ap = fr.ap;
     originalFilter = fr.getFeatureFilter(theType);
     originalColour = fr.getFeatureColours().get(theType);
-
+    originalDisplay = last;
     adjusting = true;
 
     try
@@ -1032,6 +1035,9 @@ public class FeatureTypeSettings extends JalviewDialog
   {
     fr.setColour(featureType, originalColour);
     fr.setFeatureFilter(featureType, originalFilter);
+    if (!originalDisplay) { 
+      fr.getFeaturesDisplayed().setHidden(featureType);
+    }
     refreshDisplay(true);
   }
 
@@ -1096,7 +1102,7 @@ public class FeatureTypeSettings extends JalviewDialog
   {
     if (featureSettings != null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "IMPLEMENTATION ISSUE: overwriting action listener for FeatureColourChooser");
     }
     featureSettings = listener;
index 658b34f..8829be9 100644 (file)
@@ -133,7 +133,7 @@ public class Help
         hb.setCurrentID(id.getId());
       } catch (BadIDException bad)
       {
-        System.out.println("Bad help link: " + id.getId()
+        jalview.bin.Console.outPrintln("Bad help link: " + id.getId()
                 + ": must match a target in help.jhm");
         throw bad;
       }
index c94dee0..dbffc72 100755 (executable)
@@ -22,6 +22,7 @@ package jalview.gui;
 
 import java.awt.BorderLayout;
 import java.awt.Color;
+import java.awt.Dimension;
 import java.awt.Font;
 import java.awt.FontMetrics;
 import java.awt.Graphics;
@@ -198,7 +199,7 @@ public class IdCanvas extends JPanel implements ViewportListenerI
 
     gg.translate(0, transY);
 
-    drawIds(gg, av, ss, es, searchResults);
+    drawIds(gg, av, ss, es, searchResults, true, getWidth());
 
     gg.translate(0, -transY);
 
@@ -255,7 +256,7 @@ public class IdCanvas extends JPanel implements ViewportListenerI
     gg.fillRect(0, 0, getWidth(), imgHeight);
 
     drawIds(gg, av, av.getRanges().getStartSeq(),
-            av.getRanges().getEndSeq(), searchResults);
+            av.getRanges().getEndSeq(), searchResults,true, getWidth());
 
     gg.dispose();
 
@@ -273,9 +274,12 @@ public class IdCanvas extends JPanel implements ViewportListenerI
    * @param startSeq
    * @param endSeq
    * @param selection
+   * @param forGUI when false rendering for print
+   * @param panelWidth width used to calculate righthand margin - usually idCanvas.getWidth()
+   * 
    */
   void drawIds(Graphics2D g, AlignViewport alignViewport,
-          final int startSeq, final int endSeq, List<SequenceI> selection)
+          final int startSeq, final int endSeq, List<SequenceI> selection, boolean forGUI, int panelWidth)
   {
     Font font = alignViewport.getFont();
     if (alignViewport.isSeqNameItalics())
@@ -303,12 +307,11 @@ public class IdCanvas extends JPanel implements ViewportListenerI
 
     if (alignViewport.getWrapAlignment())
     {
-      drawIdsWrapped(g, alignViewport, startSeq, getHeight());
+      drawIdsWrapped(g, alignViewport, startSeq, getHeight(), manuallyAdjusted ? panelWidth : -1,forGUI);
       return;
     }
 
     // Now draw the id strings
-    int panelWidth = getWidth();
     int xPos = 0;
 
     // Now draw the id strings
@@ -382,6 +385,25 @@ public class IdCanvas extends JPanel implements ViewportListenerI
   void drawIdsWrapped(Graphics2D g, AlignViewport alignViewport,
           int startSeq, int pageHeight)
   {
+    drawIdsWrapped(g, alignViewport, startSeq, pageHeight, -1, true);
+  }
+
+  /**
+   * render sequence IDs and annotation labels when wrapped - without GUI junk
+   * @param g
+   * @param av2
+   * @param i
+   * @param totalHeight
+   */
+  public void drawIdsWrappedNoGUI(Graphics2D g, AlignViewport av2, int i,
+          int totalHeight)
+  {
+    drawIdsWrapped(g, av2, totalHeight, totalHeight, i,false);
+  }
+
+  public void drawIdsWrapped(Graphics2D g, AlignViewport alignViewport,
+          int startSeq, int pageHeight, int idWidth, boolean forGUI)
+  {
     int alignmentWidth = alignViewport.getAlignment().getWidth();
     final int alheight = alignViewport.getAlignment().getHeight();
 
@@ -396,6 +418,8 @@ public class IdCanvas extends JPanel implements ViewportListenerI
     AnnotationLabels labels = null;
     if (alignViewport.isShowAnnotation())
     {
+      // in wrapped mode, no alignPanel reference is available
+      // FIXME: make the renderer not create a new object in wrapped mode everytime!
       labels = new AnnotationLabels(alignViewport);
     }
 
@@ -428,8 +452,23 @@ public class IdCanvas extends JPanel implements ViewportListenerI
 
       if (labels != null && alignViewport.isShowAnnotation())
       {
+        int getWidth = getWidth();
+        int thisIdWidth = getWidth;
         g.translate(0, ypos + (alheight * charHeight));
-        labels.drawComponent(g, getWidth());
+        if (!isManuallyAdjusted())
+        {
+          int getAnnotationsIdWidth = labels.drawLabels(g, false, -1, false,forGUI,
+                  null, false);
+          thisIdWidth = idWidth < 0 ? getAnnotationsIdWidth : idWidth;
+          if (thisIdWidth > getWidth)
+          {
+            this.setPreferredSize(
+                    new Dimension(thisIdWidth, this.getHeight()));
+            this.repaint();
+            alignViewport.setIdWidth(thisIdWidth);
+          }
+        }
+        labels.drawComponent(g, false, thisIdWidth, forGUI);
         g.translate(0, -ypos - (alheight * charHeight));
       }
 
@@ -585,4 +624,17 @@ public class IdCanvas extends JPanel implements ViewportListenerI
       repaint();
     }
   }
+
+  private boolean manuallyAdjusted = false;
+
+  public boolean isManuallyAdjusted()
+  {
+    return manuallyAdjusted;
+  }
+
+  public void setManuallyAdjusted(boolean b)
+  {
+    manuallyAdjusted = b;
+  }
+
 }
index 4ba0699..f1c4c83 100755 (executable)
@@ -20,8 +20,6 @@
  */
 package jalview.gui;
 
-import jalview.api.AlignViewportI;
-
 import java.awt.Color;
 import java.awt.Cursor;
 import java.awt.Graphics;
@@ -31,6 +29,9 @@ import java.awt.event.MouseMotionListener;
 
 import javax.swing.JPanel;
 
+import jalview.api.AlignViewportI;
+import jalview.bin.Cache;
+
 /**
  * DOCUMENT ME!
  * 
@@ -136,6 +137,18 @@ public class IdwidthAdjuster extends JPanel
       return;
     }
 
+    /*
+     * don't allow residue width to be < 1 in wrapped format
+     */
+    if (viewport.getWrapAlignment())
+    {
+      SeqCanvas sc = ap.getSeqPanel().seqCanvas;
+      if (sc != null && sc.getWrappedCanvasWidth(sc.getWidth() - dif) < 1)
+      {
+        return;
+      }
+    }
+
     oldX = evt.getX();
 
     /*
@@ -145,10 +158,41 @@ public class IdwidthAdjuster extends JPanel
     {
       return;
     }
+    
+    // TODO JAL-4260 - work out how to trigger recomputation of wrapped pages !
+    int curCol = viewport.getRanges().getStartRes()
+            + viewport.getRanges().getViewportWidth();
+    
+    viewport.setIdWidth(newWidth);
+
+    ap.validateAnnotationDimensions(false);
+    if (viewport.getWrapAlignment())
+    {
+      viewport.getRanges().scrollToWrappedVisible(
+              curCol - viewport.getRanges().getViewportWidth());
+    }
+    ap.paintAlignment(true, false);
+    
+    ap.getIdPanel().getIdCanvas().setManuallyAdjusted(true);
+  }
+
+  public void setWidth(int newWidth)
+  {
+    if (newWidth < MIN_ID_WIDTH
+            || ap.getIdPanel().getIdCanvas().isManuallyAdjusted())
+    {
+      return;
+    }
+    final AlignViewportI viewport = ap.getAlignViewport();
     viewport.setIdWidth(newWidth);
     ap.paintAlignment(true, false);
   }
 
+  public boolean manuallyAdjusted()
+  {
+    return ap.getIdPanel().getIdCanvas().isManuallyAdjusted();
+  }
+
   @Override
   public void mouseMoved(MouseEvent evt)
   {
@@ -167,8 +211,21 @@ public class IdwidthAdjuster extends JPanel
   @Override
   public void paintComponent(Graphics g)
   {
+    int width = getWidth();
+    int height = getHeight();
     g.setColor(Color.white);
-    g.fillRect(0, 0, getWidth(), getHeight());
+    g.fillRect(0, 0, width, height);
+
+    if (!Cache.getDefault(AnnotationLabels.RESIZE_MARGINS_MARK_PREF, false))
+    // && !ap.getAlignViewport().getWrapAlignment()) // now allowing adjustment
+    // in wrap mode
+    {
+      int spacer = Math.max(2, AnnotationLabels.HEIGHT_ADJUSTER_HEIGHT / 4);
+      g.setColor(Color.LIGHT_GRAY);
+      g.drawLine(width - 3 * spacer, 0, width - 3 * spacer, height / 2);
+      g.drawLine(width - spacer, 0, width - spacer, height / 2);
+    }
+
     setCursor(Cursor.getPredefinedCursor(Cursor.W_RESIZE_CURSOR));
   }
 }
index 8d28b1b..457ea1f 100644 (file)
@@ -108,7 +108,7 @@ public class ImageExporter
           String imageSource) throws ImageOutputException
   {
     doExport(file, parent, width, height, imageSource, null,
-            BitmapImageSizing.nullBitmapImageSizing());
+            BitmapImageSizing.defaultBitmapImageSizing());
   }
 
   public void doExport(File file, Component parent, int width, int height,
index 327eade..9ae764e 100644 (file)
@@ -122,7 +122,7 @@ public class JDatabaseTree extends JalviewDialog implements KeyListener
         }
         else
         {
-          System.err.println("dupe ig for : " + dbs[i] + " \t"
+          jalview.bin.Console.errPrintln("dupe ig for : " + dbs[i] + " \t"
                   + dbp.getDbName() + " (" + dbp.getDbSource() + ")");
           source.remove(tn);
         }
@@ -552,7 +552,7 @@ public class JDatabaseTree extends JalviewDialog implements KeyListener
   @Override
   public void setVisible(boolean arg0)
   {
-    System.out.println("setVisible: " + arg0);
+    jalview.bin.Console.outPrintln("setVisible: " + arg0);
     super.setVisible(arg0);
   }
 }
index c0efd4a..7a5daf7 100644 (file)
@@ -32,10 +32,12 @@ import java.awt.Toolkit;
 import java.awt.Window;
 import java.awt.event.ActionEvent;
 import java.awt.event.ActionListener;
+import java.awt.event.KeyEvent;
 import java.awt.event.MouseAdapter;
 import java.awt.event.MouseMotionAdapter;
 import java.beans.PropertyChangeEvent;
 import java.beans.PropertyChangeListener;
+import java.beans.PropertyVetoException;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.HashMap;
@@ -50,8 +52,11 @@ import javax.swing.JDialog;
 import javax.swing.JFrame;
 import javax.swing.JInternalFrame;
 import javax.swing.JLayeredPane;
+import javax.swing.JMenu;
+import javax.swing.JMenuBar;
 import javax.swing.JOptionPane;
 import javax.swing.JPanel;
+import javax.swing.JRootPane;
 import javax.swing.SwingUtilities;
 import javax.swing.UIManager;
 import javax.swing.event.InternalFrameEvent;
@@ -83,6 +88,13 @@ public class JvOptionPane extends JOptionPane
 
   private Map<Object, Runnable> callbacks = new HashMap<>();
 
+  private int timeout = -1;
+
+  public void setTimeout(int i)
+  {
+    timeout = i;
+  }
+
   /*
    * JalviewJS reports user choice in the dialog as the selected option (text);
    * this list allows conversion to index (int)
@@ -717,7 +729,8 @@ public class JvOptionPane extends JOptionPane
 
   private static void outputMessage(Object message)
   {
-    System.out.println(">>> JOption Message : " + message.toString());
+    jalview.bin.Console
+            .outPrintln(">>> JOption Message : " + message.toString());
   }
 
   public static Object getMockResponse()
@@ -845,6 +858,42 @@ public class JvOptionPane extends JOptionPane
                   "Supplied buttons array not the same length as supplied options array.");
           break NOTNULL;
         }
+
+        // run through buttons for initialValue first so we can set (and start)
+        // a final timeoutThreadF to include (and interrupt) in the button
+        // actions
+        Thread timeoutThread = null;
+        for (int i = 0; i < options.length; i++)
+        {
+          Object o = options[i];
+          JButton jb = buttons[i];
+          if (o.equals(initialValue))
+          {
+            if (timeout > 0 && jb != null && jb instanceof JButton)
+            {
+              // after timeout ms click the default button
+              timeoutThread = new Thread(() -> {
+                try
+                {
+                  Thread.sleep(timeout);
+                } catch (InterruptedException e)
+                {
+                  Console.debug(
+                          "Dialog timeout interrupted.  Probably a button pressed.");
+                }
+                jb.doClick();
+              });
+            }
+            initialValueButton = jb;
+            break;
+          }
+        }
+        final Thread timeoutThreadF = timeoutThread;
+        if (timeoutThreadF != null)
+        {
+          timeoutThreadF.start();
+        }
+
         int[] buttonActions = { JOptionPane.YES_OPTION,
             JOptionPane.NO_OPTION, JOptionPane.CANCEL_OPTION };
         for (int i = 0; i < options.length; i++)
@@ -854,9 +903,6 @@ public class JvOptionPane extends JOptionPane
                   "Setting button " + i + " to '" + o.toString() + "'");
           JButton jb = buttons[i];
 
-          if (o.equals(initialValue))
-            initialValueButton = jb;
-
           int buttonAction = buttonActions[i];
           Runnable action = callbacks.get(buttonAction);
           jb.setText((String) o);
@@ -865,6 +911,10 @@ public class JvOptionPane extends JOptionPane
             @Override
             public void actionPerformed(ActionEvent e)
             {
+              if (timeoutThreadF != null)
+              {
+                timeoutThreadF.interrupt();
+              }
 
               Object obj = e.getSource();
               if (obj == null || !(obj instanceof Component))
@@ -1071,9 +1121,16 @@ public class JvOptionPane extends JOptionPane
     if (parentComponent != this
             && !(parentComponent == null && Desktop.instance == null))
     {
+      // note the parent goes back to a JRootPane so is probably
+      // Desktop.getDesktop()
       JInternalFrame jif = this.createInternalFrame(
               parentComponent != null ? parentComponent : Desktop.instance,
               title);
+      // connect to the alignFrame using a map in Desktop
+      if (parentComponent instanceof AlignFrame)
+      {
+        Desktop.addModal((AlignFrame) parentComponent, jif);
+      }
       jif.setFrameIcon(null);
       jif.addInternalFrameListener(new InternalFrameListener()
       {
@@ -1129,7 +1186,13 @@ public class JvOptionPane extends JOptionPane
 
   private void internalDialogHandleResponse()
   {
-    String responseString = (String) this.getValue();
+    Object value = this.getValue();
+    if (value == null
+            || (value instanceof Integer && (Integer) value == -1))
+    {
+      return;
+    }
+    String responseString = value.toString();
     int response = ourOptions.indexOf(responseString);
 
     if (!Platform.isJS())
@@ -1246,6 +1309,17 @@ public class JvOptionPane extends JOptionPane
           int JOPTIONPANE_MESSAGETYPE, Icon icon, Object[] options,
           Object initialValue, boolean modal, JButton[] buttons)
   {
+    showDialogOnTopAsync(dialogParent, label, actionString,
+            JOPTIONPANE_OPTION, JOPTIONPANE_MESSAGETYPE, icon, options,
+            initialValue, modal, buttons, true);
+  }
+
+  public void showDialogOnTopAsync(JFrame dialogParent, Object label,
+          String actionString, int JOPTIONPANE_OPTION,
+          int JOPTIONPANE_MESSAGETYPE, Icon icon, Object[] options,
+          Object initialValue, boolean modal, JButton[] buttons,
+          boolean dispose)
+  {
     if (!isInteractiveMode())
     {
       handleResponse(getMockResponse());
@@ -1260,6 +1334,7 @@ public class JvOptionPane extends JOptionPane
 
     // A better hack which works is to create a new JFrame parent with
     // setAlwaysOnTop(true)
+    boolean parentOnTop = dialogParent.isAlwaysOnTop();
     dialogParent.setAlwaysOnTop(true);
     parentComponent = dialogParent;
 
@@ -1267,8 +1342,13 @@ public class JvOptionPane extends JOptionPane
             JOPTIONPANE_MESSAGETYPE, icon, options, initialValue, modal,
             buttons);
 
-    dialogParent.setAlwaysOnTop(false);
-    dialogParent.dispose();
+    dialogParent.setAlwaysOnTop(parentOnTop);
+
+    if (dispose)
+    {
+      dialogParent.setAlwaysOnTop(false);
+      dialogParent.dispose();
+    }
   }
 
   /**
@@ -1499,11 +1579,26 @@ public class JvOptionPane extends JOptionPane
     lp.add(modalInterceptor);
     f.toFront();
 
+    // disable the main menu bar if in Linux
+    JMenuBar menubar = null;
+    if (Platform.isLinux())
+    {
+      JRootPane rootpane = Desktop.getDesktop().getRootPane();
+      menubar = rootpane.getJMenuBar();
+    }
+
     // We need to explicitly dispatch events when we are blocking the event
     // dispatch thread.
     EventQueue queue = Toolkit.getDefaultToolkit().getSystemEventQueue();
     try
     {
+      if (menubar != null)
+      {
+        // don't allow clicks on main menu on linux due to a hanging bug.
+        // see JAL-4214.
+        setMenusEnabled(menubar, false);
+      }
+
       while (!f.isClosed())
       {
         if (EventQueue.isDispatchThread())
@@ -1515,11 +1610,25 @@ public class JvOptionPane extends JOptionPane
           // EventQueue.dispatchEvent() directly, because it is
           // protected, unfortunately.
           if (ev instanceof ActiveEvent)
+          {
             ((ActiveEvent) ev).dispatch();
-          else if (ev.getSource() instanceof Component)
+          }
+          else if (ev instanceof KeyEvent && ((KeyEvent) ev).isControlDown()
+                  && menubar != null)
+          {
+            // temporarily enable menus to send Ctrl+? KeyEvents
+            setMenusEnabled(menubar, true);
             ((Component) ev.getSource()).dispatchEvent(ev);
+            setMenusEnabled(menubar, false);
+          }
           else if (ev.getSource() instanceof MenuComponent)
+          {
             ((MenuComponent) ev.getSource()).dispatchEvent(ev);
+          }
+          else if (ev.getSource() instanceof Component)
+          {
+            ((Component) ev.getSource()).dispatchEvent(ev);
+          }
           // Other events are ignored as per spec in
           // EventQueue.dispatchEvent
         }
@@ -1534,14 +1643,34 @@ public class JvOptionPane extends JOptionPane
       // If we get interrupted, then leave the modal state.
     } finally
     {
+      // re-enable the main menu bar
+      if (menubar != null)
+      {
+        setMenusEnabled(menubar, true);
+      }
+
       // Clean up the modal interceptor.
       lp.remove(modalInterceptor);
 
+      // unpaint the frame
+      f.setVisible(false);
+
+      // close the frame
+      try
+      {
+        f.setClosed(true);
+      } catch (PropertyVetoException e)
+      {
+        f.doDefaultCloseAction();
+      }
+
       // Remove the internal frame from its parent, so it is no longer
       // lurking around and clogging memory.
       Container parent = f.getParent();
       if (parent != null)
+      {
         parent.remove(f);
+      }
     }
   }
 
@@ -1612,4 +1741,14 @@ public class JvOptionPane extends JOptionPane
 
     return jvop;
   }
+
+  private static void setMenusEnabled(JMenuBar menubar, boolean b)
+  {
+    for (int i = 0; i < menubar.getMenuCount(); i++)
+    {
+      JMenu menu = menubar.getMenu(i);
+      menu.setEnabled(b);
+    }
+  }
+
 }
index e0427cc..f05110f 100644 (file)
@@ -713,7 +713,7 @@ public class OptsAndParamsPage
             }
           } catch (NumberFormatException e)
           {
-            System.err.println(e.toString());
+            jalview.bin.Console.errPrintln(e.toString());
           }
           if (minValue != null || maxValue != null)
           {
@@ -750,7 +750,7 @@ public class OptsAndParamsPage
             }
           } catch (NumberFormatException e)
           {
-            System.err.println(e.toString());
+            jalview.bin.Console.errPrintln(e.toString());
           }
           if (minValue != null && maxValue != null)
           {
index 953fdc5..36849b0 100755 (executable)
@@ -194,7 +194,7 @@ public class PaintRefresher
           {
             // raise an implementation warning here - not sure if this situation
             // will ever occur
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "IMPLEMENTATION PROBLEM: DATASET out of sync due to an insert whilst calling PaintRefresher.validateSequences(AlignmentI, ALignmentI)");
           }
           List<SequenceI> alsq = comp.getSequences();
index c4b5367..b5b6ffc 100755 (executable)
@@ -104,7 +104,7 @@ public class PairwiseAlignPanel extends GPairwiseAlignPanel
 
         if (!first)
         {
-          System.out.println(DASHES);
+          jalview.bin.Console.outPrintln(DASHES);
           textarea.append(DASHES);
         }
         first = false;
@@ -139,7 +139,7 @@ public class PairwiseAlignPanel extends GPairwiseAlignPanel
 
     for (int i = 0; i < seqs.length; i++)
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               String.format("%3d %s", i + 1, seqs[i].getDisplayId(true)));
     }
 
@@ -151,7 +151,7 @@ public class PairwiseAlignPanel extends GPairwiseAlignPanel
     {
       System.out.print(String.format("%7d", i + 1));
     }
-    System.out.println();
+    jalview.bin.Console.outPrintln();
 
     for (int i = 0; i < seqs.length; i++)
     {
@@ -163,10 +163,10 @@ public class PairwiseAlignPanel extends GPairwiseAlignPanel
          */
         System.out.print(String.format("%7.3f", scores[i][j] / totscore));
       }
-      System.out.println();
+      jalview.bin.Console.outPrintln();
     }
 
-    System.out.println("\n");
+    jalview.bin.Console.outPrintln("\n");
   }
 
   /**
index 88c1292..109c140 100644 (file)
@@ -906,6 +906,7 @@ public class PopupMenu extends JPopupMenu implements ColourChangeListener
     if (Platform.isJS())
     {
       details = new JInternalFrame();
+      details.setFrameIcon(null);
       JPanel panel = new JPanel(new BorderLayout());
       panel.setOpaque(true);
       panel.setBackground(Color.white);
@@ -1834,6 +1835,7 @@ public class PopupMenu extends JPopupMenu implements ColourChangeListener
       pane.setBackground(Color.WHITE);
       pane.add(textLabel, BorderLayout.NORTH);
       frame = new JInternalFrame();
+      frame.setFrameIcon(null);
       frame.getContentPane().add(new JScrollPane(pane));
     }
     else
@@ -2189,7 +2191,7 @@ public class PopupMenu extends JPopupMenu implements ColourChangeListener
 
     String[] omitHidden = null;
 
-    System.out.println("PROMPT USER HERE"); // TODO: decide if a prompt happens
+    jalview.bin.Console.outPrintln("PROMPT USER HERE"); // TODO: decide if a prompt happens
     // or we simply trust the user wants
     // wysiwig behaviour
 
index 011d810..d68d95f 100644 (file)
@@ -231,7 +231,7 @@ public class ProgressBar implements IProgressIndicator
         final JPanel progressPanel = progressBars.get(id);
         if (progressPanel == null)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "call setProgressBar before registering the progress bar's handler.");
           return;
         }
index 705102a..62dce24 100644 (file)
@@ -121,7 +121,7 @@ public class PymolBindingModel extends AAStructureBindingModel
   protected List<String> executeCommand(StructureCommandI command,
           boolean getReply)
   {
-    // System.out.println(command.toString()); // debug
+    // jalview.bin.Console.outPrintln(command.toString()); // debug
     return pymolManager.sendCommand(command, getReply);
   }
 
index ad7684e..6020135 100644 (file)
@@ -294,7 +294,7 @@ public class QuitHandler
       return QResponse.QUIT;
 
     int size = 0;
-    AlignFrame[] afArray = Desktop.getAlignFrames();
+    AlignFrame[] afArray = Desktop.getDesktopAlignFrames();
     if (!(afArray == null || afArray.length == 0))
     {
       for (int i = 0; i < afArray.length; i++)
index 8d66a44..f487011 100755 (executable)
@@ -184,7 +184,7 @@ public class RedundancyPanel extends GSliderPanel implements Runnable
 
     validate();
     sliderValueChanged();
-    // System.out.println((System.currentTimeMillis()-start));
+    // jalview.bin.Console.outPrintln((System.currentTimeMillis()-start));
   }
 
   void sliderValueChanged()
index 8ae5408..9b199fd 100644 (file)
@@ -53,7 +53,7 @@ public class RestInputParamEditDialog extends GRestInputParamEditDialog
               .newInstance());
     } catch (Throwable x)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Unexpected exception when instantiating rest input type.");
       x.printStackTrace();
     }
@@ -166,7 +166,7 @@ public class RestInputParamEditDialog extends GRestInputParamEditDialog
           updated = true;
         } catch (InvalidArgumentException ex)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "IMPLEMENTATION ERROR: Invalid argument for type : "
                           + typeList.getSelectedValue() + "\n");
           ex.printStackTrace();
@@ -215,7 +215,7 @@ public class RestInputParamEditDialog extends GRestInputParamEditDialog
         types.add(jtype.getURLtokenPrefix());
       } catch (Throwable x)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Unexpected exception when instantiating rest input type.");
         x.printStackTrace();
       }
index cda76d9..8953626 100644 (file)
@@ -363,7 +363,7 @@ public class RestServiceEditorPane extends GRestServiceEditorPane
                 mtch.group(2) + ":" + mtch.group(3), mtch.group(1),
                 mtch.group(2), mtch.group(3), inputTypes, warnings))
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "IMPLEMENTATION PROBLEM: Cannot parse RestService input parameter string '"
                           + its + "'" + "\n" + warnings);
         }
@@ -389,7 +389,7 @@ public class RestServiceEditorPane extends GRestServiceEditorPane
         } catch (Throwable x)
         {
 
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "IMPLEMENTATION PROBLEM: Cannot parse RestService output parameter string '"
                           + its + "'" + "\n" + warnings);
         }
@@ -399,7 +399,7 @@ public class RestServiceEditorPane extends GRestServiceEditorPane
     }
     else
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "IMPLEMENTATION PROBLEM: Restservice generated from GUI is invalid\n"
                       + warnings);
 
index 422601d..a186ce6 100755 (executable)
@@ -107,14 +107,7 @@ public class ScalePanel extends JPanel
   @Override
   public void mousePressed(MouseEvent evt)
   {
-    int x = (evt.getX() / av.getCharWidth()) + av.getRanges().getStartRes();
-    final int res;
-
-    if (av.hasHiddenColumns())
-    {
-      x = av.getAlignment().getHiddenColumns().visibleToAbsoluteColumn(x);
-    }
-    res = Math.min(x, av.getAlignment().getWidth() - 1);
+    int res = ap.getSeqPanel().findAlignmentColumn(evt);
 
     min = res;
     max = res;
@@ -286,18 +279,8 @@ public class ScalePanel extends JPanel
     mouseDragging = false;
     ap.getSeqPanel().stopScrolling();
 
-    // todo res calculation should be a method on AlignViewport
-    int xCords = Math.max(0, evt.getX()); // prevent negative X coordinates
-    ViewportRanges ranges = av.getRanges();
-    int res = (xCords / av.getCharWidth()) + ranges.getStartRes();
-    res = Math.min(res, ranges.getEndRes());
-    if (av.hasHiddenColumns())
-    {
-      res = av.getAlignment().getHiddenColumns()
-              .visibleToAbsoluteColumn(res);
-    }
-    res = Math.max(0, res);
-
+    int res = ap.getSeqPanel().findAlignmentColumn(evt);
+    
     if (!stretchingGroup)
     {
       if (evt.isPopupTrigger()) // Windows: mouseReleased
@@ -350,16 +333,12 @@ public class ScalePanel extends JPanel
   @Override
   public void mouseDragged(MouseEvent evt)
   {
-    mouseDragging = true;
+    mouseDragging = true;  
+    int res = ap.getSeqPanel().findAlignmentColumn(evt);
+    
     ColumnSelection cs = av.getColumnSelection();
-    HiddenColumns hidden = av.getAlignment().getHiddenColumns();
-
-    int res = (evt.getX() / av.getCharWidth())
-            + av.getRanges().getStartRes();
-    res = Math.max(0, res);
-    res = hidden.visibleToAbsoluteColumn(res);
-    res = Math.min(res, av.getAlignment().getWidth() - 1);
-    min = Math.min(res, min);
+    
+    min = Math.min(res,min);
     max = Math.max(res, max);
 
     SequenceGroup sg = av.getSelectionGroup();
@@ -410,22 +389,18 @@ public class ScalePanel extends JPanel
   {
     this.setToolTipText(null);
     reveal = null;
-    if (!av.hasHiddenColumns())
-    {
-      int res = (evt.getX() / av.getCharWidth())
-              + av.getRanges().getStartRes();
-      highlightAllStructPos(res);
+    final int res = ap.getSeqPanel().findAlignmentColumn(evt);
+    
+    highlightAllStructPos(res);
+    if (!av.hasHiddenColumns()) {
       return;
     }
-
-    int res = (evt.getX() / av.getCharWidth())
-            + av.getRanges().getStartRes();
-
     reveal = av.getAlignment().getHiddenColumns()
-            .getRegionWithEdgeAtRes(res);
-
-    res = av.getAlignment().getHiddenColumns().visibleToAbsoluteColumn(res);
-    highlightAllStructPos(res);
+            .getRegionWithEdgeAtRes(av.getAlignment().getHiddenColumns().absoluteToVisibleColumn(res));
+    if (reveal==null)
+    {
+      return;
+    }
     ToolTipManager.sharedInstance().registerComponent(this);
     this.setToolTipText(
             MessageManager.getString("label.reveal_hidden_columns"));
index 62e48d2..e42acf3 100755 (executable)
@@ -35,6 +35,7 @@ import java.util.List;
 
 import javax.swing.JPanel;
 
+import jalview.api.SequenceRenderer;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.HiddenColumns;
 import jalview.datamodel.SearchResultsI;
@@ -107,7 +108,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
   {
     this.av = ap.av;
     fr = new FeatureRenderer(ap);
-    seqRdr = new SequenceRenderer(av);
+    seqRdr = new jalview.gui.SequenceRenderer(av);
     setLayout(new BorderLayout());
     PaintRefresher.Register(this, av.getSequenceSetId());
     setBackground(Color.white);
@@ -322,7 +323,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
 
       if (vertical > 0) // scroll down
       {
-        startSeq = endSeq - vertical;
+        startSeq = endSeq - vertical + 1;
 
         if (startSeq < ranges.getStartSeq())
         { // ie scrolling too fast, more than a page at a time
@@ -330,12 +331,12 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
         }
         else
         {
-          transY = img.getHeight() - ((vertical + 1) * charHeight);
+          transY = img.getHeight() - (vertical * charHeight);
         }
       }
-      else if (vertical < 0)
+      else if (vertical < 0) // scroll up
       {
-        endSeq = startSeq - vertical;
+        endSeq = startSeq - vertical - 1;
 
         if (endSeq > ranges.getEndSeq())
         {
@@ -343,7 +344,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
         }
       }
 
-      // System.err.println(">>> FastPaint to " + transX + " " + transY + " "
+      // jalview.bin.Console.errPrintln(">>> FastPaint to " + transX + " " +
+      // transY + " "
       // + horizontal + " " + vertical + " " + startRes + " " + endRes
       // + " " + startSeq + " " + endSeq);
 
@@ -355,14 +357,15 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
       /** @j2sNative xxi = this.img */
 
       gg.translate(transX, transY);
-      drawPanel(gg, startRes, endRes, startSeq, endSeq, 0);
+      drawPanel(seqRdr, gg, startRes, endRes, startSeq, endSeq, 0);
       gg.translate(-transX, -transY);
       gg.dispose();
 
       // Call repaint on alignment panel so that repaints from other alignment
       // panel components can be aggregated. Otherwise performance of the
       // overview window and others may be adversely affected.
-      // System.out.println("SeqCanvas fastPaint() repaint() request...");
+      // jalview.bin.Console.outPrintln("SeqCanvas fastPaint() repaint()
+      // request...");
       av.getAlignPanel().repaint();
     } finally
     {
@@ -455,11 +458,12 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
 
       if (av.getWrapAlignment())
       {
-        drawWrappedPanel(gg, getWidth(), getHeight(), ranges.getStartRes());
+        drawWrappedPanel(seqRdr, gg, getWidth(), getHeight(),
+                ranges.getStartRes());
       }
       else
       {
-        drawPanel(gg, startRes, endRes, startSeq, endSeq, 0);
+        drawPanel(seqRdr, gg, startRes, endRes, startSeq, endSeq, 0);
       }
 
       drawSelectionGroup(gg, startRes, endRes, startSeq, endSeq);
@@ -491,7 +495,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
   public void drawPanelForPrinting(Graphics g1, int startRes, int endRes,
           int startSeq, int endSeq)
   {
-    drawPanel(g1, startRes, endRes, startSeq, endSeq, 0);
+    SequenceRenderer localSeqR = new jalview.gui.SequenceRenderer(av);
+    drawPanel(localSeqR, g1, startRes, endRes, startSeq, endSeq, 0);
 
     drawSelectionGroup((Graphics2D) g1, startRes, endRes, startSeq, endSeq);
   }
@@ -511,7 +516,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
   public void drawWrappedPanelForPrinting(Graphics g, int canvasWidth,
           int canvasHeight, int startRes)
   {
-    drawWrappedPanel(g, canvasWidth, canvasHeight, startRes);
+    SequenceRenderer localSeqR = new jalview.gui.SequenceRenderer(av);
+    drawWrappedPanel(localSeqR, g, canvasWidth, canvasHeight, startRes);
 
     SequenceGroup group = av.getSelectionGroup();
     if (group != null)
@@ -550,6 +556,20 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
     return (canvasWidth - labelWidthEast - labelWidthWest) / charWidth;
   }
 
+  public int getMinimumWrappedCanvasWidth()
+  {
+    int charWidth = av.getCharWidth();
+    FontMetrics fm = getFontMetrics(av.getFont());
+    int labelWidth = 0;
+    if (av.getScaleRightWrapped() || av.getScaleLeftWrapped())
+    {
+      labelWidth = getLabelWidth(fm);
+    }
+    labelWidthEast = av.getScaleRightWrapped() ? labelWidth : 0;
+    labelWidthWest = av.getScaleLeftWrapped() ? labelWidth : 0;
+    return labelWidthEast + labelWidthWest + charWidth;
+  }
+
   /**
    * Returns a pixel width sufficient to show the largest sequence coordinate
    * (end position) in the alignment, calculated as the FontMetrics width of
@@ -594,8 +614,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
    * @param startColumn
    *          the first column (0...) of the alignment to draw
    */
-  public void drawWrappedPanel(Graphics g, int canvasWidth,
-          int canvasHeight, final int startColumn)
+  public void drawWrappedPanel(SequenceRenderer seqRdr, Graphics g,
+          int canvasWidth, int canvasHeight, final int startColumn)
   {
     int wrappedWidthInResidues = calculateWrappedGeometry(canvasWidth,
             canvasHeight);
@@ -623,7 +643,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
     {
       int endColumn = Math.min(maxWidth,
               start + wrappedWidthInResidues - 1);
-      drawWrappedWidth(g, ypos, start, endColumn, canvasHeight);
+      drawWrappedWidth(seqRdr, g, ypos, start, endColumn, canvasHeight);
       ypos += wrappedRepeatHeightPx;
       start += wrappedWidthInResidues;
       currentWidth++;
@@ -716,8 +736,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
    * @param endColumn
    * @param canvasHeight
    */
-  protected void drawWrappedWidth(Graphics g, final int ypos,
-          final int startColumn, final int endColumn,
+  protected void drawWrappedWidth(SequenceRenderer seqRdr, Graphics g,
+          final int ypos, final int startColumn, final int endColumn,
           final int canvasHeight)
   {
     ViewportRanges ranges = av.getRanges();
@@ -745,8 +765,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
     g.fillRect(0, ypos, (endx - startColumn + 1) * charWidth,
             wrappedRepeatHeightPx);
 
-    drawPanel(g, startColumn, endx, 0, av.getAlignment().getHeight() - 1,
-            ypos);
+    drawPanel(seqRdr, g, startColumn, endx, 0,
+            av.getAlignment().getHeight() - 1, ypos);
 
     int cHeight = av.getAlignment().getHeight() * av.getCharHeight();
 
@@ -950,6 +970,10 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
    * between the markers is drawn separately, followed by the hidden column
    * marker.
    * 
+   * @param localSeqR
+   *          - sequence renderer implementation - when null, uses the one used
+   *          for rendering interactive GUI
+   * 
    * @param g1
    *          the graphics context, positioned at the first residue to be drawn
    * @param startRes
@@ -963,15 +987,20 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
    * @param yOffset
    *          vertical offset at which to draw (for wrapped alignments)
    */
-  public void drawPanel(Graphics g1, final int startRes, final int endRes,
-          final int startSeq, final int endSeq, final int yOffset)
+  public void drawPanel(SequenceRenderer localSeqR, Graphics g1,
+          final int startRes, final int endRes, final int startSeq,
+          final int endSeq, final int yOffset)
   {
     int charHeight = av.getCharHeight();
     int charWidth = av.getCharWidth();
 
+    if (localSeqR == null)
+    {
+      localSeqR = seqRdr;
+    }
     if (!av.hasHiddenColumns())
     {
-      draw(g1, startRes, endRes, startSeq, endSeq, yOffset);
+      draw(localSeqR, g1, startRes, endRes, startSeq, endSeq, yOffset);
     }
     else
     {
@@ -995,7 +1024,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
          */
         g1.translate(screenY * charWidth, 0);
 
-        draw(g1, blockStart, blockEnd, startSeq, endSeq, yOffset);
+        draw(localSeqR, g1, blockStart, blockEnd, startSeq, endSeq,
+                yOffset);
 
         /*
          * draw the downline of the hidden column marker (ScalePanel draws the
@@ -1021,6 +1051,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
   /**
    * Draws a region of the visible alignment
    * 
+   * @param seqRdr
+   * 
    * @param g1
    * @param startRes
    *          offset of the first column in the visible region (0..)
@@ -1033,8 +1065,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
    * @param yOffset
    *          vertical offset at which to draw (for wrapped alignments)
    */
-  private void draw(Graphics g, int startRes, int endRes, int startSeq,
-          int endSeq, int offset)
+  private void draw(SequenceRenderer seqRdr, Graphics g, int startRes,
+          int endRes, int startSeq, int endSeq, int offset)
   {
     int charHeight = av.getCharHeight();
     int charWidth = av.getCharWidth();
@@ -1376,7 +1408,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
         else if (inGroup)
         {
           drawVerticals(g, sx, xwidth, visWidth, oldY, bottom);
-          drawHorizontals(g, sx, xwidth, visWidth, top, bottom+1);
+          drawHorizontals(g, sx, xwidth, visWidth, top, bottom);
 
           // reset top and bottom
           top = -1;
@@ -1387,8 +1419,9 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
       if (inGroup)
       {
         sy = verticalOffset + ((i - startSeq) * charHeight);
-        drawVerticals(g, sx, xwidth, visWidth, oldY, bottom);
-        drawHorizontals(g, sx, xwidth, visWidth, top, bottom+1);
+        drawVerticals(g, sx, xwidth, visWidth, oldY,
+                bottom == -1 ? sy : bottom);
+        drawHorizontals(g, sx, xwidth, visWidth, top, bottom);
       }
     }
   }
@@ -1462,14 +1495,14 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
     // group
     if (sx >= 0 && sx < visWidth)
     {
-      g.drawLine(sx, oldY, sx, sy);
+      g.drawLine(sx, oldY, sx, sy-1);
     }
 
     // if end position is visible, draw vertical line to right of
     // group
     if (sx + xwidth < visWidth)
     {
-      g.drawLine(sx + xwidth, oldY, sx + xwidth, sy);
+      g.drawLine(sx + xwidth, oldY, sx + xwidth, sy-1);
     }
   }
 
@@ -1653,7 +1686,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
       int transY = (firstSeq - ranges.getStartSeq()) * av.getCharHeight();
       Graphics gg = img.getGraphics();
       gg.translate(transX, transY);
-      drawPanel(gg, firstCol, lastCol, firstSeq, lastSeq, 0);
+      drawPanel(seqRdr, gg, firstCol, lastCol, firstSeq, lastSeq, 0);
       gg.translate(-transX, -transY);
       gg.dispose();
     }
@@ -1665,7 +1698,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
   public void propertyChange(PropertyChangeEvent evt)
   {
     String eventName = evt.getPropertyName();
-    // System.err.println(">>SeqCanvas propertyChange " + eventName);
+    // jalview.bin.Console.errPrintln(">>SeqCanvas propertyChange " +
+    // eventName);
     if (eventName.equals(SequenceGroup.SEQ_GROUP_CHANGED))
     {
       fastPaint = true;
@@ -1675,7 +1709,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
     else if (eventName.equals(ViewportRanges.MOVE_VIEWPORT))
     {
       fastPaint = false;
-      // System.err.println("!!!! fastPaint false from MOVE_VIEWPORT");
+      // jalview.bin.Console.errPrintln("!!!! fastPaint false from
+      // MOVE_VIEWPORT");
       repaint();
       return;
     }
@@ -1805,7 +1840,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
       if (scrollX < 0)
       {
         int startRes = ranges.getStartRes();
-        drawWrappedWidth(gg, wrappedSpaceAboveAlignment, startRes,
+        drawWrappedWidth(seqRdr, gg, wrappedSpaceAboveAlignment, startRes,
                 startRes - scrollX - 1, getHeight());
       }
       else
@@ -1879,7 +1914,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
               wrappedRepeatHeightPx);
       gg.translate(-xOffset, 0);
 
-      drawWrappedWidth(gg, ypos, startRes, endRes, canvasHeight);
+      drawWrappedWidth(seqRdr, gg, ypos, startRes, endRes, canvasHeight);
 
     }
 
@@ -1912,7 +1947,7 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
 
     if (startRes < ranges.getVisibleAlignmentWidth())
     {
-      drawWrappedWidth(gg, ypos, startRes, endRes, canvasHeight);
+      drawWrappedWidth(seqRdr, gg, ypos, startRes, endRes, canvasHeight);
     }
 
     /*
@@ -2133,8 +2168,8 @@ public class SeqCanvas extends JPanel implements ViewportListenerI
               {
                 matchFound = true;
                 gg.translate(transX, transY);
-                drawPanel(gg, displayColumn, displayColumn, seqNo, seqNo,
-                        yOffset);
+                drawPanel(seqRdr, gg, displayColumn, displayColumn, seqNo,
+                        seqNo, yOffset);
                 gg.translate(-transX, -transY);
               }
             }
index c0a86df..3560efd 100755 (executable)
@@ -377,7 +377,7 @@ public class SeqCanvas extends JComponent
       } catch (OutOfMemoryError er)
       {
         System.gc();
-        System.err.println("SeqCanvas OutOfMemory Redraw Error.\n" + er);
+        jalview.bin.Console.errPrintln("SeqCanvas OutOfMemory Redraw Error.\n" + er);
         new OOMWarning("Creating alignment image for display", er);
 
         return;
index 55f06fc..d39f937 100644 (file)
@@ -137,7 +137,7 @@ public class SeqPanel extends JPanel
       MousePos o = (MousePos) obj;
       boolean b = (column == o.column && seqIndex == o.seqIndex
               && annotationIndex == o.annotationIndex);
-      // System.out.println(obj + (b ? "= " : "!= ") + this);
+      // jalview.bin.Console.outPrintln(obj + (b ? "= " : "!= ") + this);
       return b;
     }
 
@@ -343,6 +343,14 @@ public class SeqPanel extends JPanel
   }
 
   /**
+   * @param evt
+   * @return absolute column in alignment nearest to the mouse pointer
+   */
+  int findAlignmentColumn(MouseEvent evt)
+  {
+    return findNearestColumn(evt,true);
+  }
+  /**
    * Returns the aligned sequence position (base 0) at the mouse position, or
    * the closest visible one
    * <p>
@@ -354,6 +362,15 @@ public class SeqPanel extends JPanel
    */
   int findColumn(MouseEvent evt)
   {
+    return findNearestColumn(evt, false);
+  }
+  
+  /**
+   * @param nearestColumn when false returns negative values for out of bound positions - -1 for scale left/right, <-1 if far to right
+   * @return nearest absolute column to mouse pointer
+   */
+  private int findNearestColumn(MouseEvent evt, boolean nearestColumn)
+  {
     int res = 0;
     int x = evt.getX();
 
@@ -377,7 +394,11 @@ public class SeqPanel extends JPanel
       if (x < 0)
       {
         // mouse is over left scale
-        return -1;
+        if (!nearestColumn) {
+          return -1;
+        } else {
+          x = 0;
+        }
       }
 
       int cwidth = seqCanvas.getWrappedCanvasWidth(this.getWidth());
@@ -387,8 +408,12 @@ public class SeqPanel extends JPanel
       }
       if (x >= cwidth * charWidth)
       {
-        // mouse is over right scale
-        return -1;
+        if (!nearestColumn) {
+          // mouse is over right scale
+          return -1;
+        } else {
+          x = cwidth*charWidth -1;
+        }
       }
 
       wrappedBlock = y / cHeight;
@@ -405,9 +430,16 @@ public class SeqPanel extends JPanel
        * rather than right-hand gutter
        */
       x = Math.min(x, seqCanvas.getX() + seqCanvas.getWidth());
+      if (nearestColumn)
+      {
+        x = Math.max(x, 0);
+      }
+
       res = (x / charWidth) + startRes;
       res = Math.min(res, av.getRanges().getEndRes());
+
     }
+    
 
     if (av.hasHiddenColumns())
     {
@@ -881,7 +913,7 @@ public class SeqPanel extends JPanel
 
     if (lastMessage == null || !lastMessage.equals(tmp))
     {
-      // System.err.println("mouseOver Sequence: "+tmp);
+      // jalview.bin.Console.errPrintln("mouseOver Sequence: "+tmp);
       ssm.mouseOverSequence(sequence, index, pos, av);
     }
     lastMessage = tmp;
@@ -1006,7 +1038,7 @@ public class SeqPanel extends JPanel
   @Override
   public void updateColours(SequenceI seq, int index)
   {
-    System.out.println("update the seqPanel colours");
+    jalview.bin.Console.outPrintln("update the seqPanel colours");
     // repaint();
   }
 
@@ -2861,7 +2893,7 @@ public class SeqPanel extends JPanel
     if (copycolsel && av.hasHiddenColumns()
             && (av.getAlignment().getHiddenColumns() == null))
     {
-      System.err.println("Bad things");
+      jalview.bin.Console.errPrintln("Bad things");
     }
     if (repaint) // always true!
     {
index 6b4c74a..137655f 100755 (executable)
@@ -599,7 +599,7 @@ public class SequenceFetcher extends JPanel implements Runnable
                 + ((StringPair) database.getSelectedItem()).getDisplay());
         // error
         // +="Couldn't retrieve sequences from "+database.getSelectedItem();
-        System.err.println("Retrieval failed for source ='"
+        jalview.bin.Console.errPrintln("Retrieval failed for source ='"
                 + ((StringPair) database.getSelectedItem()).getDisplay()
                 + "' and query\n'" + textArea.getText() + "'\n");
         e.printStackTrace();
index 43fef15..fedcc37 100755 (executable)
@@ -70,6 +70,7 @@ public class SequenceRenderer implements jalview.api.SequenceRenderer
    * @param b
    *          DOCUMENT ME!
    */
+  @Override
   public void prepare(Graphics g, boolean renderGaps)
   {
     graphics = g;
index 0b7af0d..1060d8a 100755 (executable)
@@ -113,8 +113,11 @@ public class SplashScreen extends JPanel
    */
   public SplashScreen(boolean isTransient)
   {
-    Desktop.instance.acquireDialogQueue();
     this.transientDialog = isTransient;
+    if (this.transientDialog)
+    {
+      Desktop.instance.acquireDialogQueue();
+    }
 
     if (Platform.isJS()) // BH 2019
     {
@@ -172,7 +175,7 @@ public class SplashScreen extends JPanel
           }
           if (mt.isErrorAny())
           {
-            System.err.println("Error when loading images!");
+            jalview.bin.Console.errPrintln("Error when loading images!");
           }
         } while (!mt.checkAll());
         Desktop.instance.setIconImages(ChannelProperties.getIconList());
@@ -228,7 +231,8 @@ public class SplashScreen extends JPanel
   protected boolean refreshText()
   {
     String newtext = Desktop.instance.getAboutMessage();
-    // System.err.println("Text found: \n"+newtext+"\nEnd of newtext.");
+    // jalview.bin.Console.errPrintln("Text found: \n"+newtext+"\nEnd of
+    // newtext.");
     if (oldTextLength != newtext.length())
     {
       iframe.setVisible(false);
@@ -324,7 +328,6 @@ public class SplashScreen extends JPanel
     }
 
     closeSplash();
-    Desktop.instance.releaseDialogQueue();
   }
 
   /**
@@ -332,10 +335,14 @@ public class SplashScreen extends JPanel
    */
   public void closeSplash()
   {
+    if (this.transientDialog)
+    {
+      Desktop.instance.releaseDialogQueue();
+    }
     try
     {
 
-      iframe.setClosed(true);
+      iframe.setClosed(true); // ##### implicated BLOCKED
     } catch (Exception ex)
     {
     }
index 08d6e03..73744b3 100644 (file)
@@ -900,6 +900,7 @@ public class SplitFrame extends GSplitFrame implements SplitContainerI
       });
       featureSettingsUI = new JInternalFrame(MessageManager.getString(
               "label.sequence_feature_settings_for_CDS_and_Protein"));
+      featureSettingsUI.setFrameIcon(null);
       featureSettingsPanels.setOpaque(true);
 
       JPanel dialog = new JPanel();
index 6fce984..8135019 100644 (file)
@@ -71,7 +71,6 @@ import jalview.gui.structurechooser.PDBStructureChooserQuerySource;
 import jalview.gui.structurechooser.StructureChooserQuerySource;
 import jalview.gui.structurechooser.ThreeDBStructureChooserQuerySource;
 import jalview.io.DataSourceType;
-import jalview.io.FileFormatException;
 import jalview.io.JalviewFileChooser;
 import jalview.io.JalviewFileView;
 import jalview.jbgui.FilterOption;
@@ -85,7 +84,6 @@ import jalview.util.StringUtils;
 import jalview.ws.DBRefFetcher;
 import jalview.ws.DBRefFetcher.FetchFinishedListenerI;
 import jalview.ws.datamodel.alphafold.PAEContactMatrix;
-import jalview.ws.dbsources.EBIAlfaFold;
 import jalview.ws.seqfetcher.DbSourceProxy;
 import jalview.ws.sifts.SiftsSettings;
 
@@ -141,6 +139,10 @@ public class StructureChooser extends GStructureChooser
   List<SequenceI> seqsWithoutSourceDBRef = null;
 
   private boolean showChooserGUI = true;
+  /**
+   * when true, queries to external services are supressed (no SIFTs, no PDBe, no 3D-Beacons, etc)
+   */
+  private boolean dontQueryServices = false;
 
   private static StructureViewer lastTargetedView = null;
 
@@ -153,6 +155,13 @@ public class StructureChooser extends GStructureChooser
   public StructureChooser(SequenceI[] selectedSeqs, SequenceI selectedSeq,
           AlignmentPanel ap, boolean showGUI)
   {
+    this(selectedSeqs, selectedSeq, ap, showGUI, false);
+  }
+  
+  public StructureChooser(SequenceI[] selectedSeqs, SequenceI selectedSeq,
+          AlignmentPanel ap, boolean showGUI, boolean dontQueryServices)
+  {
+
     // which FTS engine to use
     data = StructureChooserQuerySource.getQuerySourceFor(selectedSeqs);
     initDialog();
@@ -162,6 +171,7 @@ public class StructureChooser extends GStructureChooser
     this.selectedSequences = selectedSeqs;
     this.progressIndicator = (ap == null) ? null : ap.alignFrame;
     this.showChooserGUI = showGUI;
+    this.dontQueryServices = dontQueryServices;
     init();
 
   }
@@ -233,17 +243,21 @@ public class StructureChooser extends GStructureChooser
       }
     });
 
-    Executors.defaultThreadFactory().newThread(new Runnable()
+    if (!dontQueryServices)
     {
-      @Override
-      public void run()
+      Executors.defaultThreadFactory().newThread(new Runnable()
       {
-        populateSeqsWithoutSourceDBRef();
-        initialStructureDiscovery();
-      }
-
-    }).start();
+        @Override
+        public void run()
+        {
+          populateSeqsWithoutSourceDBRef();
+          initialStructureDiscovery();
+        }
 
+      }).start();
+    } else {
+      Console.debug("Structure chooser not querying services to discover metadata.");
+    }
   }
 
   // called by init
@@ -508,7 +522,7 @@ public class StructureChooser extends GStructureChooser
         }
       } catch (Exception e)
       {
-        e.printStackTrace();
+        Console.printStackTrace(e);
         errors.add(e.getMessage());
         continue;
       }
@@ -545,9 +559,18 @@ public class StructureChooser extends GStructureChooser
         {
           errorMsg.append(error).append("\n");
         }
-        JvOptionPane.showMessageDialog(this, errorMsg.toString(),
-                MessageManager.getString("label.pdb_web-service_error"),
-                JvOptionPane.ERROR_MESSAGE);
+        if (!Jalview.isHeadlessMode())
+        {
+          JvOptionPane.showMessageDialog(this, errorMsg.toString(),
+                  MessageManager.getString("label.pdb_web-service_error"),
+                  JvOptionPane.ERROR_MESSAGE);
+        }
+        else
+        {
+          Console.error(
+                  MessageManager.getString("label.pdb_web-service_error"));
+          Console.debug(errorMsg.toString());
+        }
       }
     }
   }
@@ -608,7 +631,7 @@ public class StructureChooser extends GStructureChooser
 
           } catch (Exception e)
           {
-            e.printStackTrace();
+            Console.debugPrintStackTrace(e);
             errors.add(e.getMessage());
             continue;
           }
@@ -985,8 +1008,13 @@ public class StructureChooser extends GStructureChooser
               .getFTSDataFor(getResultTable(), selectedRow,
                       discoveredStructuresSet);
       String pageUrl = row.getModelViewUrl();
+      
       JPopupMenu popup = new JPopupMenu("3D Beacons");
       JMenuItem viewUrl = new JMenuItem("View model web page");
+      if (pageUrl == null || "".equals(pageUrl.trim())) {
+        viewUrl.setEnabled(false);
+        viewUrl.setText("No model page available.");
+      }
       viewUrl.addActionListener(new ActionListener()
       {
         @Override
@@ -1389,6 +1417,12 @@ public class StructureChooser extends GStructureChooser
     boolean superimpose = chk_superpose.isSelected();
     theViewer.setSuperpose(superimpose);
 
+    // if we're running in --headless mode make this viewer synchronous
+    if (Jalview.isHeadlessMode())
+    {
+      theViewer.setAsync(false);
+    }
+
     /*
      * remember user's choice of superimpose or not
      */
@@ -1525,7 +1559,8 @@ public class StructureChooser extends GStructureChooser
             // for moment, it will work fine as is because it is self-contained
             String searchTerm = text.toLowerCase(Locale.ROOT);
             searchTerm = searchTerm.split(":")[0];
-            // System.out.println(">>>>> search term : " + searchTerm);
+            // jalview.bin.Console.outPrintln(">>>>> search term : " +
+            // searchTerm);
             List<FTSDataColumnI> wantedFields = new ArrayList<>();
             FTSRestRequest pdbRequest = new FTSRestRequest();
             pdbRequest.setAllowEmptySeq(false);
@@ -1778,7 +1813,8 @@ public class StructureChooser extends GStructureChooser
     {
       // headless = true;
       prompt = false;
-      sc = new StructureChooser(new SequenceI[] { seq }, seq, ap, false);
+      // suppress structure viewer's external service queries
+      sc = new StructureChooser(new SequenceI[] { seq }, seq, ap, false,true);
     }
     if (ssm == null)
     {
@@ -1801,7 +1837,9 @@ public class StructureChooser extends GStructureChooser
     sc.mainFrame.dispose();
 
     if (showRefAnnotations)
+    {
       showReferenceAnnotationsForSequence(ap.alignFrame, seq);
+    }
 
     return sv;
   }
index 6cef665..ad3fc6a 100644 (file)
 package jalview.gui;
 
 import java.util.ArrayList;
+import java.util.EnumSet;
 import java.util.HashMap;
 import java.util.LinkedHashMap;
 import java.util.List;
+import java.util.Locale;
 import java.util.Map;
 import java.util.Map.Entry;
 
@@ -66,7 +68,27 @@ public class StructureViewer
 
   public enum ViewerType
   {
-    JMOL, CHIMERA, CHIMERAX, PYMOL
+    JMOL, CHIMERA, CHIMERAX, PYMOL;
+
+    public static ViewerType getFromString(String viewerString)
+    {
+      ViewerType viewerType = null;
+      if (!"none".equals(viewerString))
+      {
+        for (ViewerType v : EnumSet.allOf(ViewerType.class))
+        {
+          String name = v.name().toLowerCase(Locale.ROOT).replaceAll(" ",
+                  "");
+          if (viewerString.equals(name))
+          {
+            viewerType = v;
+            break;
+          }
+        }
+      }
+      return viewerType;
+    }
+
   };
 
   /**
index 01a3c2d..085be71 100644 (file)
@@ -35,6 +35,7 @@ import java.io.IOException;
 import java.io.PrintWriter;
 import java.util.ArrayList;
 import java.util.List;
+import java.util.Map;
 import java.util.Random;
 import java.util.Vector;
 
@@ -47,6 +48,7 @@ import javax.swing.event.MenuEvent;
 import javax.swing.event.MenuListener;
 
 import jalview.api.AlignmentViewPanel;
+import jalview.api.structures.JalviewStructureDisplayI;
 import jalview.bin.Cache;
 import jalview.bin.Console;
 import jalview.datamodel.AlignmentI;
@@ -88,6 +90,29 @@ public abstract class StructureViewerBase extends GStructureViewer
   }
 
   /**
+   * Singleton list of all (open) instances of structureViewerBase
+   * TODO: JAL-3362 - review and adopt the swingJS-safe singleton pattern so each structure viewer base instance is kept to its own JalviewJS parent
+   */
+  private static List<JalviewStructureDisplayI> svbs = new ArrayList<>();
+
+  /**
+   * 
+   * @return list with all existing StructureViewers instance
+   */
+  public static List<JalviewStructureDisplayI> getAllStructureViewerBases()
+  {
+    List<JalviewStructureDisplayI> goodSvbs = new ArrayList<>();
+    for (JalviewStructureDisplayI s : svbs)
+    {
+      if (s != null && !goodSvbs.contains(s))
+      {
+        goodSvbs.add(s);
+      }
+    }
+    return goodSvbs;
+  }
+
+  /**
    * list of sequenceSet ids associated with the view
    */
   protected List<String> _aps = new ArrayList<>();
@@ -117,6 +142,8 @@ public abstract class StructureViewerBase extends GStructureViewer
 
   protected boolean allChainsSelected = false;
 
+  protected boolean allHetatmBeingSelected = false;
+
   protected JMenu viewSelectionMenu;
 
   /**
@@ -137,6 +164,7 @@ public abstract class StructureViewerBase extends GStructureViewer
   {
     super();
     setFrameIcon(null);
+    svbs.add(this);
   }
 
   /**
@@ -180,6 +208,7 @@ public abstract class StructureViewerBase extends GStructureViewer
     return _aps.contains(ap2.av.getSequenceSetId());
   }
 
+  @Override
   public boolean isUsedforaligment(AlignmentViewPanel ap2)
   {
 
@@ -578,6 +607,81 @@ public abstract class StructureViewerBase extends GStructureViewer
       chainMenu.add(menuItem);
     }
   }
+  void setHetatmMenuItems(Map<String,String> hetatmNames)
+  {
+    hetatmMenu.removeAll();
+    if (hetatmNames == null || hetatmNames.isEmpty())
+    {
+      hetatmMenu.setVisible(false);
+      return;
+    }
+    hetatmMenu.setVisible(true);
+    allHetatmBeingSelected=false;
+    JMenuItem allMenuItem = new JMenuItem(
+            MessageManager.getString("label.all"));
+    JMenuItem noneMenuItem = new JMenuItem(
+            MessageManager.getString("label.none"));
+    allMenuItem.addActionListener(new ActionListener()
+    {
+      @Override
+      public void actionPerformed(ActionEvent e) {
+      {
+        allHetatmBeingSelected=true;
+        // Toggle state of everything - on
+        for (int i = 0; i < hetatmMenu.getItemCount(); i++)
+        {
+          if (hetatmMenu.getItem(i) instanceof JCheckBoxMenuItem)
+          {
+            ((JCheckBoxMenuItem) hetatmMenu.getItem(i)).setSelected(true);
+          }
+        }
+        allHetatmBeingSelected=false;
+        showSelectedHetatms();
+      }
+      }});
+
+    noneMenuItem.addActionListener(new ActionListener()
+    {
+      @Override
+      public void actionPerformed(ActionEvent e) {
+      {
+        allHetatmBeingSelected=true;
+        // Toggle state of everything off
+        for (int i = 0; i < hetatmMenu.getItemCount(); i++)
+        {
+          if (hetatmMenu.getItem(i) instanceof JCheckBoxMenuItem)
+          {
+            ((JCheckBoxMenuItem) hetatmMenu.getItem(i)).setSelected(false);
+          }
+        }
+        allHetatmBeingSelected=false;
+        showSelectedHetatms();
+      }
+      }});
+    hetatmMenu.add(noneMenuItem);
+    hetatmMenu.add(allMenuItem);
+
+    for (Map.Entry<String, String> chain : hetatmNames.entrySet())
+    {
+      JCheckBoxMenuItem menuItem = new JCheckBoxMenuItem(chain.getKey(), false);
+      menuItem.setToolTipText(chain.getValue());
+      menuItem.addItemListener(new ItemListener()
+      {
+        @Override
+        public void itemStateChanged(ItemEvent evt)
+        {
+          if (!allHetatmBeingSelected)
+          { 
+            // update viewer only when we were clicked, not programmatically
+            // checked/unchecked
+            showSelectedHetatms();
+          }
+        }
+      });
+
+      hetatmMenu.add(menuItem);
+    }
+  }
 
   /**
    * Action on selecting one of Jalview's registered colour schemes
@@ -983,6 +1087,7 @@ public abstract class StructureViewerBase extends GStructureViewer
       return;
     }
     setChainMenuItems(binding.getChainNames());
+    setHetatmMenuItems(binding.getHetatmNames());
 
     this.setTitle(binding.getViewerTitle(getViewerName(), true));
 
@@ -1132,7 +1237,25 @@ public abstract class StructureViewerBase extends GStructureViewer
     }
     getBinding().showChains(toshow);
   }
-
+  /**
+   * Display selected hetatms in viewer
+   */
+  protected void showSelectedHetatms()
+  {
+    List<String> toshow = new ArrayList<>();
+    for (int i = 0; i < hetatmMenu.getItemCount(); i++)
+    {
+      if (hetatmMenu.getItem(i) instanceof JCheckBoxMenuItem)
+      {
+        JCheckBoxMenuItem item = (JCheckBoxMenuItem) hetatmMenu.getItem(i);
+        if (item.isSelected())
+        {
+          toshow.add(item.getText());
+        }
+      }
+    }
+    getBinding().showHetatms(toshow);
+  }
   /**
    * Tries to fetch a PDB file and save to a temporary local file. Returns the
    * saved file path if successful, or null if not.
@@ -1197,7 +1320,7 @@ public abstract class StructureViewerBase extends GStructureViewer
       }
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error retrieving PDB id " + pdbid + ": " + e.getMessage());
     } finally
     {
@@ -1336,6 +1459,13 @@ public abstract class StructureViewerBase extends GStructureViewer
     // TODO: check for memory leaks where instance isn't finalised because jmb
     // holds a reference to the window
     // jmb = null;
+    
+    try {
+      svbs.remove(this);
+    } catch (Throwable t)
+    {
+      Console.info("Unexpected exception when deregistering structure viewer",t);
+    }
     dispose();
   }
 
index 6fbd422..2d4bdc8 100755 (executable)
@@ -406,9 +406,9 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
       }
 
       int ystart = (node.left() == null ? 0
-              : (int) (((BinaryNode) node.left()).ycount * chunk)) + offy;
+              : (int) (node.left().ycount * chunk)) + offy;
       int yend = (node.right() == null ? 0
-              : (int) (((BinaryNode) node.right()).ycount * chunk)) + offy;
+              : (int) (node.right().ycount * chunk)) + offy;
 
       Rectangle pos = new Rectangle(xend - 2, ypos - 2, 5, 5);
       nodeHash.put(node, pos);
@@ -791,11 +791,11 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
 
     if (top.count == 0)
     {
-      top.count = ((BinaryNode) top.left()).count
-              + ((BinaryNode) top.right()).count;
+      top.count = top.left().count
+              + top.right().count;
     }
 
-    double chunk = (double) (height - (offy)) / (double)top.count;
+    float chunk = (float) (height - (offy)) / top.count;
 
     drawNode(g2, tree.getTopNode(), chunk, wscale, width, offx, offy);
 
index 2eff542..0a0c1b8 100755 (executable)
@@ -261,7 +261,7 @@ public class TreePanel extends GTreePanel
         {
           if (tree == null)
           {
-            System.out.println("tree is null");
+            jalview.bin.Console.outPrintln("tree is null");
             // TODO: deal with case when a change event is received whilst a
             // tree is still being calculated - should save reference for
             // processing message later.
@@ -269,7 +269,7 @@ public class TreePanel extends GTreePanel
           }
           if (evt.getNewValue() == null)
           {
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     "new alignment sequences vector value is null");
           }
 
@@ -896,7 +896,7 @@ public class TreePanel extends GTreePanel
       pg.close();
     } catch (Exception ex)
     {
-      System.err.println("Error writing tree as EPS");
+      jalview.bin.Console.errPrintln("Error writing tree as EPS");
       ex.printStackTrace();
     }
   }
index 8a8ba8d..28f6c59 100644 (file)
@@ -614,7 +614,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
       cdoc = null;
     } catch (Exception ee)
     {
-      System.err.println("Exception whilst updating :");
+      jalview.bin.Console.errPrintln("Exception whilst updating :");
       ee.printStackTrace(System.err);
       // recover object map backup, since its probably corrupted with references
       // to Vobjects that don't exist anymore.
@@ -803,7 +803,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
               // we only care about AlignmentSequence selections
               SelectionMessage sm = (SelectionMessage) message;
               sm.validate();
-              System.err.println("Received\n" + sm.getRawMessage());
+              jalview.bin.Console.errPrintln("Received\n" + sm.getRawMessage());
               Object[] jvobjs = sm.getVorbaIDs() == null ? null
                       : new Object[sm.getVorbaIDs().length];
               if (jvobjs == null)
index 7eeee9a..961caa7 100644 (file)
@@ -359,7 +359,7 @@ public class WebserviceInfo extends GWebserviceInfo
       @Override
       public void internalFrameClosed(InternalFrameEvent evt)
       {
-        // System.out.println("Shutting down webservice client");
+        // jalview.bin.Console.outPrintln("Shutting down webservice client");
         WSClientI service = thisinfo.getthisService();
         if (service != null && service.isCancellable())
         {
index e1613da..d8259f9 100644 (file)
@@ -493,7 +493,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
     else
     {
       // TODO: show warning
-      System.err.println("Invalid name. Not saved.");
+      jalview.bin.Console.errPrintln("Invalid name. Not saved.");
     }
   }
 
@@ -642,7 +642,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
           }
           else
           {
-            System.err.println("Ignoring unknown service argument type "
+            jalview.bin.Console.errPrintln("Ignoring unknown service argument type "
                     + myarg.getClass().getName());
           }
         }
@@ -685,7 +685,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
         {
           if (arg instanceof OptionI)
           {
-            // System.out.println("Setting option "
+            // jalview.bin.Console.outPrintln("Setting option "
             // + System.identityHashCode(arg) + ":" + arg.getName()
             // + " with " + arg.getDefaultValue());
             opanp.selectOption((OptionI) arg, arg.getValue());
@@ -874,7 +874,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
         if (cw + 120 > panewidth)
         {
           jobOptions.add(pbox, "wrap");
-          // System.out.println("Wrap on "+pbox.option.getName());
+          // jalview.bin.Console.outPrintln("Wrap on "+pbox.option.getName());
           cw = hgap + pbox.getSize().width;
           fh = true;
         }
@@ -946,7 +946,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
     }
     // TODO: waste some time trying to eliminate any unnecessary .validate calls
     // here
-    // System.out.println("Size will be : "+w+","+os);
+    // jalview.bin.Console.outPrintln("Size will be : "+w+","+os);
     // optsAndparams.setPreferredSize(null);
     // paramPane.getViewport().setView(optsAndparams);
     paramPane.getViewport().setAutoscrolls(true);
@@ -976,7 +976,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
       disc.run();
     } catch (Exception e)
     {
-      System.err.println("Aborting. Problem discovering services.");
+      jalview.bin.Console.errPrintln("Aborting. Problem discovering services.");
       e.printStackTrace();
       return;
     }
@@ -1023,7 +1023,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
               pr = en.next();
             }
             {
-              System.out.println("Testing opts dupes for "
+              jalview.bin.Console.outPrintln("Testing opts dupes for "
                       + lastserv.getUri() + " : " + lastserv.getActionText()
                       + ":" + pr.getName());
               List<Option> rg = lastserv.getRunnerConfig().getOptions();
@@ -1034,17 +1034,17 @@ public class WsJobParameters extends JPanel implements ItemListener,
                   Option cpy = jalview.ws.jws2.ParameterUtils.copyOption(o);
                 } catch (Exception e)
                 {
-                  System.err.println("Failed to copy " + o.getName());
+                  jalview.bin.Console.errPrintln("Failed to copy " + o.getName());
                   e.printStackTrace();
                 } catch (Error e)
                 {
-                  System.err.println("Failed to copy " + o.getName());
+                  jalview.bin.Console.errPrintln("Failed to copy " + o.getName());
                   e.printStackTrace();
                 }
               }
             }
             {
-              System.out.println("Testing param dupes:");
+              jalview.bin.Console.outPrintln("Testing param dupes:");
               List<Parameter> rg = lastserv.getRunnerConfig()
                       .getParameters();
               for (Parameter o : rg)
@@ -1055,17 +1055,17 @@ public class WsJobParameters extends JPanel implements ItemListener,
                           .copyParameter(o);
                 } catch (Exception e)
                 {
-                  System.err.println("Failed to copy " + o.getName());
+                  jalview.bin.Console.errPrintln("Failed to copy " + o.getName());
                   e.printStackTrace();
                 } catch (Error e)
                 {
-                  System.err.println("Failed to copy " + o.getName());
+                  jalview.bin.Console.errPrintln("Failed to copy " + o.getName());
                   e.printStackTrace();
                 }
               }
             }
             {
-              System.out.println("Testing param write:");
+              jalview.bin.Console.outPrintln("Testing param write:");
               List<String> writeparam = null, readparam = null;
               try
               {
@@ -1073,7 +1073,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
                         .writeParameterSet(
                                 pr.getArguments(lastserv.getRunnerConfig()),
                                 " ");
-                System.out.println("Testing param read :");
+                jalview.bin.Console.outPrintln("Testing param read :");
                 List<Option> pset = jalview.ws.jws2.ParameterUtils
                         .processParameters(writeparam,
                                 lastserv.getRunnerConfig(), " ");
@@ -1087,7 +1087,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
                   String on = o.next(), sn = s.next(), st = t.next();
                   if (!sn.equals(st))
                   {
-                    System.out.println(
+                    jalview.bin.Console.outPrintln(
                             "Original was " + on + " Phase 1 wrote " + sn
                                     + "\tPhase 2 wrote " + st);
                     failed = true;
@@ -1095,11 +1095,11 @@ public class WsJobParameters extends JPanel implements ItemListener,
                 }
                 if (failed)
                 {
-                  System.out.println(
+                  jalview.bin.Console.outPrintln(
                           "Original parameters:\n" + pr.getOptions());
-                  System.out.println(
+                  jalview.bin.Console.outPrintln(
                           "Wrote parameters in first set:\n" + writeparam);
-                  System.out.println(
+                  jalview.bin.Console.outPrintln(
                           "Wrote parameters in second set:\n" + readparam);
 
                 }
@@ -1223,7 +1223,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
    * + storeSetName + ": ", jobParams); }
    * 
    * private void writeParam(String nm, List<ArgumentI> params) { for (ArgumentI
-   * p : params) { System.out.println(nm + ":" + System.identityHashCode(p) +
+   * p : params) { jalview.bin.Console.outPrintln(nm + ":" + System.identityHashCode(p) +
    * " Name: " + p.getName() + " Value: " + p.getDefaultValue()); } }
    * 
    * private Object[] _getUserPreset(String setName) { Object[] pset =
@@ -1325,7 +1325,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
    */
   protected void updateWebServiceMenus()
   {
-    for (AlignFrame alignFrame : Desktop.getAlignFrames())
+    for (AlignFrame alignFrame : Desktop.getDesktopAlignFrames())
     {
       alignFrame.BuildWebServiceMenu();
     }
@@ -1376,7 +1376,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
         return;
       }
       settingDialog = true;
-      System.out.println("Prompting to save " + lsetname);
+      jalview.bin.Console.outPrintln("Prompting to save " + lsetname);
       if (JvOptionPane.showConfirmDialog(this, "Parameter set '" + lsetname
               + "' is modifed, and your changes will be lost.\nReally change preset ?",
               "Warning: Unsaved Changes",
@@ -1388,7 +1388,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
         settingDialog = false;
         // and leave.
         return;
-        // System.out.println("Saving for " + lsetname);
+        // jalview.bin.Console.outPrintln("Saving for " + lsetname);
         // _storeCurrentPreset(lsetname);
 
       }
@@ -1467,7 +1467,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
           return;
         }
         curSetName = newname;
-        System.err.println("New name for user setting " + curSetName
+        jalview.bin.Console.errPrintln("New name for user setting " + curSetName
                 + " (was " + setName.getSelectedItem() + ")");
         if (curSetName.equals(setName.getSelectedItem()))
         {
index 8555a78..76479e2 100644 (file)
@@ -150,7 +150,7 @@ public class PDBStructureChooserQuerySource
       String[] names = seqName.toLowerCase(Locale.ROOT).split("\\|");
       for (String name : names)
       {
-        // System.out.println("Found name : " + name);
+        // jalview.bin.Console.outPrintln("Found name : " + name);
         name.trim();
         if (isValidSeqName(name))
         {
@@ -196,7 +196,7 @@ public class PDBStructureChooserQuerySource
    */
   static boolean isValidSeqName(String seqName)
   {
-    // System.out.println("seqName : " + seqName);
+    // jalview.bin.Console.outPrintln("seqName : " + seqName);
     String ignoreList = "pdb,uniprot,swiss-prot";
     if (seqName.length() < 3)
     {
index cdf0d57..253c8dc 100644 (file)
@@ -120,7 +120,7 @@ public abstract class StructureChooserQuerySource
    */
   static boolean isValidSeqName(String seqName)
   {
-    // System.out.println("seqName : " + seqName);
+    // jalview.bin.Console.outPrintln("seqName : " + seqName);
     String ignoreList = "pdb,uniprot,swiss-prot";
     if (seqName.length() < 3)
     {
index e817b26..28861d9 100644 (file)
@@ -113,7 +113,7 @@ public class TDBResultAnalyser
     int idx = EXP_CATEGORIES.indexOf(upper_cat);
     if (idx == -1)
     {
-      System.out.println("Unknown category: '" + cat + "'");
+      jalview.bin.Console.outPrintln("Unknown category: '" + cat + "'");
       EXP_CATEGORIES.add(upper_cat);
       idx = EXP_CATEGORIES.size() - 1;
     }
@@ -223,8 +223,8 @@ public class TDBResultAnalyser
                 if (!o1_qualtype.equals(o2_qualtype))
                 {
                   // prefer LDDT measure over others
-                  return "pLDDT".equals(o1_prov) ? -1
-                          : "pLDDT".equals(o2_prov) ? 1 : 0;
+                  return "pLDDT".equals(o1_qualtype) ? -1
+                          : "pLDDT".equals(o2_qualtype) ? 1 : 0;
                 }
                 // OR NO VALUE FOR THE QUALITY
                 if (eitherNull(idx_mqual, o1data, o2data))
@@ -234,7 +234,8 @@ public class TDBResultAnalyser
                 // models, so rank on qmean - b
                 double o1_mq = (Double) o1data[idx_mqual];
                 double o2_mq = (Double) o2data[idx_mqual];
-                return (o2_mq < o1_mq) ? 1 : (o2_mq == o1_mq) ? 0 : -1;
+                int res = (o2_mq < o1_mq) ? 1 : (o2_mq == o1_mq) ? 0 : -1;
+                return ("pLDDT".equals(o1_qualtype)) ? -res : res;
               }
             }
             else
index cbc6add..76ef85f 100644 (file)
@@ -310,7 +310,7 @@ public class ThreeDBStructureChooserQuerySource
             && tdBeaconsFilters.contains(fieldToFilterBy);
   }
 
-  private String remove_prefix(String fieldToFilterBy)
+  protected String remove_prefix(String fieldToFilterBy)
   {
     if (tdBeaconsFilters != null
             && tdBeaconsFilters.contains(fieldToFilterBy)
@@ -587,7 +587,7 @@ public class ThreeDBStructureChooserQuerySource
       {
         if (!hasPdbResp)
         {
-          System.out.println(
+          jalview.bin.Console.outPrintln(
                   "Warning: seems like we couldn't get to the PDBe search interface.");
         }
         else
index ece2df0..a6e96cb 100644 (file)
@@ -67,14 +67,14 @@ public abstract class AbstractRequestHandler extends AbstractHandler
       /*
        * Set server error status on response
        */
-      System.err.println("Exception handling request "
+      jalview.bin.Console.errPrintln("Exception handling request "
               + request.getRequestURI() + " : " + t.getMessage());
       if (response.isCommitted())
       {
         /*
          * Can't write an HTTP header once any response content has been written
          */
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Unable to return HTTP 500 as response already committed");
       }
       else
@@ -105,20 +105,20 @@ public abstract class AbstractRequestHandler extends AbstractHandler
    */
   protected void dumpRequest(HttpServletRequest request)
   {
-    System.out.println(request.getMethod());
-    System.out.println(request.getRequestURL());
+    jalview.bin.Console.outPrintln(request.getMethod());
+    jalview.bin.Console.outPrintln(request.getRequestURL());
     for (String hdr : Collections.list(request.getHeaderNames()))
     {
       for (String val : Collections.list(request.getHeaders(hdr)))
       {
-        System.out.println(hdr + ": " + val);
+        jalview.bin.Console.outPrintln(hdr + ": " + val);
       }
     }
     for (String param : Collections.list(request.getParameterNames()))
     {
       for (String val : request.getParameterValues(param))
       {
-        System.out.println(param + "=" + val);
+        jalview.bin.Console.outPrintln(param + "=" + val);
       }
     }
   }
@@ -143,7 +143,7 @@ public abstract class AbstractRequestHandler extends AbstractHandler
       stop();
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error stopping " + getName() + ": " + e.getMessage());
     }
   }
index a18d38d..b9adcc6 100644 (file)
@@ -150,13 +150,13 @@ public class HttpServer
       contextHandlers = new HandlerCollection(true);
       server.setHandler(contextHandlers);
       server.start();
-      // System.out.println(String.format(
+      // jalview.bin.Console.outPrintln(String.format(
       // "HttpServer started with %d threads", server.getThreadPool()
       // .getThreads()));
       contextRoot = server.getURI();
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error trying to start HttpServer: " + e.getMessage());
       try
       {
@@ -195,14 +195,14 @@ public class HttpServer
     {
       for (String val : Collections.list(request.getHeaders(hdr)))
       {
-        System.out.println(hdr + ": " + val);
+        jalview.bin.Console.outPrintln(hdr + ": " + val);
       }
     }
     for (String param : Collections.list(request.getParameterNames()))
     {
       for (String val : request.getParameterValues(param))
       {
-        System.out.println(param + "=" + val);
+        jalview.bin.Console.outPrintln(param + "=" + val);
       }
     }
   }
@@ -221,7 +221,7 @@ public class HttpServer
           server.stop();
         } catch (Exception e)
         {
-          System.err.println("Error stopping Http Server on "
+          jalview.bin.Console.errPrintln("Error stopping Http Server on "
                   + server.getURI() + ": " + e.getMessage());
         }
       }
@@ -267,12 +267,12 @@ public class HttpServer
       ch.start();
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Error starting handler for " + path + ": " + e.getMessage());
     }
 
     handler.setUri(this.contextRoot + ch.getContextPath().substring(1));
-    System.out.println("Jalview " + handler.getName()
+    jalview.bin.Console.outPrintln("Jalview " + handler.getName()
             + " handler started on " + handler.getUri());
   }
 
@@ -293,7 +293,7 @@ public class HttpServer
     {
       contextHandlers.removeHandler(ch);
       myHandlers.remove(handler);
-      System.out.println("Stopped Jalview " + handler.getName()
+      jalview.bin.Console.outPrintln("Stopped Jalview " + handler.getName()
               + " handler on " + handler.getUri());
     }
   }
index 09859c9..7e2539f 100755 (executable)
@@ -317,7 +317,7 @@ public class AnnotationFile
               }
               else
               {
-                // System.err.println("Skipping NaN - not valid value.");
+                // jalview.bin.Console.errPrintln("Skipping NaN - not valid value.");
                 text.append(comma + 0f);// row.annotations[j].value);
               }
               comma = ",";
@@ -679,10 +679,10 @@ public class AnnotationFile
     } catch (Exception ex)
     {
       ex.printStackTrace();
-      System.out.println("Problem reading annotation file: " + ex);
+      jalview.bin.Console.outPrintln("Problem reading annotation file: " + ex);
       if (nlinesread > 0)
       {
-        System.out.println("Last read line " + nlinesread + ": '" + lastread
+        jalview.bin.Console.outPrintln("Last read line " + nlinesread + ": '" + lastread
                 + "' (first 80 chars) ...");
       }
       return false;
@@ -821,7 +821,7 @@ public class AnnotationFile
               if (refSeqIndex < 1)
               {
                 refSeqIndex = 1;
-                System.out.println(
+                jalview.bin.Console.outPrintln(
                         "WARNING: SEQUENCE_REF index must be > 0 in AnnotationFile");
               }
             } catch (Exception ex)
@@ -923,7 +923,7 @@ public class AnnotationFile
           {
             if (hidden == null)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Cannot process HIDE_INSERTIONS without an alignment view: Ignoring line: "
                               + line);
             }
@@ -1075,7 +1075,7 @@ public class AnnotationFile
             {
               // TODO: specify and implement duplication of alignment annotation
               // for multiple group references.
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Ignoring 1:many group reference mappings for group name '"
                               + groupRef + "'");
             }
@@ -1368,7 +1368,7 @@ public class AnnotationFile
     }
     else
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Couldn't combine annotations. None are added to alignment yet!");
     }
   }
@@ -1385,7 +1385,7 @@ public class AnnotationFile
       value = Float.valueOf(nextToken);
     } catch (NumberFormatException e)
     {
-      System.err.println("line " + nlinesread + ": Threshold '" + nextToken
+      jalview.bin.Console.errPrintln("line " + nlinesread + ": Threshold '" + nextToken
               + "' invalid, setting to zero");
     }
     String label = st.hasMoreTokens() ? st.nextToken() : null;
@@ -1435,7 +1435,7 @@ public class AnnotationFile
       }
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Couldn't parse Group Start or End Field as '*' or a valid column or sequence index: '"
                       + rng + "' - assuming alignment width for group.");
       // assume group is full width
index 9a4e982..56e9fa1 100755 (executable)
@@ -215,7 +215,7 @@ public class AppletFormatAdapter
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println("Failed to read alignment using the '" + fileFormat
+      jalview.bin.Console.errPrintln("Failed to read alignment using the '" + fileFormat
               + "' reader.\n" + e);
 
       if (e.getMessage() != null
@@ -297,7 +297,7 @@ public class AppletFormatAdapter
     } catch (Exception e)
     {
       e.printStackTrace();
-      System.err.println("Failed to read alignment using the '" + format
+      jalview.bin.Console.errPrintln("Failed to read alignment using the '" + format
               + "' reader.\n" + e);
 
       if (e.getMessage() != null
@@ -424,13 +424,13 @@ public class AppletFormatAdapter
       String afileresp = afile.print(seqs, jvsuffix);
       if (afile.hasWarningMessage())
       {
-        System.err.println("Warning raised when writing as " + format
+        jalview.bin.Console.errPrintln("Warning raised when writing as " + format
                 + " : " + afile.getWarningMessage());
       }
       return afileresp;
     } catch (Exception e)
     {
-      System.err.println("Failed to write alignment as a '"
+      jalview.bin.Console.errPrintln("Failed to write alignment as a '"
               + format.getName() + "' file\n");
       e.printStackTrace();
     }
@@ -488,7 +488,7 @@ public class AppletFormatAdapter
       {
         try
         {
-          System.out.println("Reading file: " + f);
+          jalview.bin.Console.outPrintln("Reading file: " + f);
           AppletFormatAdapter afa = new AppletFormatAdapter();
           Runtime r = Runtime.getRuntime();
           System.gc();
@@ -502,36 +502,36 @@ public class AppletFormatAdapter
           memf += r.totalMemory() - r.freeMemory();
           if (al != null)
           {
-            System.out.println("Alignment contains " + al.getHeight()
+            jalview.bin.Console.outPrintln("Alignment contains " + al.getHeight()
                     + " sequences and " + al.getWidth() + " columns.");
             try
             {
-              System.out.println(new AppletFormatAdapter()
+              jalview.bin.Console.outPrintln(new AppletFormatAdapter()
                       .formatSequences(FileFormat.Fasta, al, true));
             } catch (Exception e)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Couln't format the alignment for output as a FASTA file.");
               e.printStackTrace(System.err);
             }
           }
           else
           {
-            System.out.println("Couldn't read alignment");
+            jalview.bin.Console.outPrintln("Couldn't read alignment");
           }
-          System.out.println("Read took " + (t1 / 1000.0) + " seconds.");
-          System.out.println(
+          jalview.bin.Console.outPrintln("Read took " + (t1 / 1000.0) + " seconds.");
+          jalview.bin.Console.outPrintln(
                   "Difference between free memory now and before is "
                           + (memf / (1024.0 * 1024.0) * 1.0) + " MB");
         } catch (Exception e)
         {
-          System.err.println("Exception when dealing with " + i
+          jalview.bin.Console.errPrintln("Exception when dealing with " + i
                   + "'th argument: " + args[i] + "\n" + e);
         }
       }
       else
       {
-        System.err.println("Ignoring argument '" + args[i] + "' (" + i
+        jalview.bin.Console.errPrintln("Ignoring argument '" + args[i] + "' (" + i
                 + "'th)- not a readable file.");
       }
       i++;
@@ -559,7 +559,7 @@ public class AppletFormatAdapter
     DataSourceType protocol = null;
     if (debug)
     {
-      System.out.println("resolving datasource started with:\n>>file\n"
+      jalview.bin.Console.outPrintln("resolving datasource started with:\n>>file\n"
               + file + ">>endfile");
     }
 
@@ -577,7 +577,7 @@ public class AppletFormatAdapter
       }
       if (debug)
       {
-        System.err.println("Resource '" + file + "' was "
+        jalview.bin.Console.errPrintln("Resource '" + file + "' was "
                 + (rtn ? "" : "not") + " located by classloader.");
       }
       if (rtn)
@@ -605,7 +605,7 @@ public class AppletFormatAdapter
     {
       if (debug)
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "Trying to get contents of resource as " + protocol + ":");
       }
       fp = new FileParse(file, protocol);
@@ -617,14 +617,14 @@ public class AppletFormatAdapter
       {
         if (debug)
         {
-          System.out.println("Successful.");
+          jalview.bin.Console.outPrintln("Successful.");
         }
       }
     } catch (Exception e)
     {
       if (debug)
       {
-        System.err.println("Exception when accessing content: " + e);
+        jalview.bin.Console.errPrintln("Exception when accessing content: " + e);
       }
       fp = null;
     }
@@ -632,7 +632,7 @@ public class AppletFormatAdapter
     {
       if (debug)
       {
-        System.out.println("Accessing as paste.");
+        jalview.bin.Console.outPrintln("Accessing as paste.");
       }
       protocol = DataSourceType.PASTE;
       fp = null;
@@ -645,7 +645,7 @@ public class AppletFormatAdapter
         }
       } catch (Exception e)
       {
-        System.err.println("Failed to access content as paste!");
+        jalview.bin.Console.errPrintln("Failed to access content as paste!");
         e.printStackTrace();
         fp = null;
       }
@@ -667,20 +667,20 @@ public class AppletFormatAdapter
         {
           if (debug)
           {
-            System.out.println("Format not identified. Inaccessible file.");
+            jalview.bin.Console.outPrintln("Format not identified. Inaccessible file.");
           }
           return null;
         }
         if (debug)
         {
-          System.out.println("Format identified as " + idformat
+          jalview.bin.Console.outPrintln("Format identified as " + idformat
                   + "and expected as " + format);
         }
         if (idformat.equals(format))
         {
           if (debug)
           {
-            System.out.println("Protocol identified as " + protocol);
+            jalview.bin.Console.outPrintln("Protocol identified as " + protocol);
           }
           return protocol;
         }
@@ -698,7 +698,7 @@ public class AppletFormatAdapter
       {
         if (debug)
         {
-          System.err.println("File deemed not accessible via " + protocol);
+          jalview.bin.Console.errPrintln("File deemed not accessible via " + protocol);
           e.printStackTrace();
         }
       }
index b8a721e..1a08363 100644 (file)
@@ -54,7 +54,7 @@ public class BackupFilenameFilter implements FilenameFilter
       }
     } catch (IOException e)
     {
-      System.out.println("IOException when checking file '" + filename
+      jalview.bin.Console.outPrintln("IOException when checking file '" + filename
               + "' is a backupfile");
     }
 
index 6779892..eef203f 100644 (file)
@@ -138,7 +138,7 @@ public class BioJsHTMLOutput extends HTMLOutput
       {
         if (!biojsDirectory.mkdirs())
         {
-          System.out.println("Couldn't create local directory : "
+          jalview.bin.Console.outPrintln("Couldn't create local directory : "
                   + BJS_TEMPLATES_LOCAL_DIRECTORY);
           return;
         }
@@ -264,7 +264,7 @@ public class BioJsHTMLOutput extends HTMLOutput
 
     } catch (OutOfMemoryError err)
     {
-      System.out.println("########################\n" + "OUT OF MEMORY "
+      jalview.bin.Console.outPrintln("########################\n" + "OUT OF MEMORY "
               + generatedFile + "\n" + "########################");
       new OOMWarning("Creating Image for " + generatedFile, err);
     } catch (Exception e)
index afb2009..a71e6e8 100755 (executable)
@@ -140,7 +140,7 @@ public class ClustalFile extends AlignFile
       }
     } catch (IOException e)
     {
-      System.err.println("Exception parsing clustal file " + e);
+      jalview.bin.Console.errPrintln("Exception parsing clustal file " + e);
       e.printStackTrace();
     }
 
@@ -168,7 +168,7 @@ public class ClustalFile extends AlignFile
         }
         else
         {
-          System.err.println("Clustal File Reader: Can't find sequence for "
+          jalview.bin.Console.errPrintln("Clustal File Reader: Can't find sequence for "
                   + headers.elementAt(i));
         }
       }
index 6d00a7d..c983dfe 100644 (file)
@@ -28,4 +28,9 @@ public enum DataSourceType
   {
     return this != FILE;
   }
+
+  public boolean isUrl()
+  {
+    return this == URL || this == RELATIVE_URL;
+  }
 }
index 6332561..a704f24 100755 (executable)
@@ -312,7 +312,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
       // should report somewhere useful for UI if necessary
       warningMessage = ((warningMessage == null) ? "" : warningMessage)
               + "Parsing error at\n" + line;
-      System.out.println("Error parsing feature file: " + ex + "\n" + line);
+      jalview.bin.Console.outPrintln("Error parsing feature file: " + ex + "\n" + line);
       ex.printStackTrace(System.err);
       resetMatcher();
       return false;
@@ -354,7 +354,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
       String[] tokens = line.split(TAB_REGEX);
       if (tokens.length != 2)
       {
-        System.err.println(String.format("Invalid token count %d for %d",
+        jalview.bin.Console.errPrintln(String.format("Invalid token count %d for %d",
                 tokens.length, line));
       }
       else
@@ -392,7 +392,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
      */
     if (gffColumns.length < 6)
     {
-      System.err.println("Ignoring feature line '" + line
+      jalview.bin.Console.errPrintln("Ignoring feature line '" + line
               + "' with too few columns (" + gffColumns.length + ")");
       return false;
     }
@@ -415,13 +415,13 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
         seq = alignment.getSequenceAt(idx);
       } catch (NumberFormatException ex)
       {
-        System.err.println("Invalid sequence index: " + seqIndex);
+        jalview.bin.Console.errPrintln("Invalid sequence index: " + seqIndex);
       }
     }
 
     if (seq == null)
     {
-      System.out.println("Sequence not found: " + line);
+      jalview.bin.Console.outPrintln("Sequence not found: " + line);
       return false;
     }
 
@@ -1009,7 +1009,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
   @Override
   public String print(SequenceI[] sqs, boolean jvsuffix)
   {
-    System.out.println("Use printGffFormat() or printJalviewFormat()");
+    jalview.bin.Console.outPrintln("Use printGffFormat() or printJalviewFormat()");
     return null;
   }
 
@@ -1333,7 +1333,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
      */
     if (gffColumns.length < 5)
     {
-      System.err.println("Ignoring GFF feature line with too few columns ("
+      jalview.bin.Console.errPrintln("Ignoring GFF feature line with too few columns ("
               + gffColumns.length + ")");
       return null;
     }
@@ -1364,7 +1364,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
         }
       } catch (IOException e)
       {
-        System.err.println("GFF parsing failed with: " + e.getMessage());
+        jalview.bin.Console.errPrintln("GFF parsing failed with: " + e.getMessage());
         return null;
       }
     }
@@ -1532,7 +1532,7 @@ public class FeaturesFile extends AlignFile implements FeaturesSourceI
     }
     else
     {
-      System.err.println("Ignoring unknown pragma: " + line);
+      jalview.bin.Console.errPrintln("Ignoring unknown pragma: " + line);
     }
   }
 }
index 43c6dcf..91ce527 100644 (file)
@@ -308,6 +308,21 @@ public enum FileFormat implements FileFormatI
       return new FeaturesFile();
     }
   },
+  FeatureSettings("Jalview Feature Settings File","fc",false,false)
+  {
+    @Override
+    public AlignmentFileReaderI getReader(FileParse source)
+            throws IOException
+    {
+      return null;
+    }
+
+    @Override
+    public AlignmentFileWriterI getWriter(AlignmentI al)
+    {
+      return null;
+    }    
+  },
   ScoreMatrix("Substitution matrix", "", false, false)
   {
     @Override
index b7dd834..96489d0 100644 (file)
@@ -107,7 +107,7 @@ public class FileFormats
     String name = format.getName().toUpperCase(Locale.ROOT);
     if (formats.containsKey(name))
     {
-      System.err.println("Overwriting file format: " + format.getName());
+      jalview.bin.Console.errPrintln("Overwriting file format: " + format.getName());
     }
     formats.put(name, format);
     if (isIdentifiable)
index a2585b3..b16c37f 100755 (executable)
@@ -74,6 +74,8 @@ public class FileLoader implements Runnable
 
   private File selectedFile;
 
+  private static boolean useDefaultFileFormat = false;
+
   /**
    * default constructor always raised errors in GUI dialog boxes
    */
@@ -321,9 +323,9 @@ public class FileLoader implements Runnable
       if (format == null)
       {
         Desktop.instance.stopLoading();
-        System.err.println("The input file \"" + file
+        jalview.bin.Console.errPrintln("The input file \"" + file
                 + "\" has null or unidentifiable data content!");
-        if (!Jalview.isHeadlessMode())
+        if (!Jalview.isHeadlessMode() && !Jalview.isBatchMode())
         {
           JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                   MessageManager.getString("label.couldnt_read_data")
@@ -354,13 +356,14 @@ public class FileLoader implements Runnable
         if (source != null)
         {
           // Tell the user (developer?) that this is going to cause a problem
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "IMPLEMENTATION ERROR: Cannot read consecutive Jalview XML projects from a stream.");
           // We read the data anyway - it might make sense.
         }
         // BH 2018 switch to File object here instead of filename
-        alignFrame = new Jalview2XML(raiseGUI).loadJalviewAlign(
-                selectedFile == null ? file : selectedFile);
+        alignFrame = new Jalview2XML(raiseGUI && !Jalview.isBatchMode())
+                .loadJalviewAlign(
+                        selectedFile == null ? file : selectedFile);
       }
       else
       {
@@ -535,7 +538,7 @@ public class FileLoader implements Runnable
                   "label.couldnt_load_file") + " " + title + "\n" + error;
           // TODO: refactor FileLoader to be independent of Desktop / Applet GUI
           // bits ?
-          if (raiseGUI && Desktop.desktop != null)
+          if (raiseGUI && !Jalview.isBatchMode() && Desktop.desktop != null)
           {
             javax.swing.SwingUtilities.invokeLater(new Runnable()
             {
@@ -552,7 +555,7 @@ public class FileLoader implements Runnable
           }
           else
           {
-            System.err.println(errorMessage);
+            jalview.bin.Console.errPrintln(errorMessage);
           }
         }
       }
@@ -561,9 +564,10 @@ public class FileLoader implements Runnable
 
     } catch (Exception er)
     {
-      System.err.println("Exception whilst opening file '" + file);
+      jalview.bin.Console
+              .errPrintln("Exception whilst opening file '" + file);
       er.printStackTrace();
-      if (raiseGUI)
+      if (raiseGUI && !Jalview.isBatchMode())
       {
         javax.swing.SwingUtilities.invokeLater(new Runnable()
         {
@@ -585,7 +589,7 @@ public class FileLoader implements Runnable
 
       er.printStackTrace();
       alignFrame = null;
-      if (raiseGUI)
+      if (raiseGUI && !Jalview.isBatchMode())
       {
         javax.swing.SwingUtilities.invokeLater(new Runnable()
         {
@@ -601,7 +605,8 @@ public class FileLoader implements Runnable
           }
         });
       }
-      System.err.println("Out of memory loading file " + file + "!!");
+      jalview.bin.Console
+              .errPrintln("Out of memory loading file " + file + "!!");
 
     }
     loadtime += System.currentTimeMillis();
@@ -620,7 +625,7 @@ public class FileLoader implements Runnable
       {
         AlignmentI al = alignFrame.getViewport().getAlignment();
 
-        System.out.println("Loaded '" + title + "' in "
+        jalview.bin.Console.outPrintln("Loaded '" + title + "' in "
                 + (loadtime / 1000.0) + "s, took an additional "
                 + (1.0 * memused / (1024.0 * 1024.0)) + " MB ("
                 + al.getHeight() + " seqs by " + al.getWidth() + " cols)");
@@ -629,7 +634,7 @@ public class FileLoader implements Runnable
       {
         // report that we didn't load anything probably due to an out of memory
         // error
-        System.out.println("Failed to load '" + title + "' in "
+        jalview.bin.Console.outPrintln("Failed to load '" + title + "' in "
                 + (loadtime / 1000.0) + "s, took an additional "
                 + (1.0 * memused / (1024.0 * 1024.0))
                 + " MB (alignment is null)");
@@ -642,6 +647,8 @@ public class FileLoader implements Runnable
     }
 
     this.setShouldBeSaved();
+    // after first file loaded we revert to assuming a default file format
+    useDefaultFileFormat = true;
   }
 
   /**
@@ -680,8 +687,21 @@ public class FileLoader implements Runnable
     AlignViewport avp = af.getViewport();
     if (avp == null)
       return;
-    avp.setSavedUpToDate(!protocol.isDynamic(),
-            QuitHandler.Message.UNSAVED_ALIGNMENTS);
+    boolean upToDate = !protocol.isDynamic();
+    if (protocol.isUrl() && !Cache
+            .getDefault(PROMPT_SAVE_UNCHANGED_URL_ALIGNMENTS, true))
+    {
+      upToDate = true;
+    }
+    avp.setSavedUpToDate(upToDate,
+            upToDate ? null : QuitHandler.Message.UNSAVED_ALIGNMENTS);
+  }
+
+  public static final String PROMPT_SAVE_UNCHANGED_URL_ALIGNMENTS = "PROMPT_SAVE_UNCHANGED_URL_ALIGNMENTS";
+
+  public static boolean getUseDefaultFileFormat()
+  {
+    return useDefaultFileFormat;
   }
 
 }
index 8d3283d..1f51d8c 100755 (executable)
@@ -380,7 +380,7 @@ public class FileParse
     if (sfpos > -1 && sfpos < fileStr.length() - 1)
     {
       suffix = fileStr.substring(sfpos + 1);
-      // System.err.println("DEBUG: Found Suffix:"+suffix);
+      // jalview.bin.Console.errPrintln("DEBUG: Found Suffix:"+suffix);
       return fileStr.substring(0, sfpos);
     }
     return null;
@@ -634,7 +634,7 @@ public class FileParse
   {
     if (bytesRead >= READAHEAD_LIMIT)
     {
-      System.err.println(String.format(
+      jalview.bin.Console.errPrintln(String.format(
               "File reset error: read %d bytes but reset limit is %d",
               bytesRead, READAHEAD_LIMIT));
     }
index d659e2a..02d46e7 100644 (file)
@@ -239,7 +239,7 @@ public abstract class HTMLOutput implements Runnable
     }
     else
     {
-      System.out.println(message);
+      jalview.bin.Console.outPrintln(message);
     }
   }
 
index 7b661f3..b5fdc2c 100644 (file)
@@ -249,7 +249,7 @@ public class HtmlSvgOutput extends HTMLOutput
       }
     } catch (OutOfMemoryError err)
     {
-      System.out.println("########################\n" + "OUT OF MEMORY "
+      jalview.bin.Console.outPrintln("########################\n" + "OUT OF MEMORY "
               + generatedFile + "\n" + "########################");
       new OOMWarning("Creating Image for " + generatedFile, err);
     } catch (Exception e)
index ea87058..11d96a3 100755 (executable)
@@ -35,6 +35,8 @@ import jalview.bin.Console;
 public class IdentifyFile
 {
 
+  private static final String XMLHEADER = "<?XML VERSION=\"1.0\" ENCODING=\"UTF-8\" STANDALONE=\"YES\"?>";
+
   public FileFormatI identify(Object file, DataSourceType protocol)
           throws FileFormatException
   {
@@ -134,6 +136,7 @@ public class IdentifyFile
     String data;
     int bytesRead = 0;
     int trimmedLength = 0;
+    boolean isXml = false; // set true if first line is XMLHEADER
     boolean lineswereskipped = false;
     boolean isBinary = false; // true if length is non-zero and non-printable
     // characters are encountered
@@ -188,6 +191,10 @@ public class IdentifyFile
           reply = FileFormat.ScoreMatrix;
           break;
         }
+        if (data.startsWith(XMLHEADER) && !lineswereskipped)
+        {
+          isXml = true;
+        }
         if (data.startsWith("LOCUS"))
         {
           reply = FileFormat.GenBank;
@@ -346,6 +353,11 @@ public class IdentifyFile
             reply = FileFormat.Rnaml;
             break;
           }
+          if (isXml && data.contains("<NS2:JALVIEWUSERCOLOURS SCHEMENAME=\"SEQUENCE FEATURES\" XMLNS:NS2=\"WWW.JALVIEW.ORG/COLOURS\">"))
+          {
+            reply = FileFormat.FeatureSettings;
+            break;
+          }
         }
 
         if ((data.length() < 1) || (data.indexOf("#") == 0))
index ab2c00a..9f8ac4e 100755 (executable)
@@ -150,7 +150,7 @@ public class JPredFile extends AlignFile
   @Override
   public void parse() throws IOException
   {
-    // JBPNote log.System.out.println("all read in ");
+    // JBPNote log.jalview.bin.Console.outPrintln("all read in ");
     String line;
     QuerySeqPosition = -1;
     noSeqs = 0;
@@ -240,7 +240,7 @@ public class JPredFile extends AlignFile
       }
       else if (id.equals("jnetconf"))
       {
-        // log.debug System.out.println("here");
+        // log.debug jalview.bin.Console.outPrintln("here");
         id = "Prediction Confidence";
         this.conf = new Vector(numSymbols);
 
@@ -377,14 +377,14 @@ public class JPredFile extends AlignFile
 
       for (int i = 0; i < jpred.seqs.size(); i++)
       {
-        System.out.println(((Sequence) jpred.seqs.elementAt(i)).getName()
+        jalview.bin.Console.outPrintln(((Sequence) jpred.seqs.elementAt(i)).getName()
                 + "\n"
                 + ((Sequence) jpred.seqs.elementAt(i)).getSequenceAsString()
                 + "\n");
       }
     } catch (java.io.IOException e)
     {
-      System.err.println("Exception " + e);
+      jalview.bin.Console.errPrintln("Exception " + e);
       // e.printStackTrace(); not java 1.1 compatible!
     }
   }
@@ -447,6 +447,6 @@ public class JPredFile extends AlignFile
  * out = BLCFile.print(s);
  * 
  * AlignFrame af = new AlignFrame(null, s); af.resize(700, 500); af.show();
- * System.out.println(out); } catch (java.io.IOException e) {
- * System.out.println("Exception " + e); } } }
+ * jalview.bin.Console.outPrintln(out); } catch (java.io.IOException e) {
+ * jalview.bin.Console.outPrintln("Exception " + e); } } }
  */
index 2ee305f..0b45ba6 100644 (file)
@@ -363,7 +363,7 @@ public class JSONFile extends AlignFile implements ComplexAlignFile
                   .setSecondaryStructure(annotation.secondaryStructure);
           String displayChar = annotation.displayCharacter == null ? null
                   : annotation.displayCharacter;
-          // System.out.println("--------------------->[" + displayChar + "]");
+          // jalview.bin.Console.outPrintln("--------------------->[" + displayChar + "]");
           annotationPojo.setDisplayCharacter(displayChar);
           if (annotation.colour != null)
           {
index cb47610..3f44596 100755 (executable)
@@ -40,15 +40,19 @@ import java.util.StringTokenizer;
 import java.util.Vector;
 
 import javax.swing.BoxLayout;
-import javax.swing.DefaultListCellRenderer;
 import javax.swing.JCheckBox;
 import javax.swing.JDialog;
 import javax.swing.JFileChooser;
+import javax.swing.JLabel;
 import javax.swing.JList;
 import javax.swing.JOptionPane;
 import javax.swing.JPanel;
 import javax.swing.JScrollPane;
+import javax.swing.ListCellRenderer;
 import javax.swing.SpringLayout;
+import javax.swing.SwingConstants;
+import javax.swing.SwingUtilities;
+import javax.swing.border.TitledBorder;
 import javax.swing.filechooser.FileFilter;
 import javax.swing.plaf.basic.BasicFileChooserUI;
 
@@ -193,7 +197,7 @@ public class JalviewFileChooser extends JFileChooser
     }
     else
     {
-      System.err.println("JalviewFileChooser arguments mismatch: "
+      jalview.bin.Console.errPrintln("JalviewFileChooser arguments mismatch: "
               + extensions + ", " + descs);
     }
   }
@@ -262,6 +266,31 @@ public class JalviewFileChooser extends JFileChooser
     // file filters to fix bug on Mac OSX
     setAcceptAllFileFilterUsed(acceptAny);
 
+    // add a "All known alignment files" option
+    List<String> allExtensions = new ArrayList<>();
+    for (String[] format : formats)
+    {
+      String[] extensions = format[0].split(",");
+      for (String ext : extensions)
+      {
+        if (!allExtensions.contains(ext))
+        {
+          allExtensions.add(ext);
+        }
+      }
+    }
+    allExtensions.sort(null);
+    JalviewFileFilter alljvf = new JalviewFileFilter(
+            allExtensions.toArray(new String[] {}),
+            MessageManager.getString("label.all_known_alignment_files"));
+    alljvf.setExtensionListInDescription(false);
+    addChoosableFileFilter(alljvf);
+
+    if (selected == null)
+    {
+      chosen = alljvf;
+    }
+
     for (String[] format : formats)
     {
       JalviewFileFilter jvf = new JalviewFileFilter(format[0], format[1]);
@@ -408,7 +437,7 @@ public class JalviewFileChooser extends JFileChooser
         return FileFormats.getInstance().forName(format);
       } catch (IllegalArgumentException e)
       {
-        System.err.println("Unexpected format: " + format);
+        jalview.bin.Console.errPrintln("Unexpected format: " + format);
       }
     }
     return null;
@@ -462,7 +491,7 @@ public class JalviewFileChooser extends JFileChooser
         }
       } catch (Throwable x)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Unexpected exception when trying to get filename.");
         x.printStackTrace();
       }
@@ -524,6 +553,11 @@ public class JalviewFileChooser extends JFileChooser
         }
       }
 
+      if (!file.isAbsolute() && file.exists())
+      {
+        file = file.getAbsoluteFile();
+      }
+
       setSelectedFile(file);
     }
   }
@@ -552,10 +586,7 @@ public class JalviewFileChooser extends JFileChooser
       }
 
       list = new JList<>(recent);
-
-      DefaultListCellRenderer dlcr = new DefaultListCellRenderer();
-      dlcr.setHorizontalAlignment(DefaultListCellRenderer.RIGHT);
-      list.setCellRenderer(dlcr);
+      list.setCellRenderer(new recentlyOpenedCellRenderer());
 
       list.addMouseListener(new MouseAdapter()
       {
@@ -566,8 +597,11 @@ public class JalviewFileChooser extends JFileChooser
         }
       });
 
-      this.setBorder(new javax.swing.border.TitledBorder(
-              MessageManager.getString("label.recently_opened")));
+      TitledBorder recentlyOpenedBorder = new TitledBorder(
+              MessageManager.getString("label.recently_opened"));
+      recentlyOpenedBorder.setTitleFont(
+              recentlyOpenedBorder.getTitleFont().deriveFont(10f));
+      this.setBorder(recentlyOpenedBorder);
 
       final JScrollPane scroller = new JScrollPane(list);
 
@@ -577,18 +611,11 @@ public class JalviewFileChooser extends JFileChooser
       layout.putConstraint(SpringLayout.NORTH, scroller, 5,
               SpringLayout.NORTH, this);
 
-      if (Platform.isAMacAndNotJS())
-      {
-        scroller.setPreferredSize(new Dimension(500, 100));
-      }
-      else
-      {
-        scroller.setPreferredSize(new Dimension(530, 200));
-      }
-
+      // one size okay for all
+      scroller.setPreferredSize(new Dimension(280, 105));
       this.add(scroller);
 
-      javax.swing.SwingUtilities.invokeLater(new Runnable()
+      SwingUtilities.invokeLater(new Runnable()
       {
         @Override
         public void run()
@@ -602,6 +629,77 @@ public class JalviewFileChooser extends JFileChooser
 
   }
 
+  class recentlyOpenedCellRenderer extends JLabel
+          implements ListCellRenderer<String>
+  {
+    private final static int maxChars = 46;
+
+    private final static String ellipsis = "...";
+
+    @Override
+    public Component getListCellRendererComponent(
+            JList<? extends String> list, String value, int index,
+            boolean isSelected, boolean cellHasFocus)
+    {
+      String filename = value.toString();
+      String displayFilename;
+      if (filename.length() > maxChars)
+      {
+        StringBuilder displayFileSB = new StringBuilder();
+        File file = new File(filename);
+        displayFileSB.append(file.getName());
+        if (file.getParent() != null)
+        {
+          File parent = file;
+          boolean spaceleft = true;
+          while (spaceleft && parent.getParent() != null)
+          {
+            parent = parent.getParentFile();
+            String name = parent.getName();
+            displayFileSB.insert(0, File.separator);
+            if (displayFileSB.length() + name.length() < maxChars - 1)
+            {
+              displayFileSB.insert(0, name);
+            }
+            else
+            {
+              displayFileSB.insert(0, ellipsis);
+              spaceleft = false;
+            }
+          }
+          if (spaceleft && filename.startsWith(File.separator)
+                  && !(displayFileSB.charAt(0) == File.separatorChar))
+          {
+            displayFileSB.insert(0, File.separator);
+          }
+        }
+        displayFilename = displayFileSB.toString();
+      }
+      else
+      {
+        displayFilename = filename;
+      }
+      this.setText(displayFilename.toString());
+      this.setToolTipText(filename);
+      if (isSelected)
+      {
+        setBackground(list.getSelectionBackground());
+        setForeground(list.getSelectionForeground());
+      }
+      else
+      {
+        setBackground(list.getBackground());
+        setForeground(list.getForeground());
+      }
+      this.setHorizontalAlignment(SwingConstants.TRAILING);
+      this.setEnabled(list.isEnabled());
+      this.setFont(list.getFont().deriveFont(12f));
+      this.setOpaque(true);
+      return this;
+    }
+
+  }
+
   /*
   @Override
   public JalviewFileChooser setResponseHandler(Object response,
index 10dc9ea..5e9a242 100755 (executable)
  */
 package jalview.io;
 
-import java.util.Locale;
-
 import java.io.File;
 import java.util.Hashtable;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
+import java.util.Locale;
 import java.util.Map;
 import java.util.StringTokenizer;
 
@@ -175,7 +174,7 @@ public class JalviewFileFilter extends FileFilter
 
           while (extensions.hasNext())
           {
-            fullDescription += (", " + extensions.next());
+            fullDescription += (", ." + extensions.next());
           }
         }
 
index a9fc7ed..5996781 100755 (executable)
@@ -169,7 +169,7 @@ public class JalviewFileView extends FileView
         }
         else
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "JalviewFileView.createImageIcon: Couldn't find file: "
                           + filePath);
         }
index 158feb9..0a0520a 100755 (executable)
@@ -136,7 +136,7 @@ public class MSFfile extends AlignFile
       }
     } catch (IOException e)
     {
-      System.err.println("Exception parsing MSFFile " + e);
+      jalview.bin.Console.errPrintln("Exception parsing MSFFile " + e);
       e.printStackTrace();
     }
 
@@ -169,7 +169,7 @@ public class MSFfile extends AlignFile
       }
       else
       {
-        System.err.println("MSFFile Parser: Can't find sequence for "
+        jalview.bin.Console.errPrintln("MSFFile Parser: Can't find sequence for "
                 + headers.get(i));
       }
     }
@@ -200,7 +200,7 @@ public class MSFfile extends AlignFile
         }
       } catch (Exception e)
       {
-        System.err.println("Exception during MSF Checksum calculation");
+        jalview.bin.Console.errPrintln("Exception during MSF Checksum calculation");
         e.printStackTrace();
       }
     }
index b3c0011..a43dc42 100755 (executable)
@@ -36,6 +36,7 @@ import java.util.StringTokenizer;
 import com.stevesoft.pat.Regex;
 
 import jalview.bin.Jalview;
+import jalview.bin.Jalview.ExitCode;
 import jalview.datamodel.BinaryNode;
 import jalview.datamodel.SequenceNode;
 import jalview.util.MessageManager;
@@ -324,7 +325,7 @@ public class NewickFile extends FileParse
         {
           c.setRight(new SequenceNode(null, c, null, DefDistance,
                   DefBootstrap, false));
-          c = (BinaryNode) c.right();
+          c = c.right();
         }
         else
         {
@@ -338,7 +339,7 @@ public class NewickFile extends FileParse
 
           c.setLeft(new SequenceNode(null, c, null, DefDistance,
                   DefBootstrap, false));
-          c = (BinaryNode) c.left();
+          c = c.left();
         }
 
         if (realroot == null)
@@ -394,7 +395,7 @@ public class NewickFile extends FileParse
           // node string contains Comment or structured/extended NH format info
           /*
            * if ((fcp-cp>1 && nf.substring(cp,fcp).trim().length()>1)) { // will
-           * process in remains System.err.println("skipped text:
+           * process in remains jalview.bin.Console.errPrintln("skipped text:
            * '"+nf.substring(cp,fcp)+"'"); }
            */
           // verify termination.
@@ -579,7 +580,7 @@ public class NewickFile extends FileParse
               // Just advance focus, if we need to
               if ((c.left() != null) && (!c.left().isLeaf()))
               {
-                c = (BinaryNode) c.left();
+                c = c.left();
               }
             }
           }
@@ -617,7 +618,7 @@ public class NewickFile extends FileParse
     }
     // THe next line is failing for topali trees - not sure why yet. if
     // (root.right()!=null && root.isDummy())
-    root = (SequenceNode) root.right().detach(); // remove the imaginary root.
+    root = root.right().detach(); // remove the imaginary root.
 
     if (!RootHasDistance)
     {
@@ -665,7 +666,7 @@ public class NewickFile extends FileParse
             // more codes here.
           } catch (Exception e)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Couldn't parse code '" + code + "' = '" + value + "'");
             e.printStackTrace(System.err);
           }
@@ -947,7 +948,8 @@ public class NewickFile extends FileParse
       if (args == null || args.length != 1)
       {
         Jalview.exit(
-                "Takes one argument - file name of a newick tree file.", 0);
+                "Takes one argument - file name of a newick tree file.",
+                ExitCode.INVALID_ARGUMENT);
       }
 
       File fn = new File(args[0]);
@@ -962,31 +964,35 @@ public class NewickFile extends FileParse
       }
 
       treefile.close();
-      System.out.println("Read file :\n");
+      jalview.bin.Console.outPrintln("Read file :\n");
 
       NewickFile trf = new NewickFile(args[0], DataSourceType.FILE);
       trf.parse();
-      System.out.println("Original file :\n");
+      jalview.bin.Console.outPrintln("Original file :\n");
 
       Regex nonl = new Regex("\n+", "");
-      System.out.println(nonl.replaceAll(newickfile.toString()) + "\n");
-
-      System.out.println("Parsed file.\n");
-      System.out.println("Default output type for original input.\n");
-      System.out.println(trf.print());
-      System.out.println("Without bootstraps.\n");
-      System.out.println(trf.print(false));
-      System.out.println("Without distances.\n");
-      System.out.println(trf.print(true, false));
-      System.out.println("Without bootstraps but with distanecs.\n");
-      System.out.println(trf.print(false, true));
-      System.out.println("Without bootstraps or distanecs.\n");
-      System.out.println(trf.print(false, false));
-      System.out.println("With bootstraps and with distances.\n");
-      System.out.println(trf.print(true, true));
+      jalview.bin.Console
+              .outPrintln(nonl.replaceAll(newickfile.toString()) + "\n");
+
+      jalview.bin.Console.outPrintln("Parsed file.\n");
+      jalview.bin.Console
+              .outPrintln("Default output type for original input.\n");
+      jalview.bin.Console.outPrintln(trf.print());
+      jalview.bin.Console.outPrintln("Without bootstraps.\n");
+      jalview.bin.Console.outPrintln(trf.print(false));
+      jalview.bin.Console.outPrintln("Without distances.\n");
+      jalview.bin.Console.outPrintln(trf.print(true, false));
+      jalview.bin.Console
+              .outPrintln("Without bootstraps but with distanecs.\n");
+      jalview.bin.Console.outPrintln(trf.print(false, true));
+      jalview.bin.Console.outPrintln("Without bootstraps or distanecs.\n");
+      jalview.bin.Console.outPrintln(trf.print(false, false));
+      jalview.bin.Console
+              .outPrintln("With bootstraps and with distances.\n");
+      jalview.bin.Console.outPrintln(trf.print(true, true));
     } catch (java.io.IOException e)
     {
-      System.err.println("Exception\n" + e);
+      jalview.bin.Console.errPrintln("Exception\n" + e);
       e.printStackTrace();
     }
   }
index d9ed516..adfc1cb 100755 (executable)
@@ -59,7 +59,7 @@ public class PIRFile extends AlignFile
     {
       if (line.length() == 0)
       {
-        // System.out.println("blank line");
+        // jalview.bin.Console.outPrintln("blank line");
         continue;
       }
       if (line.indexOf("C;") == 0 || line.indexOf("#") == 0)
index 6b9dc3f..57fae00 100755 (executable)
@@ -137,7 +137,7 @@ public class PfamFile extends AlignFile
       }
       else
       {
-        System.err.println("PFAM File reader: Can't find sequence for "
+        jalview.bin.Console.errPrintln("PFAM File reader: Can't find sequence for "
                 + headers.get(i));
       }
     }
index 12e87a6..7542884 100644 (file)
@@ -188,7 +188,7 @@ public class PhylipFile extends AlignFile
 
     } catch (IOException e)
     {
-      System.err.println("Exception parsing PHYLIP file " + e);
+      jalview.bin.Console.errPrintln("Exception parsing PHYLIP file " + e);
       e.printStackTrace(System.err);
       throw e;
     }
index 3041a23..f8c384d 100644 (file)
@@ -212,8 +212,8 @@ public class RnamlFile extends AlignFile
   // public static void main(String[] args) {
   // Pattern p= Pattern.compile("(.+)[.][^.]+");
   // Matcher m = p.matcher("toto.xml.zip");
-  // System.out.println(m.matches());
-  // System.out.println(m.group(1));
+  // jalview.bin.Console.outPrintln(m.matches());
+  // jalview.bin.Console.outPrintln(m.group(1));
   // }
   /**
    * make a friendly ID string.
index 95bd1cc..0a1172c 100644 (file)
@@ -55,7 +55,7 @@ public class SequenceAnnotationReport
 
   private static final int MAX_REFS_PER_SOURCE = 4;
 
-  private static final int MAX_SOURCES = 40;
+  private static final int MAX_SOURCES = 5;
 
   private static String linkImageURL;
 
@@ -79,10 +79,19 @@ public class SequenceAnnotationReport
       {
         return 1;
       }
+      
       String s1 = ref1.getSource();
       String s2 = ref2.getSource();
       boolean s1Primary = DBRefSource.isPrimarySource(s1);
       boolean s2Primary = DBRefSource.isPrimarySource(s2);
+      if (ref1.isCanonical() && !ref2.isCanonical())
+      {
+        return -1;
+      }
+      if (!ref1.isCanonical() && ref2.isCanonical())
+      {
+        return 1;
+      }
       if (s1Primary && !s2Primary)
       {
         return -1;
@@ -423,7 +432,7 @@ public class SequenceAnnotationReport
             }
           } catch (Exception x)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "problem when creating links from " + urlstring);
             x.printStackTrace();
           }
@@ -446,7 +455,7 @@ public class SequenceAnnotationReport
     UrlLink urlLink = new UrlLink(link);
     if (!urlLink.isValid())
     {
-      System.err.println(urlLink.getInvalidMessage());
+      jalview.bin.Console.errPrintln(urlLink.getInvalidMessage());
       return null;
     }
 
index ba6b2f3..d8b3215 100644 (file)
@@ -165,7 +165,7 @@ public class SimpleBlastFile extends AlignFile
               rstart = Long.parseLong(stindx);
             } catch (Exception e)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Couldn't parse '" + stindx + "' as start of row");
               // inAlignments = false;
               // warn for this line
@@ -175,7 +175,7 @@ public class SimpleBlastFile extends AlignFile
               rend = Long.parseLong(endindx);
             } catch (Exception e)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Couldn't parse '" + endindx + "' as end of row");
               // inAlignments = false;
 
index 28f062f..d674485 100644 (file)
@@ -147,19 +147,19 @@ public class StockholmFile extends AlignFile
               + umcp.getMessage() + ")";
       throw new IOException(umcp);
     }
-    // DEBUG System.out.println("this is the secondary scructure:"
+    // DEBUG jalview.bin.Console.outPrintln("this is the secondary scructure:"
     // +result.size());
     SequenceI[] seqs = new SequenceI[result.size()];
     String id = null;
     for (int i = 0; i < result.size(); i++)
     {
-      // DEBUG System.err.println("Processing i'th sequence in Stockholm file")
+      // DEBUG jalview.bin.Console.errPrintln("Processing i'th sequence in Stockholm file")
       RNA current = result.get(i);
 
       String seq = current.getSeq();
       String rna = current.getStructDBN(true);
-      // DEBUG System.out.println(seq);
-      // DEBUG System.err.println(rna);
+      // DEBUG jalview.bin.Console.outPrintln(seq);
+      // DEBUG jalview.bin.Console.errPrintln(rna);
       int begin = 0;
       int end = seq.length() - 1;
       id = safeName(getDataName());
@@ -441,7 +441,7 @@ public class StockholmFile extends AlignFile
       }
       else if (!r.search(line))
       {
-        // System.err.println("Found sequence line: " + line);
+        // jalview.bin.Console.errPrintln("Found sequence line: " + line);
 
         // Split sequence in sequence and accession parts
         if (!x.search(line))
@@ -465,7 +465,7 @@ public class StockholmFile extends AlignFile
         String annType = r.stringMatched(1);
         String annContent = r.stringMatched(2);
 
-        // System.err.println("type:" + annType + " content: " + annContent);
+        // jalview.bin.Console.errPrintln("type:" + annType + " content: " + annContent);
 
         if (annType.equals("GF"))
         {
@@ -567,7 +567,7 @@ public class StockholmFile extends AlignFile
           else
           {
             // throw new IOException("Error parsing " + line);
-            System.err.println(">> missing annotation: " + line);
+            jalview.bin.Console.errPrintln(">> missing annotation: " + line);
           }
         }
         else if (annType.equals("GC"))
@@ -685,7 +685,7 @@ public class StockholmFile extends AlignFile
           // }
           else
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Warning - couldn't parse sequence annotation row line:\n"
                             + line);
             // throw new IOException("Error parsing " + line);
@@ -937,7 +937,7 @@ public class StockholmFile extends AlignFile
               annot.annotations.length);
       System.arraycopy(els, 0, anns, annot.annotations.length, els.length);
       annot.annotations = anns;
-      // System.out.println("else: ");
+      // jalview.bin.Console.outPrintln("else: ");
     }
     return annot;
   }
@@ -1270,7 +1270,7 @@ public class StockholmFile extends AlignFile
     {
       return (String) typeIds.get(id);
     }
-    System.err.println(
+    jalview.bin.Console.errPrintln(
             "Warning : Unknown Stockholm annotation type code " + id);
     return id;
   }
@@ -1292,7 +1292,7 @@ public class StockholmFile extends AlignFile
     {
       return key;
     }
-    System.err.println(
+    jalview.bin.Console.errPrintln(
             "Warning : Unknown Stockholm annotation type: " + type);
     return key;
   }
index 6ec0298..df384a6 100644 (file)
@@ -242,7 +242,7 @@ public abstract class StructureFile extends AlignFile
   protected void processPdbFileWithAnnotate3d(List<SequenceI> rna)
           throws Exception
   {
-    // System.out.println("this is a PDB format and RNA sequence");
+    // jalview.bin.Console.outPrintln("this is a PDB format and RNA sequence");
     // note: we use reflection here so that the applet can compile and run
     // without the HTTPClient bits and pieces needed for accessing Annotate3D
     // web service
@@ -336,7 +336,7 @@ public abstract class StructureFile extends AlignFile
         processPdbFileWithAnnotate3d(rnaSequences);
       } catch (Exception x)
       {
-        System.err.println("Exceptions when dealing with RNA in pdb file");
+        jalview.bin.Console.errPrintln("Exceptions when dealing with RNA in pdb file");
         x.printStackTrace();
 
       }
@@ -352,7 +352,7 @@ public abstract class StructureFile extends AlignFile
         processWithJmolParser(proteinSequences, true);
       } catch (Exception x)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Exceptions from Jmol when processing data in pdb file");
         x.printStackTrace();
       }
index 7e963d5..52751e9 100644 (file)
@@ -601,7 +601,7 @@ public class TCoffeeScoreFile extends AlignFile
           annotations[j] = null;
           if (val > 0)
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Warning: non-zero value for positional T-COFFEE score for gap at "
                             + j + " in sequence " + s.getName());
           }
index dd4b72c..46b75c8 100644 (file)
@@ -151,7 +151,7 @@ public class VamsasAppDatastore
   private void buildSkipList()
   {
     skipList = new Hashtable();
-    AlignFrame[] al = Desktop.getAlignFrames();
+    AlignFrame[] al = Desktop.getDesktopAlignFrames();
     for (int f = 0; al != null && f < al.length; f++)
     {
       skipList.put(al[f].getViewport().getSequenceSetId(), al[f]);
@@ -460,7 +460,7 @@ public class VamsasAppDatastore
           {
             // removeValignmentSequences(alignment, docseqs);
             docseqs.removeAllElements();
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     "Sequence deletion from alignment is not implemented.");
 
           }
@@ -488,11 +488,11 @@ public class VamsasAppDatastore
           }
           if (alismod)
           {
-            System.out.println("update alignment in document.");
+            jalview.bin.Console.outPrintln("update alignment in document.");
           }
           else
           {
-            System.out.println("alignment in document left unchanged.");
+            jalview.bin.Console.outPrintln("alignment in document left unchanged.");
           }
         }
         else
@@ -500,7 +500,7 @@ public class VamsasAppDatastore
           // unbind alignment from view.
           // create new binding and new alignment.
           // mark trail on new alignment as being derived from old ?
-          System.out.println(
+          jalview.bin.Console.outPrintln(
                   "update edited alignment to new alignment in document.");
         }
       }
@@ -1115,12 +1115,12 @@ public class VamsasAppDatastore
       // METHODS)
       {
         // verify existing alignment sequence annotation is up to date
-        System.out.println("update dataset sequence annotation.");
+        jalview.bin.Console.outPrintln("update dataset sequence annotation.");
       }
       else
       {
         // verify existing alignment sequence annotation is up to date
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "make new alignment dataset sequence annotation if modification has happened.");
       }
     }
@@ -1184,12 +1184,12 @@ public class VamsasAppDatastore
       // METHODS)
       {
         // verify existing alignment sequence annotation is up to date
-        System.out.println("update alignment sequence annotation.");
+        jalview.bin.Console.outPrintln("update alignment sequence annotation.");
       }
       else
       {
         // verify existing alignment sequence annotation is up to date
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "make new alignment sequence annotation if modification has happened.");
       }
     }
index 63b78b2..c7c90f4 100755 (executable)
@@ -84,7 +84,7 @@ public class WSWUBlastClient
     for (int i = 0; i < ids.size(); i++)
     {
       Sequence sequence = (Sequence) ids.get(i);
-      System.out.println(sequence.getName());
+      jalview.bin.Console.outPrintln(sequence.getName());
 
       BlastThread thread = new BlastThread(sequence);
       thread.start();
@@ -249,7 +249,7 @@ public class WSWUBlastClient
 
     BlastThread(Sequence sequence)
     {
-      System.out.println("blasting for: " + sequence.getName());
+      jalview.bin.Console.outPrintln("blasting for: " + sequence.getName());
       this.sequence = sequence;
     }
 
@@ -276,7 +276,7 @@ public class WSWUBlastClient
           else
           {
             Thread.sleep(10000);
-            System.out.println("WSWuBlastClient: I'm alive "
+            jalview.bin.Console.outPrintln("WSWuBlastClient: I'm alive "
                     + sequence.getName() + " " + jobid); // log.debug
           }
         } catch (Exception ex)
@@ -315,7 +315,7 @@ public class WSWUBlastClient
       {
         jobComplete = true;
         jobsRunning--;
-        System.err.println("WSWUBlastClient error:\n" + exp.toString());
+        jalview.bin.Console.errPrintln("WSWUBlastClient error:\n" + exp.toString());
         exp.printStackTrace();
       }
     }
index eedf09a..e4e2d99 100644 (file)
@@ -204,7 +204,7 @@ public class JvCacheableInputBox<E>
       @Override
       public void actionPerformed(ActionEvent e)
       {
-        // System.out.println(">>>>> Clear cache items");
+        // jalview.bin.Console.outPrintln(">>>>> Clear cache items");
         setSelectedItem("");
         appCache.deleteCacheItems(cacheKey);
         updateCache();
index 9ce4cc6..77b641a 100644 (file)
@@ -90,7 +90,7 @@ public class ExonerateHelper extends Gff2Helper
               relaxedIdMatching);
     } catch (IOException ivfe)
     {
-      System.err.println(ivfe);
+      jalview.bin.Console.errPrintln(ivfe);
     }
 
     /*
@@ -200,7 +200,7 @@ public class ExonerateHelper extends Gff2Helper
     }
     else if (!"+".equals(strand))
     {
-      System.err.println("Strand must be specified for alignment");
+      jalview.bin.Console.errPrintln("Strand must be specified for alignment");
       return;
     }
 
@@ -239,7 +239,7 @@ public class ExonerateHelper extends Gff2Helper
     String[] tokens = region.split(" ");
     if (tokens.length != 3)
     {
-      System.err.println("Malformed Align descriptor: " + region);
+      jalview.bin.Console.errPrintln("Malformed Align descriptor: " + region);
       return null;
     }
 
@@ -257,7 +257,7 @@ public class ExonerateHelper extends Gff2Helper
       alignCount = Integer.parseInt(tokens[2]);
     } catch (NumberFormatException nfe)
     {
-      System.err.println(nfe.toString());
+      jalview.bin.Console.errPrintln(nfe.toString());
       return null;
     }
 
@@ -351,7 +351,7 @@ public class ExonerateHelper extends Gff2Helper
         return true;
       }
     }
-    System.err.println("Sorry, I don't handle exonerate model " + model);
+    jalview.bin.Console.errPrintln("Sorry, I don't handle exonerate model " + model);
     return false;
   }
 
index 1ef8848..646900d 100644 (file)
@@ -154,7 +154,7 @@ public class Gff3Helper extends GffHelperBase
      */
     if ("-".equals(strand))
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Skipping mapping from reverse complement as not yet supported");
       return null;
     }
@@ -162,7 +162,7 @@ public class Gff3Helper extends GffHelperBase
     List<String> targets = attributes.get(TARGET);
     if (targets == null)
     {
-      System.err.println("'Target' missing in GFF");
+      jalview.bin.Console.errPrintln("'Target' missing in GFF");
       return null;
     }
 
@@ -178,7 +178,7 @@ public class Gff3Helper extends GffHelperBase
       String[] tokens = target.split(" ");
       if (tokens.length < 3)
       {
-        System.err.println("Incomplete Target: " + target);
+        jalview.bin.Console.errPrintln("Incomplete Target: " + target);
         continue;
       }
 
@@ -225,7 +225,7 @@ public class Gff3Helper extends GffHelperBase
         }
       } catch (NumberFormatException nfe)
       {
-        System.err.println("Invalid start or end in Target " + target);
+        jalview.bin.Console.errPrintln("Invalid start or end in Target " + target);
       }
     }
 
index 22386d4..dccfd27 100644 (file)
@@ -114,7 +114,7 @@ public abstract class GffHelperBase implements GffHelperI
      */
     if (!trimMapping(from, to, fromRatio, toRatio))
     {
-      System.err.println("Ignoring mapping from " + Arrays.toString(from)
+      jalview.bin.Console.errPrintln("Ignoring mapping from " + Arrays.toString(from)
               + " to " + Arrays.toString(to) + " as counts don't match!");
       return null;
     }
@@ -166,7 +166,7 @@ public abstract class GffHelperBase implements GffHelperI
       {
         from[1] += fromOverlap / toRatio;
       }
-      System.err.println(Arrays.toString(from));
+      jalview.bin.Console.errPrintln(Arrays.toString(from));
       return true;
     }
     else if (fromOverlap < 0 && fromOverlap % fromRatio == 0)
@@ -185,7 +185,7 @@ public abstract class GffHelperBase implements GffHelperI
       {
         to[1] += fromOverlap / fromRatio;
       }
-      System.err.println(Arrays.toString(to));
+      jalview.bin.Console.errPrintln(Arrays.toString(to));
       return true;
     }
 
@@ -444,7 +444,7 @@ public abstract class GffHelperBase implements GffHelperI
       return sf;
     } catch (NumberFormatException nfe)
     {
-      System.err.println("Invalid number in gff: " + nfe.getMessage());
+      jalview.bin.Console.errPrintln("Invalid number in gff: " + nfe.getMessage());
       return null;
     }
   }
@@ -504,7 +504,7 @@ public abstract class GffHelperBase implements GffHelperI
 
     if (!valid)
     {
-      System.err.println(INVALID_GFF_ATTRIBUTE_FORMAT + s);
+      jalview.bin.Console.errPrintln(INVALID_GFF_ATTRIBUTE_FORMAT + s);
       return map;
     }
 
@@ -526,7 +526,7 @@ public abstract class GffHelperBase implements GffHelperI
       theKey = theKey.trim();
       if (theKey.isEmpty())
       {
-        System.err.println(INVALID_GFF_ATTRIBUTE_FORMAT + s);
+        jalview.bin.Console.errPrintln(INVALID_GFF_ATTRIBUTE_FORMAT + s);
         map.clear();
         return map;
       }
index 7d354e0..1e77f78 100644 (file)
@@ -215,7 +215,7 @@ public class SequenceOntologyLite implements SequenceOntologyI
       {
         // suppress logging here as it reports Uniprot sequence features
         // (which do not use SO terms) when auto-configuring feature colours
-        // System.out.println("SO term " + term
+        // jalview.bin.Console.outPrintln("SO term " + term
         // + " not known - add to model if needed in "
         // + getClass().getName());
         termsNotFound.add(term);
index 9f84c16..5248a16 100644 (file)
@@ -291,7 +291,7 @@ public class JalviewDataset
     AlignmentSet last = getLastAlignmentSet();
     if (last != null)
     {
-      System.err.println("Deuniquifying last alignment set.");
+      jalview.bin.Console.errPrintln("Deuniquifying last alignment set.");
       last.deuniquifyAlignment();
     }
     al.add(new AlignmentSet(newal));
index 37dd66b..3ce774e 100644 (file)
@@ -246,7 +246,7 @@ public class ParsePackedSet
           fp = new FileParse(file, AppletFormatAdapter.checkProtocol(file));
         } catch (Exception e)
         {
-          System.err.println("Couldn't handle datasource of type " + jtype
+          jalview.bin.Console.errPrintln("Couldn't handle datasource of type " + jtype
                   + " using URI " + file);
           e.printStackTrace();
           return;
@@ -255,7 +255,7 @@ public class ParsePackedSet
       }
       else
       {
-        System.out.println("Couldn't parse source type token '"
+        jalview.bin.Console.outPrintln("Couldn't parse source type token '"
                 + type.toUpperCase(Locale.ROOT) + "'");
       }
     }
@@ -269,7 +269,7 @@ public class ParsePackedSet
       System.out.print("\n");
 
     }
-    System.out.println("Now trying to parse set:");
+    jalview.bin.Console.outPrintln("Now trying to parse set:");
     JalviewDataset context;
     Object[] newdm;
     ParsePackedSet pps;
@@ -279,7 +279,7 @@ public class ParsePackedSet
               .getAlignment(context = new JalviewDataset(), dp);
     } catch (Exception e)
     {
-      System.out.println("Test failed for these arguments.\n");
+      jalview.bin.Console.outPrintln("Test failed for these arguments.\n");
       e.printStackTrace(System.out);
       return;
     }
@@ -287,7 +287,7 @@ public class ParsePackedSet
     {
       for (Object o : newdm)
       {
-        System.out.println("Will need to create an " + o.getClass());
+        jalview.bin.Console.outPrintln("Will need to create an " + o.getClass());
       }
 
       // now test uniquify/deuniquify stuff
@@ -300,7 +300,7 @@ public class ParsePackedSet
     {
       if (context.getLastAlignmentSet().isModified())
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Initial alignment set was modified and any associated views should be updated.");
       }
     }
index a33390f..3183bf6 100644 (file)
@@ -139,7 +139,7 @@ public class Sequencemapping extends Rangetype
 
   private void conflict(Mapping mjvmapping, SequenceMapping sequenceMapping)
   {
-    System.err.println("Conflict in update of sequenceMapping "
+    jalview.bin.Console.errPrintln("Conflict in update of sequenceMapping "
             + sequenceMapping.getVorbaId());
   }
 
index f6d17d4..a6dd8b6 100644 (file)
@@ -415,7 +415,7 @@ public class Tree extends DatastoreItem
             }
             else
             {
-              System.err.println("WARNING: Unassociated treeNode "
+              jalview.bin.Console.errPrintln("WARNING: Unassociated treeNode "
                       + tnode.element().toString() + " "
                       + ((tnode.getName() != null)
                               ? " label " + tnode.getName()
@@ -466,7 +466,7 @@ public class Tree extends DatastoreItem
       occurence = Integer.valueOf(oval).intValue();
     } catch (Exception e)
     {
-      System.err.println("Invalid nodespec '" + nodespec + "'");
+      jalview.bin.Console.errPrintln("Invalid nodespec '" + nodespec + "'");
       return null;
     }
     jalview.datamodel.BinaryNode bn = null;
index ea5b8e0..c3fbea8 100644 (file)
@@ -278,7 +278,7 @@ public class VCFLoader
       initialise(vcfFile);
     } catch (IOException e)
     {
-      System.err.println("Error opening VCF file: " + e.getMessage());
+      jalview.bin.Console.errPrintln("Error opening VCF file: " + e.getMessage());
     }
 
     // map of species!chromosome!fromAssembly!toAssembly to {fromRange, toRange}
@@ -398,7 +398,7 @@ public class VCFLoader
       }
     } catch (Throwable e)
     {
-      System.err.println("Error processing VCF: " + e.getMessage());
+      jalview.bin.Console.errPrintln("Error processing VCF: " + e.getMessage());
       e.printStackTrace();
       if (gui != null)
       {
@@ -678,7 +678,7 @@ public class VCFLoader
         patterns.add(Pattern.compile(token.toUpperCase(Locale.ROOT)));
       } catch (PatternSyntaxException e)
       {
-        System.err.println("Invalid pattern ignored: " + token);
+        jalview.bin.Console.errPrintln("Invalid pattern ignored: " + token);
       }
     }
     return patterns;
index 29f3fa9..c174696 100644 (file)
@@ -171,7 +171,7 @@ public class JSFunctionExec implements Runnable
           {
             if (jvlite.debug && dbgMsg != null)
             {
-              System.err.println(dbgMsg);
+              jalview.bin.Console.errPrintln(dbgMsg);
             }
             scriptObject.call(_listener, objects);
           }
@@ -182,7 +182,7 @@ public class JSFunctionExec implements Runnable
           {
             if (jvlite.debug)
             {
-              System.err.println(jex);
+              jalview.bin.Console.errPrintln(jex);
             }
             if (jex instanceof netscape.javascript.JSException
                     && jvlite.jsfallbackEnabled)
@@ -190,7 +190,7 @@ public class JSFunctionExec implements Runnable
               jsex[0] = jex;
               if (jvlite.debug)
               {
-                System.err.println("Falling back to javascript: url call");
+                jalview.bin.Console.errPrintln("Falling back to javascript: url call");
               }
               StringBuffer sb = new StringBuffer(
                       "javascript:" + _listener + "(");
@@ -213,7 +213,7 @@ public class JSFunctionExec implements Runnable
               sb.append(")");
               if (jvlite.debug)
               {
-                System.err.println(sb.toString());
+                jalview.bin.Console.errPrintln(sb.toString());
               }
               // alternate
               URL url = null;
index c2a963e..eda8741 100644 (file)
@@ -47,7 +47,7 @@ public class JsSelectionSender extends JSFunctionExec
   public void selection(SequenceGroup seqsel, ColumnSelection colsel,
           HiddenColumns hidden, SelectionSource source)
   {
-    // System.err.println("Testing selection event relay to
+    // jalview.bin.Console.errPrintln("Testing selection event relay to
     // jsfunction:"+_listener);
     try
     {
@@ -106,20 +106,20 @@ public class JsSelectionSender extends JSFunctionExec
         ;
 
       }
-      System.err.println("Relaying selection to jsfunction:" + _listener);
+      jalview.bin.Console.errPrintln("Relaying selection to jsfunction:" + _listener);
       executeJavascriptFunction(_listener,
               new Object[]
               { src, setid, jvlite.arrayToSeparatorList(seqs),
                   jvlite.arrayToSeparatorList(cols) });
     } catch (Exception ex)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Jalview Javascript exec error: Couldn't send selection message using function '"
                       + _listener + "'");
       ex.printStackTrace();
       if (ex instanceof netscape.javascript.JSException)
       {
-        System.err.println("Javascript Exception: "
+        jalview.bin.Console.errPrintln("Javascript Exception: "
                 + ((netscape.javascript.JSException) ex).getCause()
                         .toString());
       }
index 16b57a4..70a300c 100644 (file)
@@ -71,12 +71,12 @@ public class MouseOverListener extends JSFunctionExec
       } catch (Exception ex)
       {
 
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "JalviewLite javascript error: Couldn't send mouseOver with handler '"
                         + _listener + "'");
         if (ex instanceof netscape.javascript.JSException)
         {
-          System.err.println("Javascript Exception: "
+          jalview.bin.Console.errPrintln("Javascript Exception: "
                   + ((netscape.javascript.JSException) ex).getMessage());
         }
         ex.printStackTrace();
index e90b968..f0b3132 100644 (file)
@@ -156,7 +156,7 @@ public class MouseOverStructureListener extends JSFunctionExec
                     "" + (atom.getPdbResNum()), "" + atom.getAtomIndex() });
       } catch (Exception ex)
       {
-        System.err.println("Couldn't execute callback with " + _listenerfn
+        jalview.bin.Console.errPrintln("Couldn't execute callback with " + _listenerfn
                 + " for atomSpec: " + atom);
         ex.printStackTrace();
       }
@@ -172,7 +172,7 @@ public class MouseOverStructureListener extends JSFunctionExec
 
     if (JalviewLite.debug)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               this.getClass().getName() + " modelSet[0]: " + modelSet[0]);
       ssm.reportMapping();
     }
@@ -197,7 +197,7 @@ public class MouseOverStructureListener extends JSFunctionExec
         }
         // if (jvlite.debug)
         // {
-        // System.err.println("Mapped '" + modelSet[m] + "' to "
+        // jalview.bin.Console.errPrintln("Mapped '" + modelSet[m] + "' to "
         // + sequence[m].length + " sequences.");
         // }
       }
@@ -260,7 +260,7 @@ public class MouseOverStructureListener extends JSFunctionExec
           executeJavascriptFunction(true, _listenerfn, st);
         } catch (Exception ex)
         {
-          System.err.println("Couldn't execute callback with " + _listenerfn
+          jalview.bin.Console.errPrintln("Couldn't execute callback with " + _listenerfn
                   + " using args { " + st[0] + ", " + st[1] + ", " + st[2]
                   + "," + st[3] + "}"); // + ","+st[4]+"\n");
           ex.printStackTrace();
@@ -274,7 +274,7 @@ public class MouseOverStructureListener extends JSFunctionExec
        * executeJavascriptFunction( false, _listenerfn, st = new String[] {
        * "colourstruct", "" + ((jalview.appletgui.AlignmentPanel) source).av
        * .getViewId(), handle, "" }); } catch (Exception ex) {
-       * System.err.println("Couldn't execute callback with " + _listenerfn +
+       * jalview.bin.Console.errPrintln("Couldn't execute callback with " + _listenerfn +
        * " using args { " + st[0] + ", " + st[1] + ", " + st[2] + "," + st[3] +
        * "\n"); ex.printStackTrace();
        * 
index c0cdfee..7daeb37 100755 (executable)
@@ -57,7 +57,6 @@ import jalview.bin.Cache;
 import jalview.gui.JvSwingUtils;
 import jalview.gui.Preferences;
 import jalview.io.FileFormats;
-import jalview.io.exceptions.ImageOutputException;
 import jalview.schemes.ResidueColourScheme;
 import jalview.util.MessageManager;
 import jalview.util.Platform;
@@ -221,6 +220,7 @@ public class GAlignFrame extends JInternalFrame
   {
     try
     {
+      setFrameIcon(null);
 
       // for Web-page embedding using id=align-frame-div
       setName("jalview-alignment");
@@ -246,7 +246,7 @@ public class GAlignFrame extends JInternalFrame
       }
     } catch (Exception e)
     {
-      System.err.println(e.toString());
+      jalview.bin.Console.errPrintln(e.toString());
     }
 
     if (Platform.allowMnemonics()) // was "not mac and not JS"
@@ -1979,19 +1979,19 @@ public class GAlignFrame extends JInternalFrame
   protected void createPNG_actionPerformed(ActionEvent object)
   {
     // TODO Auto-generated method stub
-    
+
   }
 
   protected void createEPS_actionPerformed(ActionEvent object)
   {
     // TODO Auto-generated method stub
-    
+
   }
 
   protected void createSVG_actionPerformed(ActionEvent object)
   {
     // TODO Auto-generated method stub
-    
+
   }
 
   protected void copyHighlightedColumns_actionPerformed(
@@ -2487,7 +2487,6 @@ public class GAlignFrame extends JInternalFrame
   {
   }
 
-
   protected void font_actionPerformed(ActionEvent e)
   {
   }
@@ -2501,7 +2500,6 @@ public class GAlignFrame extends JInternalFrame
 
   }
 
-
   protected void loadTreeMenuItem_actionPerformed(ActionEvent e)
   {
 
index 6594e2d..2f0c75e 100755 (executable)
@@ -76,7 +76,7 @@ public class GAlignmentPanel extends JPanel
 
   protected JPanel scalePanelHolder = newJPanel();
 
-  protected JPanel idPanelHolder = newJPanel();
+  public JPanel idPanelHolder = newJPanel();
 
   protected JPanel idSpaceFillerPanel1 = newJPanel();
 
index b0079b4..124c7c7 100755 (executable)
@@ -152,7 +152,7 @@ public class GDesktop extends JFrame
       APQHandlers.setAPQHandlers((Desktop) this);
     } catch (Exception e)
     {
-      System.out.println("Cannot set APQHandlers");
+      jalview.bin.Console.outPrintln("Cannot set APQHandlers");
       // e.printStackTrace();
     } catch (Throwable t)
     {
@@ -193,7 +193,7 @@ public class GDesktop extends JFrame
           inputURLMenuItem_actionPerformed(null);
         } catch (FileFormatException e1)
         {
-          System.err.println("Error loading from URL: " + e1.getMessage());
+          jalview.bin.Console.errPrintln("Error loading from URL: " + e1.getMessage());
         }
       }
     });
@@ -521,7 +521,7 @@ public class GDesktop extends JFrame
    */
   protected void quit()
   {
-    // System.out.println("********** GDesktop.quit()");
+    // jalview.bin.Console.outPrintln("********** GDesktop.quit()");
   }
 
   /**
index 8cb5b3c..5b04359 100644 (file)
@@ -295,7 +295,7 @@ public abstract class GStructureChooser extends JPanel
       mainFrame.pack();
     } catch (Exception e)
     {
-      System.out.println(e); // for JavaScript TypeError
+      jalview.bin.Console.outPrintln(e); // for JavaScript TypeError
       e.printStackTrace();
     }
   }
@@ -849,11 +849,11 @@ public abstract class GStructureChooser extends JPanel
 
   protected void closeAction(int preferredHeight)
   {
-    // System.out.println(">>>>>>>>>> closing internal frame!!!");
-    // System.out.println("width : " + mainFrame.getWidth());
-    // System.out.println("heigh : " + mainFrame.getHeight());
-    // System.out.println("x : " + mainFrame.getX());
-    // System.out.println("y : " + mainFrame.getY());
+    // jalview.bin.Console.outPrintln(">>>>>>>>>> closing internal frame!!!");
+    // jalview.bin.Console.outPrintln("width : " + mainFrame.getWidth());
+    // jalview.bin.Console.outPrintln("heigh : " + mainFrame.getHeight());
+    // jalview.bin.Console.outPrintln("x : " + mainFrame.getX());
+    // jalview.bin.Console.outPrintln("y : " + mainFrame.getY());
     tempUserPrefs.put("structureChooser.width", pnl_filter.getWidth());
     tempUserPrefs.put("structureChooser.height", preferredHeight);
     tempUserPrefs.put("structureChooser.x", mainFrame.getX());
index 18e4c9f..fceb50c 100644 (file)
@@ -52,6 +52,8 @@ public abstract class GStructureViewer extends JInternalFrame
 
   protected JMenu chainMenu;
 
+  protected JMenu hetatmMenu;
+
   protected JMenu viewerActionMenu;
 
   protected JMenuItem alignStructs;
@@ -152,6 +154,9 @@ public abstract class GStructureViewer extends JInternalFrame
     chainMenu = new JMenu();
     chainMenu.setText(MessageManager.getString("action.show_chain"));
 
+    hetatmMenu = new JMenu();
+    hetatmMenu.setText(MessageManager.getString("action.show_hetatm"));
+
     fitToWindow = new JMenuItem();
     fitToWindow.setText(MessageManager.getString("label.fit_to_window"));
     fitToWindow.addActionListener(new ActionListener()
@@ -197,6 +202,7 @@ public abstract class GStructureViewer extends JInternalFrame
     savemenu.add(png);
     savemenu.add(eps);
     viewMenu.add(chainMenu);
+    viewMenu.add(hetatmMenu);
     helpMenu.add(helpItem);
 
     menuBar.add(fileMenu);
index cfd41d0..554b997 100644 (file)
@@ -138,13 +138,13 @@ public abstract class JLogger implements JLoggerI
     {
       String logLine = String.format("%s: %s", loglevel.toString(),
               message);
-      System.out.println(logLine);
+      jalview.bin.Console.outPrintln(logLine);
       if (t != null)
       {
         if (loglevel.compareTo(LogLevel.DEBUG) <= 0)
           t.printStackTrace(System.err);
         else
-          System.err.println(t.getMessage());
+          jalview.bin.Console.errPrintln(t.getMessage());
       }
       return false;
     }
index b22bf4e..ad91464 100755 (executable)
@@ -464,7 +464,7 @@ public class Matrix implements MatrixI
           }
           else
           {
-            // System.out.println("Iteration " + iter);
+            // jalview.bin.Console.outPrintln("Iteration " + iter);
           }
 
           g = (d[l] - d[l - 1]) / (2.0 * e[l - 1]);
@@ -728,7 +728,7 @@ public class Matrix implements MatrixI
           }
           else
           {
-            // System.out.println("Iteration " + iter);
+            // jalview.bin.Console.outPrintln("Iteration " + iter);
           }
 
           g = (d[l] - d[l - 1]) / (2.0 * e[l - 1]);
index f3bf436..ea67f48 100755 (executable)
@@ -137,7 +137,7 @@ public class RotatableMatrix
     Float floatValue = Float.valueOf(degrees);
     if (cachedRotations.get(axis).containsKey(floatValue))
     {
-      // System.out.println("getRotation from cache: " + (int) degrees);
+      // jalview.bin.Console.outPrintln("getRotation from cache: " + (int) degrees);
       return cachedRotations.get(axis).get(floatValue);
     }
 
index 6f26036..d5b3808 100644 (file)
@@ -26,7 +26,6 @@ import static jalview.math.RotatableMatrix.Axis.Z;
 
 import java.awt.Color;
 import java.awt.Font;
-import java.awt.FontMetrics;
 import java.awt.Rectangle;
 import java.io.BufferedReader;
 import java.io.ByteArrayInputStream;
@@ -87,16 +86,20 @@ import jalview.api.analysis.SimilarityParamsI;
 import jalview.api.structures.JalviewStructureDisplayI;
 import jalview.bin.Cache;
 import jalview.bin.Console;
+import jalview.bin.Jalview;
 import jalview.datamodel.AlignedCodonFrame;
 import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.AlignmentI;
+import jalview.datamodel.ContactListI;
 import jalview.datamodel.ContactMatrix;
 import jalview.datamodel.ContactMatrixI;
 import jalview.datamodel.DBRefEntry;
+import jalview.datamodel.FloatContactMatrix;
 import jalview.datamodel.GeneLocus;
 import jalview.datamodel.GraphLine;
 import jalview.datamodel.GroupSet;
+import jalview.datamodel.GroupSetI;
 import jalview.datamodel.PDBEntry;
 import jalview.datamodel.Point;
 import jalview.datamodel.RnaViewerModel;
@@ -199,6 +202,7 @@ import jalview.xml.binding.jalview.JalviewUserColours.Colour;
 import jalview.xml.binding.jalview.MapListType;
 import jalview.xml.binding.jalview.MapListType.MapListFrom;
 import jalview.xml.binding.jalview.MapListType.MapListTo;
+import jalview.xml.binding.jalview.MapOnAMatrixType;
 import jalview.xml.binding.jalview.Mapping;
 import jalview.xml.binding.jalview.MatrixType;
 import jalview.xml.binding.jalview.NoValueColour;
@@ -268,7 +272,7 @@ public class Jalview2XML
 
   Map<String, SequenceI> incompleteSeqs = null;
 
-  List<SeqFref> frefedSequence = null;
+  List<forwardRef> frefedSequence = null;
 
   boolean raiseGUI = true; // whether errors are raised in dialog boxes or not
 
@@ -283,6 +287,13 @@ public class Jalview2XML
    * entry names
    */
   private Map<RnaModel, String> rnaSessions = new HashMap<>();
+  
+  /**
+   * map from contact matrices to their XML ids
+   */
+  private Map<ContactMatrixI,String> contactMatrices = new HashMap<>();
+  private Map<String, ContactMatrixI> contactMatrixRefs = new HashMap<>();
+  private List<jalview.xml.binding.jalview.MatrixType> xmlMatrices= new ArrayList<>();
 
   /**
    * A helper method for safely using the value of an optional attribute that
@@ -380,18 +391,17 @@ public class Jalview2XML
   }
 
   /**
-   * base class for resolving forward references to sequences by their ID
+   * base class for resolving forward references to an as-yet unmarshalled object referenced by already unmarshalled objects
    * 
    * @author jprocter
    *
    */
-  abstract class SeqFref
-  {
+  abstract class forwardRef {
     String sref;
 
     String type;
 
-    public SeqFref(String _sref, String type)
+    public forwardRef(String _sref, String type)
     {
       sref = _sref;
       this.type = type;
@@ -402,6 +412,28 @@ public class Jalview2XML
       return sref;
     }
 
+    public abstract boolean isResolvable();
+    /**
+     * @return true if the forward reference was fully resolved
+     */
+    abstract boolean resolve();
+
+    @Override
+    public String toString()
+    {
+      return type + " reference to " + sref;
+    }
+  }
+  /**
+   * resolve forward references to sequences by their ID
+   * @author jprocter
+   */
+  abstract class SeqFref extends forwardRef
+  {
+    public SeqFref(String _sref, String type)
+    {
+      super(_sref, type);
+    }
     public SequenceI getSrefSeq()
     {
       return seqRefIds.get(sref);
@@ -424,17 +456,6 @@ public class Jalview2XML
       }
       return sq;
     }
-
-    /**
-     * @return true if the forward reference was fully resolved
-     */
-    abstract boolean resolve();
-
-    @Override
-    public String toString()
-    {
-      return type + " reference to " + sref;
-    }
   }
 
   /**
@@ -497,15 +518,42 @@ public class Jalview2XML
     };
     return fref;
   }
+  
+  public forwardRef newMatrixFref(final String matRef,
+          final jalview.util.MapList mapping, final AlignmentAnnotation jaa)
+  {
+    forwardRef fref = new forwardRef(matRef,
+            "Matrix Reference for sequence and annotation")
+    {
+
+      @Override
+      boolean resolve()
+      {
+        ContactMatrixI cm = contactMatrixRefs.get(matRef);
+        PAEContactMatrix newpae = new PAEContactMatrix(jaa.sequenceRef,
+                mapping, cm);
+
+        jaa.sequenceRef.addContactListFor(jaa, newpae);
+        return true;
+      }
+
+      @Override
+      public boolean isResolvable()
+      {
+        return (contactMatrixRefs.get(matRef) != null);
+      }
+    };
+    return fref;
+  }
 
   public void resolveFrefedSequences()
   {
-    Iterator<SeqFref> nextFref = frefedSequence.iterator();
+    Iterator<forwardRef> nextFref = frefedSequence.iterator();
     int toresolve = frefedSequence.size();
     int unresolved = 0, failedtoresolve = 0;
     while (nextFref.hasNext())
     {
-      SeqFref ref = nextFref.next();
+      forwardRef ref = nextFref.next();
       if (ref.isResolvable())
       {
         try
@@ -520,7 +568,7 @@ public class Jalview2XML
           }
         } catch (Exception x)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "IMPLEMENTATION ERROR: Failed to resolve forward reference for sequence "
                           + ref.getSref());
           x.printStackTrace();
@@ -534,29 +582,30 @@ public class Jalview2XML
     }
     if (unresolved > 0)
     {
-      System.err.println("Jalview Project Import: There were " + unresolved
+      jalview.bin.Console.errPrintln("Jalview Project Import: There were "
+              + unresolved
               + " forward references left unresolved on the stack.");
     }
     if (failedtoresolve > 0)
     {
-      System.err.println("SERIOUS! " + failedtoresolve
+      jalview.bin.Console.errPrintln("SERIOUS! " + failedtoresolve
               + " resolvable forward references failed to resolve.");
     }
     if (incompleteSeqs != null && incompleteSeqs.size() > 0)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Jalview Project Import: There are " + incompleteSeqs.size()
                       + " sequences which may have incomplete metadata.");
       if (incompleteSeqs.size() < 10)
       {
         for (SequenceI s : incompleteSeqs.values())
         {
-          System.err.println(s.toString());
+          jalview.bin.Console.errPrintln(s.toString());
         }
       }
       else
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Too many to report. Skipping output of incomplete sequences.");
       }
     }
@@ -630,7 +679,7 @@ public class Jalview2XML
    */
   public void saveState(JarOutputStream jout)
   {
-    AlignFrame[] frames = Desktop.getAlignFrames();
+    AlignFrame[] frames = Desktop.getDesktopAlignFrames();
 
     setStateSavedUpToDate(true);
 
@@ -936,7 +985,7 @@ public class Jalview2XML
       object.setCreationDate(now);
     } catch (DatatypeConfigurationException e)
     {
-      System.err.println("error writing date: " + e.toString());
+      jalview.bin.Console.errPrintln("error writing date: " + e.toString());
     }
     object.setVersion(Cache.getDefault("VERSION", "Development Build"));
 
@@ -1003,14 +1052,14 @@ public class Jalview2XML
           // HAPPEN! (PF00072.15.stk does this)
           // JBPNote: Uncomment to debug writing out of files that do not read
           // back in due to ArrayOutOfBoundExceptions.
-          // System.err.println("vamsasSeq backref: "+id+"");
-          // System.err.println(jds.getName()+"
+          // jalview.bin.Console.errPrintln("vamsasSeq backref: "+id+"");
+          // jalview.bin.Console.errPrintln(jds.getName()+"
           // "+jds.getStart()+"-"+jds.getEnd()+" "+jds.getSequenceAsString());
-          // System.err.println("Hashcode: "+seqHash(jds));
+          // jalview.bin.Console.errPrintln("Hashcode: "+seqHash(jds));
           // SequenceI rsq = (SequenceI) seqRefIds.get(id + "");
-          // System.err.println(rsq.getName()+"
+          // jalview.bin.Console.errPrintln(rsq.getName()+"
           // "+rsq.getStart()+"-"+rsq.getEnd()+" "+rsq.getSequenceAsString());
-          // System.err.println("Hashcode: "+seqHash(rsq));
+          // jalview.bin.Console.errPrintln("Hashcode: "+seqHash(rsq));
         }
         else
         {
@@ -1139,38 +1188,55 @@ public class Jalview2XML
            * only view *should* be coped with sensibly.
            */
           // This must have been loaded, is it still visible?
-          JInternalFrame[] frames = Desktop.desktop.getAllFrames();
-          String matchedFile = null;
-          for (int f = frames.length - 1; f > -1; f--)
+          List<JalviewStructureDisplayI> viewFrames = new ArrayList<>();
+          if (Desktop.desktop != null)
           {
-            if (frames[f] instanceof StructureViewerBase)
+            JInternalFrame[] jifs = Desktop.desktop.getAllFrames();
+            if (jifs != null)
             {
-              StructureViewerBase viewFrame = (StructureViewerBase) frames[f];
-              matchedFile = saveStructureViewer(ap, jds, pdb, entry,
-                      viewIds, matchedFile, viewFrame);
-              /*
-               * Only store each structure viewer's state once in the project
-               * jar. First time through only (storeDS==false)
-               */
-              String viewId = viewFrame.getViewId();
-              String viewerType = viewFrame.getViewerType().toString();
-              if (!storeDS && !viewIds.contains(viewId))
+              for (JInternalFrame jif : jifs)
               {
-                viewIds.add(viewId);
-                File viewerState = viewFrame.saveSession();
-                if (viewerState != null)
-                {
-                  copyFileToJar(jout, viewerState.getPath(),
-                          getViewerJarEntryName(viewId), viewerType);
-                }
-                else
+                if (jif instanceof JalviewStructureDisplayI)
                 {
-                  Console.error(
-                          "Failed to save viewer state for " + viewerType);
+                  viewFrames.add((JalviewStructureDisplayI) jif);
                 }
               }
             }
           }
+          else if (Jalview.isHeadlessMode()
+                  && Jalview.getInstance().getCommands() != null)
+          {
+            viewFrames.addAll(
+                    StructureViewerBase.getAllStructureViewerBases());
+          }
+
+          String matchedFile = null;
+          for (JalviewStructureDisplayI viewFrame : viewFrames)
+          {
+            matchedFile = saveStructureViewer(ap, jds, pdb, entry, viewIds,
+                    matchedFile, viewFrame);
+            /*
+             * Only store each structure viewer's state once in the project
+             * jar. First time through only (storeDS==false)
+             */
+            String viewId = viewFrame.getViewId();
+            String viewerType = viewFrame.getViewerType().toString();
+            if (!storeDS && !viewIds.contains(viewId))
+            {
+              viewIds.add(viewId);
+              File viewerState = viewFrame.saveSession();
+              if (viewerState != null)
+              {
+                copyFileToJar(jout, viewerState.getPath(),
+                        getViewerJarEntryName(viewId), viewerType);
+              }
+              else
+              {
+                Console.error(
+                        "Failed to save viewer state for " + viewerType);
+              }
+            }
+          }
 
           if (matchedFile != null || entry.getFile() != null)
           {
@@ -1580,6 +1646,9 @@ public class Jalview2XML
       view.setShowColourText(av.getColourText());
       view.setShowFullId(av.getShowJVSuffix());
       view.setRightAlignIds(av.isRightAlignIds());
+      view.setIdWidth(av.getIdWidth());
+      view.setIdWidthManuallyAdjusted(ap.getIdPanel().getIdCanvas().isManuallyAdjusted());
+      
       view.setShowSequenceFeatures(av.isShowSequenceFeatures());
       view.setShowText(av.getShowText());
       view.setShowUnconserved(av.getShowUnconserved());
@@ -1751,6 +1820,20 @@ public class Jalview2XML
       // jms.addViewport(view);
       object.getViewport().add(view);
     }
+    
+    
+    if (storeDS)
+    {
+      // store matrices referenced by any views or annotation in this dataset
+      if (xmlMatrices!=null && xmlMatrices.size()>0)
+      {
+        Console.debug("Adding "+xmlMatrices.size()+" matrices to dataset.");
+        vamsasSet.getMatrix().addAll(xmlMatrices);
+        xmlMatrices.clear();
+      }
+    }
+
+    
     // object.setJalviewModelSequence(jms);
     // object.getVamsasModel().addSequenceSet(vamsasSet);
     object.getVamsasModel().getSequenceSet().add(vamsasSet);
@@ -1763,7 +1846,7 @@ public class Jalview2XML
       try
       {
         fileName = fileName.replace('\\', '/');
-        System.out.println("Writing jar entry " + fileName);
+        jalview.bin.Console.outPrintln("Writing jar entry " + fileName);
         JarEntry entry = new JarEntry(fileName);
         jout.putNextEntry(entry);
         PrintWriter pout = new PrintWriter(
@@ -1784,7 +1867,7 @@ public class Jalview2XML
       } catch (Exception ex)
       {
         // TODO: raise error in GUI if marshalling failed.
-        System.err.println("Error writing Jalview project");
+        jalview.bin.Console.errPrintln("Error writing Jalview project");
         ex.printStackTrace();
       }
     }
@@ -2098,7 +2181,7 @@ public class Jalview2XML
       File file = new File(infilePath);
       if (file.exists() && jout != null)
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "Writing jar entry " + jarEntryName + " (" + msg + ")");
         jout.putNextEntry(new JarEntry(jarEntryName));
         copyAll(is, jout);
@@ -2147,7 +2230,7 @@ public class Jalview2XML
    */
   protected String saveStructureViewer(AlignmentPanel ap, SequenceI jds,
           Pdbids pdb, PDBEntry entry, List<String> viewIds,
-          String matchedFile, StructureViewerBase viewFrame)
+          String matchedFile, JalviewStructureDisplayI viewFrame)
   {
     final AAStructureBindingModel bindingModel = viewFrame.getBinding();
 
@@ -2192,7 +2275,7 @@ public class Jalview2XML
         {
           StructureState state = new StructureState();
           state.setVisible(true);
-          state.setXpos(viewFrame.getX());
+          state.setXpos(viewFrame.getY());
           state.setYpos(viewFrame.getY());
           state.setWidth(viewFrame.getWidth());
           state.setHeight(viewFrame.getHeight());
@@ -2315,64 +2398,7 @@ public class Jalview2XML
                     .getContactMatrixFor(annotation);
             if (cm != null)
             {
-              MatrixType xmlmat = new MatrixType();
-              xmlmat.setType(cm.getType());
-              xmlmat.setRows(BigInteger.valueOf(cm.getWidth()));
-              xmlmat.setCols(BigInteger.valueOf(cm.getHeight()));
-              // consider using an opaque to/from -> allow instance to control
-              // its representation ?
-              xmlmat.setElements(ContactMatrix.contactToFloatString(cm));
-              if (cm.hasGroups())
-              {
-                for (BitSet gp : cm.getGroups())
-                {
-                  xmlmat.getGroups().add(stringifyBitset(gp));
-                }
-              }
-              if (cm.hasTree())
-              {
-                // provenance object for tree ?
-                xmlmat.getNewick().add(cm.getNewick());
-                xmlmat.setTreeMethod(cm.getTreeMethod());
-              }
-              if (cm.hasCutHeight())
-              {
-                xmlmat.setCutHeight(cm.getCutHeight());
-              }
-              // set/get properties
-              if (cm instanceof MappableContactMatrixI)
-              {
-                jalview.util.MapList mlst = ((MappableContactMatrixI) cm)
-                        .getMapFor(annotation.sequenceRef);
-                if (mlst != null)
-                {
-                  MapListType mp = new MapListType();
-                  List<int[]> r = mlst.getFromRanges();
-                  for (int[] range : r)
-                  {
-                    MapListFrom mfrom = new MapListFrom();
-                    mfrom.setStart(range[0]);
-                    mfrom.setEnd(range[1]);
-                    // mp.addMapListFrom(mfrom);
-                    mp.getMapListFrom().add(mfrom);
-                  }
-                  r = mlst.getToRanges();
-                  for (int[] range : r)
-                  {
-                    MapListTo mto = new MapListTo();
-                    mto.setStart(range[0]);
-                    mto.setEnd(range[1]);
-                    // mp.addMapListTo(mto);
-                    mp.getMapListTo().add(mto);
-                  }
-                  mp.setMapFromUnit(
-                          BigInteger.valueOf(mlst.getFromRatio()));
-                  mp.setMapToUnit(BigInteger.valueOf(mlst.getToRatio()));
-                  xmlmat.setMapping(mp);
-                }
-              }
-              // and add to model
-              an.getContactmatrix().add(xmlmat);
+              storeMatrixFor(vamsasSet, an,annotation, cm);
             }
           }
         }
@@ -2479,6 +2505,88 @@ public class Jalview2XML
 
   }
 
+  private void storeMatrixFor(SequenceSet root, Annotation an, AlignmentAnnotation annotation, ContactMatrixI cm)
+  {
+    String cmId = contactMatrices.get(cm);
+    MatrixType xmlmat=null;
+    
+    // first create an xml ref for the matrix data, if none exist
+    if (cmId == null)
+    {
+      xmlmat = new MatrixType();
+      xmlmat.setType(cm.getType());
+      xmlmat.setRows(BigInteger.valueOf(cm.getWidth()));
+      xmlmat.setCols(BigInteger.valueOf(cm.getHeight()));
+      // consider using an opaque to/from -> allow instance to control
+      // its representation ?
+      xmlmat.setElements(ContactMatrix.contactToFloatString(cm));
+      if (cm.hasGroups())
+      {
+        for (BitSet gp : cm.getGroups())
+        {
+          xmlmat.getGroups().add(stringifyBitset(gp));
+        }
+      }
+      if (cm.hasTree())
+      {
+        // provenance object for tree ?
+        xmlmat.getNewick().add(cm.getNewick());
+        xmlmat.setTreeMethod(cm.getTreeMethod());
+      }
+      if (cm.hasCutHeight())
+      {
+        xmlmat.setCutHeight(cm.getCutHeight());
+      }
+      xmlmat.setId(cmId = "m"+contactMatrices.size()+System.currentTimeMillis());
+      Console.trace("Matrix data stored :"+cmId);
+      contactMatrices.put(cm, cmId);
+      contactMatrixRefs.put(cmId, cm);
+      xmlMatrices.add(xmlmat);
+    } else {
+      Console.trace("Existing Matrix stored :"+cmId);
+    }
+
+    // now store mapping
+
+    MapOnAMatrixType xmlmatmapping = new MapOnAMatrixType();
+    xmlmatmapping.setMatrix(cmId);
+    
+    // Pretty much all matrices currently managed in this way are
+    // mappableContactMatrixI implementations - but check anyway
+    if (cm instanceof MappableContactMatrixI)
+    {
+      jalview.util.MapList mlst = ((MappableContactMatrixI) cm)
+              .getMapFor(annotation.sequenceRef);
+      if (mlst != null)
+      {
+        MapListType mp = new MapListType();
+        List<int[]> r = mlst.getFromRanges();
+        for (int[] range : r)
+        {
+          MapListFrom mfrom = new MapListFrom();
+          mfrom.setStart(range[0]);
+          mfrom.setEnd(range[1]);
+          // mp.addMapListFrom(mfrom);
+          mp.getMapListFrom().add(mfrom);
+        }
+        r = mlst.getToRanges();
+        for (int[] range : r)
+        {
+          MapListTo mto = new MapListTo();
+          mto.setStart(range[0]);
+          mto.setEnd(range[1]);
+          // mp.addMapListTo(mto);
+          mp.getMapListTo().add(mto);
+        }
+        mp.setMapFromUnit(BigInteger.valueOf(mlst.getFromRatio()));
+        mp.setMapToUnit(BigInteger.valueOf(mlst.getToRatio()));
+        xmlmatmapping.setMapping(mp);
+      }
+    }
+    // and add to model
+    an.getContactmatrix().add(xmlmatmapping);
+  }
+
   private String stringifyBitset(BitSet gp)
   {
     StringBuilder sb = new StringBuilder();
@@ -2516,6 +2624,7 @@ public class Jalview2XML
     return BitSet.valueOf(newlongvals);
 
   }
+
   private CalcIdParam createCalcIdParam(String calcId, AlignViewport av)
   {
     AutoCalcSetting settings = av.getCalcIdSettingsFor(calcId);
@@ -2959,7 +3068,8 @@ public class Jalview2XML
         });
       } catch (Exception x)
       {
-        System.err.println("Error loading alignment: " + x.getMessage());
+        jalview.bin.Console
+                .errPrintln("Error loading alignment: " + x.getMessage());
       }
     }
     return af;
@@ -2998,19 +3108,22 @@ public class Jalview2XML
         {
           if (bytes != null)
           {
-            // System.out.println("Jalview2XML: opening byte jarInputStream for
+            // jalview.bin.Console.outPrintln("Jalview2XML: opening byte
+            // jarInputStream for
             // bytes.length=" + bytes.length);
             return new JarInputStream(new ByteArrayInputStream(bytes));
           }
           if (_url != null)
           {
-            // System.out.println("Jalview2XML: opening url jarInputStream for "
+            // jalview.bin.Console.outPrintln("Jalview2XML: opening url
+            // jarInputStream for "
             // + _url);
             return new JarInputStream(_url.openStream());
           }
           else
           {
-            // System.out.println("Jalview2XML: opening file jarInputStream for
+            // jalview.bin.Console.outPrintln("Jalview2XML: opening file
+            // jarInputStream for
             // " + file);
             return new JarInputStream(new FileInputStream(file));
           }
@@ -3050,6 +3163,7 @@ public class Jalview2XML
       initSeqRefs();
     }
     AlignFrame af = null, _af = null;
+    List<AlignFrame> toRepaint=new ArrayList<AlignFrame>();
     IdentityHashMap<AlignmentI, AlignmentI> importedDatasets = new IdentityHashMap<>();
     Map<String, AlignFrame> gatherToThisFrame = new HashMap<>();
     final String file = jprovider.getFilename();
@@ -3084,6 +3198,7 @@ public class Jalview2XML
             if (_af != null && object.getViewport().size() > 0)
             // getJalviewModelSequence().getViewportCount() > 0)
             {
+              toRepaint.add(_af);
               if (af == null)
               {
                 // store a reference to the first view
@@ -3113,15 +3228,20 @@ public class Jalview2XML
       } while (jarentry != null);
       jin.close();
       resolveFrefedSequences();
+      for (AlignFrame alignFrame:toRepaint)
+      {
+        alignFrame.repaint();
+      }
     } catch (IOException ex)
     {
       ex.printStackTrace();
       errorMessage = "Couldn't locate Jalview XML file : " + file;
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Exception whilst loading jalview XML file : " + ex + "\n");
     } catch (Exception ex)
     {
-      System.err.println("Parsing as Jalview Version 2 file failed.");
+      jalview.bin.Console
+              .errPrintln("Parsing as Jalview Version 2 file failed.");
       ex.printStackTrace(System.err);
       if (attemptversion1parse)
       {
@@ -3133,18 +3253,19 @@ public class Jalview2XML
       }
       if (af != null)
       {
-        System.out.println("Successfully loaded archive file");
+        jalview.bin.Console.outPrintln("Successfully loaded archive file");
         return af;
       }
       ex.printStackTrace();
 
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Exception whilst loading jalview XML file : " + ex + "\n");
     } catch (OutOfMemoryError e)
     {
       // Don't use the OOM Window here
       errorMessage = "Out of memory loading jalview XML file";
-      System.err.println("Out of memory whilst loading jalview XML file");
+      jalview.bin.Console
+              .errPrintln("Out of memory whilst loading jalview XML file");
       e.printStackTrace();
     }
 
@@ -3248,8 +3369,8 @@ public class Jalview2XML
         Desktop.addInternalFrame(af, view.getTitle(),
                 safeInt(view.getWidth()), safeInt(view.getHeight()));
         af.setMenusForViewport();
-        System.err.println("Failed to restore view " + view.getTitle()
-                + " to split frame");
+        jalview.bin.Console.errPrintln("Failed to restore view "
+                + view.getTitle() + " to split frame");
       }
     }
 
@@ -3327,7 +3448,8 @@ public class Jalview2XML
       }
       else
       {
-        System.err.println("Problem loading Jalview file: " + errorMessage);
+        jalview.bin.Console.errPrintln(
+                "Problem loading Jalview file: " + errorMessage);
       }
     }
     errorMessage = null;
@@ -3500,6 +3622,14 @@ public class Jalview2XML
     }
 
     // ////////////////////////////////
+    // LOAD MATRICES (IF ANY)
+    
+    if (vamsasSet.getMatrix()!=null && vamsasSet.getMatrix().size()>0)
+    {
+      importMatrixData(vamsasSet.getMatrix());
+    }
+    
+    // ////////////////////////////////
     // LOAD SEQUENCES
 
     List<SequenceI> hiddenSeqs = null;
@@ -3525,7 +3655,7 @@ public class Jalview2XML
           if (tmpSeq.getStart() != jseq.getStart()
                   || tmpSeq.getEnd() != jseq.getEnd())
           {
-            System.err.println(String.format(
+            jalview.bin.Console.errPrintln(String.format(
                     "Warning JAL-2154 regression: updating start/end for sequence %s from %d/%d to %d/%d",
                     tmpSeq.getName(), tmpSeq.getStart(), tmpSeq.getEnd(),
                     jseq.getStart(), jseq.getEnd()));
@@ -4031,80 +4161,10 @@ public class Jalview2XML
           if (annotation.getContactmatrix() != null
                   && annotation.getContactmatrix().size() > 0)
           {
-            for (MatrixType xmlmat : annotation.getContactmatrix())
+            for (MapOnAMatrixType xmlmat : annotation.getContactmatrix())
             {
-              if (PAEContactMatrix.PAEMATRIX.equals(xmlmat.getType()))
-              {
-                if (!xmlmat.getRows().equals(xmlmat.getCols()))
-                {
-                  Console.error("Can't handle non square PAE Matrices");
-                }
-                else
-                {
-                  float[][] elements = ContactMatrix
-                          .fromFloatStringToContacts(xmlmat.getElements(),
-                                  xmlmat.getCols().intValue(),
-                                  xmlmat.getRows().intValue());
-                  jalview.util.MapList mapping = null;
-                  if (xmlmat.getMapping() != null)
-                  {
-                    MapListType m = xmlmat.getMapping();
-                    // Mapping m = dr.getMapping();
-                    int fr[] = new int[m.getMapListFrom().size() * 2];
-                    Iterator<MapListFrom> from = m.getMapListFrom()
-                            .iterator();// enumerateMapListFrom();
-                    for (int _i = 0; from.hasNext(); _i += 2)
-                    {
-                      MapListFrom mf = from.next();
-                      fr[_i] = mf.getStart();
-                      fr[_i + 1] = mf.getEnd();
-                    }
-                    int fto[] = new int[m.getMapListTo().size() * 2];
-                    Iterator<MapListTo> to = m.getMapListTo().iterator();// enumerateMapListTo();
-                    for (int _i = 0; to.hasNext(); _i += 2)
-                    {
-                      MapListTo mf = to.next();
-                      fto[_i] = mf.getStart();
-                      fto[_i + 1] = mf.getEnd();
-                    }
-
-                    mapping = new jalview.util.MapList(fr, fto,
-                            m.getMapFromUnit().intValue(),
-                            m.getMapToUnit().intValue());
-                  }
-                  List<BitSet> newgroups = new ArrayList<BitSet>();
-                  if (xmlmat.getGroups().size() > 0)
-                  {
-                    for (String sgroup : xmlmat.getGroups())
-                    {
-                      newgroups.add(deStringifyBitset(sgroup));
-                    }
-                  }
-                  String nwk = xmlmat.getNewick().size() > 0
-                          ? xmlmat.getNewick().get(0)
-                          : null;
-                  if (xmlmat.getNewick().size() > 1)
-                  {
-                    Console.log.info(
-                            "Ignoring additional clusterings for contact matrix");
-                  }
-                  String treeMethod = xmlmat.getTreeMethod();
-                  double thresh = xmlmat.getCutHeight() != null
-                          ? xmlmat.getCutHeight()
-                          : 0;
-                  GroupSet grpset = new GroupSet();
-                  grpset.restoreGroups(newgroups, treeMethod, nwk, thresh);
-                  PAEContactMatrix newpae = new PAEContactMatrix(
-                          jaa.sequenceRef, mapping, elements, grpset);
-                  jaa.sequenceRef.addContactListFor(jaa, newpae);
-                }
-              }
-              else
-              {
-                Console.error("Ignoring CONTACT_MAP annotation with type "
-                        + xmlmat.getType());
-              }
-            }
+              restoreMatrixFor(jaa.sequenceRef, jaa, xmlmat);
+            } 
           }
         }
 
@@ -4256,7 +4316,7 @@ public class Jalview2XML
       // XML.
       // and then recover its containing af to allow the settings to be applied.
       // TODO: fix for vamsas demo
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "About to recover a viewport for existing alignment: Sequence set ID is "
                       + uniqueSeqSetId);
       Object seqsetobj = retrieveExistingObj(uniqueSeqSetId);
@@ -4265,13 +4325,13 @@ public class Jalview2XML
         if (seqsetobj instanceof String)
         {
           uniqueSeqSetId = (String) seqsetobj;
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Recovered extant sequence set ID mapping for ID : New Sequence set ID is "
                           + uniqueSeqSetId);
         }
         else
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Warning : Collision between sequence set ID string and existing jalview object mapping.");
         }
 
@@ -4334,6 +4394,105 @@ public class Jalview2XML
     return af;
   }
 
+  private void importMatrixData(List<MatrixType> xmlmatrices)
+  {
+    for (MatrixType xmlmat:xmlmatrices)
+    {
+      if (!PAEContactMatrix.PAEMATRIX.equals(xmlmat.getType()))
+      {
+        Console.error("Ignoring matrix '"+xmlmat.getId()+"' of type '"+xmlmat.getType());
+        continue;
+      }
+
+      if (!xmlmat.getRows().equals(xmlmat.getCols()))
+      {
+        Console.error("Can't handle non square matrices");
+        continue;
+      }
+
+      float[][] elements = ContactMatrix
+              .fromFloatStringToContacts(xmlmat.getElements(),
+                      xmlmat.getCols().intValue(),
+                      xmlmat.getRows().intValue());
+      
+      List<BitSet> newgroups = new ArrayList<BitSet>();
+      if (xmlmat.getGroups().size() > 0)
+      {
+        for (String sgroup : xmlmat.getGroups())
+        {
+          newgroups.add(deStringifyBitset(sgroup));
+        }
+      }
+      String nwk = xmlmat.getNewick().size() > 0
+              ? xmlmat.getNewick().get(0)
+              : null;
+      if (xmlmat.getNewick().size() > 1)
+      {
+        Console.log.info(
+                "Ignoring additional clusterings for contact matrix");
+      }
+      String treeMethod = xmlmat.getTreeMethod();
+      double thresh = xmlmat.getCutHeight() != null
+              ? xmlmat.getCutHeight()
+              : 0;
+      GroupSet grpset = new GroupSet();
+      grpset.restoreGroups(newgroups, treeMethod, nwk, thresh);
+      
+      FloatContactMatrix newcm = new FloatContactMatrix(elements, grpset);
+      contactMatrixRefs.put(xmlmat.getId(), newcm);
+      Console.trace("Restored base contact matrix "+xmlmat.getId());
+    }
+  }
+
+  private void restoreMatrixFor(SequenceI sequenceRef,
+          AlignmentAnnotation jaa, MapOnAMatrixType xmlmatmapping)
+  {    
+    // restore mapping data to matrix data
+    jalview.util.MapList mapping = null;
+    if (xmlmatmapping.getMapping() != null)
+    {
+      MapListType m = xmlmatmapping.getMapping();
+      // Mapping m = dr.getMapping();
+      int fr[] = new int[m.getMapListFrom().size() * 2];
+      Iterator<MapListFrom> from = m.getMapListFrom().iterator();// enumerateMapListFrom();
+      for (int _i = 0; from.hasNext(); _i += 2)
+      {
+        MapListFrom mf = from.next();
+        fr[_i] = mf.getStart();
+        fr[_i + 1] = mf.getEnd();
+      }
+      int fto[] = new int[m.getMapListTo().size() * 2];
+      Iterator<MapListTo> to = m.getMapListTo().iterator();// enumerateMapListTo();
+      for (int _i = 0; to.hasNext(); _i += 2)
+      {
+        MapListTo mf = to.next();
+        fto[_i] = mf.getStart();
+        fto[_i + 1] = mf.getEnd();
+      }
+
+      mapping = new jalview.util.MapList(fr, fto,
+              m.getMapFromUnit().intValue(), m.getMapToUnit().intValue());
+    }
+    
+    // locate matrix data in project XML and import
+    ContactMatrixI cm = contactMatrixRefs.get(xmlmatmapping.getMatrix());
+    if (cm == null)
+    {
+      frefedSequence
+              .add(newMatrixFref(xmlmatmapping.getMatrix(), mapping, jaa));
+    }
+    else
+    {
+      // create the PAEMatrix now
+      PAEContactMatrix newpae = new PAEContactMatrix(jaa.sequenceRef,
+              mapping, cm);
+
+      jaa.sequenceRef.addContactListFor(jaa, newpae);
+    }
+
+    return;
+  }
+
   /**
    * Load Overview window, restoring colours, 'show hidden regions' flag, title
    * and geometry as saved
@@ -4491,7 +4650,7 @@ public class Jalview2XML
         {
           if (tree.isColumnWise())
           {
-            AlignmentAnnotation aa = (AlignmentAnnotation) annotationIds
+            AlignmentAnnotation aa = annotationIds
                     .get(tree.getColumnReference());
             if (aa == null)
             {
@@ -4711,7 +4870,7 @@ public class Jalview2XML
         createOrLinkStructureViewer(entry, af, ap, jprovider);
       } catch (Exception e)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Error loading structure viewer: " + e.getMessage());
         // failed - try the next one
       }
@@ -4915,7 +5074,7 @@ public class Jalview2XML
             || version.equalsIgnoreCase("Test")
             || version.equalsIgnoreCase("AUTOMATED BUILD"))
     {
-      System.err.println("Assuming project file with "
+      jalview.bin.Console.errPrintln("Assuming project file with "
               + (version == null ? "null" : version)
               + " is compatible with Jalview version " + supported);
       return true;
@@ -4962,7 +5121,7 @@ public class Jalview2XML
     //
     // @Override
     // protected void processKeyEvent(java.awt.event.KeyEvent e) {
-    // System.out.println("Jalview2XML AF " + e);
+    // jalview.bin.Console.outPrintln("Jalview2XML AF " + e);
     // super.processKeyEvent(e);
     //
     // }
@@ -5085,6 +5244,21 @@ public class Jalview2XML
     }
     af.setBounds(safeInt(view.getXpos()), safeInt(view.getYpos()),
             safeInt(view.getWidth()), safeInt(view.getHeight()));
+    
+    af.alignPanel.fontChanged(); // make sure font is updated *before* we set ID width
+    if (view.getIdWidth()==null)
+    {
+      if (!isVersionStringLaterThan("2.11.3", jm.getVersion())) {
+        // Pre 2.11.3 jalview projects do not store the id width
+        // idWidth was also calculated in a different way.
+        viewport.setIdWidth(af.alignPanel.getLegacyIdWidth());
+        af.alignPanel.getIdPanel().getIdCanvas().setManuallyAdjusted(true);
+      }
+    } else {
+      viewport.setIdWidth(view.getIdWidth());
+      af.alignPanel.getIdPanel().getIdCanvas().setManuallyAdjusted(view.isIdWidthManuallyAdjusted());
+    }
+    
     // startSeq set in af.alignPanel.updateLayout below
     af.alignPanel.updateLayout();
     ColourSchemeI cs = null;
@@ -5377,8 +5551,9 @@ public class Jalview2XML
     }
     if (matchedAnnotation == null)
     {
-      System.err.println("Failed to match annotation colour scheme for "
-              + annotationId);
+      jalview.bin.Console
+              .errPrintln("Failed to match annotation colour scheme for "
+                      + annotationId);
       return null;
     }
     // belt-and-braces create a threshold line if the
@@ -5836,7 +6011,7 @@ public class Jalview2XML
         }
         // TODO: merges will never happen if we 'know' we have the real dataset
         // sequence - this should be detected when id==dssid
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "DEBUG Notice:  Merged dataset sequence (if you see this often, post at http://issues.jalview.org/browse/JAL-1474)"); // ("
         // + (pre ? "prepended" : "") + " "
         // + (post ? "appended" : ""));
@@ -6029,7 +6204,7 @@ public class Jalview2XML
       }
       else
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Warning - making up dataset sequence id for DbRef sequence map reference");
         sqid = ((Object) ms).toString(); // make up a new hascode for
         // undefined dataset sequence hash
@@ -6710,7 +6885,7 @@ public class Jalview2XML
     } catch (IllegalStateException e)
     {
       // mixing AND and OR conditions perhaps
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               String.format("Error reading filter conditions for '%s': %s",
                       featureType, e.getMessage()));
       // return as much as was parsed up to the error
@@ -6791,7 +6966,8 @@ public class Jalview2XML
       }
       else
       {
-        System.err.println("Malformed compound filter condition");
+        jalview.bin.Console
+                .errPrintln("Malformed compound filter condition");
       }
     }
   }
@@ -6891,7 +7067,7 @@ public class Jalview2XML
     if (stateSavedUpToDate()) // nothing happened since last project save
       return true;
 
-    AlignFrame[] frames = Desktop.getAlignFrames();
+    AlignFrame[] frames = Desktop.getDesktopAlignFrames();
     if (frames != null)
     {
       for (int i = 0; i < frames.length; i++)
index cba36d2..9438e9a 100644 (file)
@@ -175,7 +175,6 @@ public class AnnotationRenderer
           int x, int y, int iconOffset, int startRes, int column,
           boolean validRes, boolean validEnd)
   {
-    g.setColor(STEM_COLOUR);
     int sCol = (lastSSX / charWidth)
             + hiddenColumns.visibleToAbsoluteColumn(startRes);
     int x1 = lastSSX;
@@ -190,6 +189,13 @@ public class AnnotationRenderer
             || row_annotations[column] == null
             || dc != row_annotations[column].secondaryStructure;
 
+    if (diffupstream || diffdownstream)
+    {
+      // draw glyphline under arrow
+      drawGlyphLine(g, lastSSX, x, y, iconOffset);
+    }
+    g.setColor(STEM_COLOUR);
+
     if (column > 0 && Rna.isClosingParenthesis(dc))
     {
       if (diffupstream)
@@ -202,7 +208,8 @@ public class AnnotationRenderer
          */
         fillPolygon(g, new int[] { lastSSX + 5, lastSSX + 5, lastSSX },
                 new int[]
-                { y + iconOffset, y + 13 + iconOffset, y + 7 + iconOffset },
+                { y + iconOffset + 1, y + 13 + iconOffset,
+                    y + 7 + iconOffset },
                 3);
         x1 += 5;
       }
@@ -220,9 +227,10 @@ public class AnnotationRenderer
          * if annotation ending with an opeing base pair half of the stem, 
          * display a forward arrow
          */
-        fillPolygon(g, new int[] { x2 - 5, x2 - 5, x2 },
+        fillPolygon(g, new int[] { x2 - 6, x2 - 6, x2 - 1 },
                 new int[]
-                { y + iconOffset, y + 13 + iconOffset, y + 7 + iconOffset },
+                { y + iconOffset + 1, y + 13 + iconOffset,
+                    y + 7 + iconOffset },
                 3);
         x2 -= 5;
       }
@@ -232,6 +240,7 @@ public class AnnotationRenderer
       }
     }
     // draw arrow body
+    unsetAntialias(g);
     fillRect(g, x1, y + 4 + iconOffset, x2 - x1, 6);
   }
 
@@ -1267,7 +1276,6 @@ public class AnnotationRenderer
       }
       else
       {
-        // g.setColor(Color.orange);
         fillRoundRect(g, lastSSX, y + 3 + iconOffset, x2 - x1 - ofs, 8, 0,
                 0);
       }
@@ -1278,7 +1286,6 @@ public class AnnotationRenderer
       }
       else
       {
-        // g.setColor(Color.magenta);
         fillRoundRect(g, lastSSX + ofs, y + 3 + iconOffset, x2 - x1 - ofs,
                 8, 0, 0);
       }
index 9fd4de6..a1443c8 100644 (file)
@@ -1,6 +1,8 @@
 package jalview.renderer;
 
+import java.util.Arrays;
 import java.util.Iterator;
+import java.util.List;
 
 import jalview.datamodel.ColumnSelection;
 import jalview.datamodel.ContactListI;
@@ -19,21 +21,45 @@ public class ContactGeometry
 
   final ContactListI contacts;
 
+  /**
+   * how many pixels per contact (1..many)
+   */
   final int pixels_step;
 
+  /**
+   * how many contacts per pixel (many > 0)
+   */
   final double contacts_per_pixel;
 
+  /**
+   * number of contacts being mapped
+   */
   final int contact_height;
 
+  /**
+   * number of pixels to map contact_height to
+   */
   final int graphHeight;
 
+  /**
+   * number of contacts for each pixel_step - to last whole contact
+   */
+  final double contacts_step;
+  
+  final int lastStep;
+
+  /**
+   * Bean used to map from a range of contacts to a range of pixels
+   * @param contacts
+   * @param graphHeight Number of pixels to map given range of contacts
+   */
   public ContactGeometry(final ContactListI contacts, int graphHeight)
   {
     this.contacts = contacts;
     this.graphHeight = graphHeight;
     contact_height = contacts.getContactHeight();
     // fractional number of contacts covering each pixel
-    contacts_per_pixel = (graphHeight < 1) ? contact_height
+    contacts_per_pixel = (graphHeight <= 1) ? contact_height
             : ((double) contact_height) / ((double) graphHeight);
 
     if (contacts_per_pixel >= 1)
@@ -47,6 +73,8 @@ public class ContactGeometry
       pixels_step = (int) Math
               .ceil(((double) graphHeight) / (double) contact_height);
     }
+    contacts_step = pixels_step*contacts_per_pixel;
+    lastStep = (int) Math.min((double)graphHeight, ((double)graphHeight)/((double)pixels_step));
   }
 
   public class contactInterval
@@ -69,6 +97,22 @@ public class ContactGeometry
 
     public final int pEnd;
 
+    @Override
+    public boolean equals(Object obj)
+    {
+      if (obj == null || !(obj instanceof contactInterval))
+      {
+        return false;
+      }
+      contactInterval them = (contactInterval) obj;
+      return cStart == them.cStart && cEnd == them.cEnd && pEnd == them.pEnd
+              && pStart == them.pStart;
+    }
+    @Override
+    public String toString()
+    {
+      return "Contacts ["+cStart+","+cEnd+"] : Pixels ["+pStart+","+pEnd+"]";
+    }
   }
 
   /**
@@ -100,7 +144,7 @@ public class ContactGeometry
       {
         // TODO: turn into function on hiddenColumns and create test !!
         Iterator<int[]> viscont = hiddenColumns.getVisContigsIterator(
-                mappedRange[p], mappedRange[p + 1], false);
+                -1+mappedRange[p], -1+mappedRange[p + 1], false);
         containsHidden = !viscont.hasNext();
         if (!containsHidden)
         {
@@ -112,8 +156,8 @@ public class ContactGeometry
       }
       else
       {
-        rowsel = columnSelection.intersects(mappedRange[p],
-                mappedRange[p + 1]);
+        rowsel = columnSelection.intersects(-1+mappedRange[p],
+                -1+mappedRange[p + 1]);
       }
     }
     return rowsel;
@@ -121,21 +165,56 @@ public class ContactGeometry
   }
 
   /**
+   * Return mapped cell intersecting pStart \
+   * 
+   * FIXME: REDUNDANT METHOD - COULD DELETE FIXME: OR RE-IMPLEMENT AS EFFICIENT
+   * RANGE QUERY
    * 
    * @param pStart
+   *          [0..)
    * @param pEnd
-   * @return range for
+   * @return nearest full cell containing pStart - does not set
+   *         contactInterval.pEnd or cEnd to equivalent position on pEnd !
    */
   public contactInterval mapFor(int pStart, int pEnd)
   {
-    int cStart = (int) Math.floor(pStart * contacts_per_pixel);
-    contactInterval ci = new contactInterval(cStart,
-            (int) Math.min(contact_height,
-                    Math.ceil(
-                            cStart + (pEnd - pStart) * contacts_per_pixel)),
-            pStart, pEnd);
-
-    return ci;
+    if (pStart < 0)
+    {
+      pStart = 0;
+    }
+    if (pEnd < pStart)
+    {
+      pEnd = pStart;
+    }
+    if (pEnd >= graphHeight)
+    {
+      pEnd = graphHeight - 1;
+    }
+    if (pStart >= graphHeight)
+    {
+      pStart = graphHeight - pixels_step;
+    }
+    int step = Math.floorDiv(pStart, pixels_step);
+    return findStep(step);
+  }
+
+  /**
+   * 
+   * @param step
+   *          [0..) n steps covering height and contactHeight
+   * @return contactInterval for step, or null if out of bounds
+   */
+  contactInterval findStep(int step)
+  {
+    if (step < 0 || step > lastStep)
+    {
+      return null;
+    }
+    return new contactInterval((int) Math.floor(contacts_step * step),
+            -1 + (int) Math.min(contact_height,
+                    Math.floor(contacts_step * (step + 1))),
+            pixels_step * step,
+            Math.min(graphHeight, (step + 1) * pixels_step) - 1);
   }
 
   /**
@@ -146,15 +225,31 @@ public class ContactGeometry
    */
   public contactInterval mapFor(int pCentre)
   {
-    int pStart = Math.max(pCentre - pixels_step, 0);
-    int pEnd = Math.min(pStart + pixels_step, graphHeight);
-    int cStart = (int) Math.floor(pStart * contacts_per_pixel);
-    contactInterval ci = new contactInterval(cStart,
-            (int) Math.min(contact_height,
-                    Math.ceil(cStart + (pixels_step) * contacts_per_pixel)),
-            pStart, pEnd);
-
-    return ci;
+    if (pCentre >= graphHeight + pixels_step)
+    {
+      return null;
+    }
+    int step = Math.floorDiv(pCentre, pixels_step);
+    return findStep(step);
+  }
+
+  public List<contactInterval> allSteps()
+  {
+    contactInterval[] array = new contactInterval[lastStep + 1];
+    int csum = 0, psum = 0;
+    for (int i = 0; i <= lastStep; i++)
+    {
+      array[i] = findStep(i);
+      csum += 1 + array[i].cEnd - array[i].cStart;
+      psum += 1 + array[i].pEnd - array[i].pStart;
+    }
+    if (csum != contact_height || psum != graphHeight)
+    {
+      System.err.println("csum = " + csum + " not " + contact_height + "\n"
+              + "psum = " + psum + " not " + graphHeight);
+      return null;
+    }
+    return Arrays.asList(array);
   }
 
   public Iterator<contactInterval> iterateOverContactIntervals(
index 0471145..edf3ca2 100644 (file)
@@ -49,6 +49,15 @@ public abstract class ContactMapRenderer implements AnnotationRowRendererI
      */
     Color selMinColor, selMaxColor;
 
+    /**
+     * 
+     * @param no_data - colour when no data available
+     * @param hidden - colour if this row is hidden
+     * @param maxColor - colour for maximum value of contact
+     * @param minColor - colour for minimum value of contact
+     * @param selMinColor - min colour if the contact has been selected
+     * @param selMaxColor - max colour if contact is selected
+     */
     public Shading(Color no_data, Color hidden, Color maxColor,
             Color minColor, Color selMinColor, Color selMaxColor)
     {
@@ -79,8 +88,8 @@ public abstract class ContactMapRenderer implements AnnotationRowRendererI
       {
         return new Shading(Color.pink, Color.red,
 
-                new Color(246, 252, 243), new Color(0, 60, 26),
-                new Color(26, 0, 60), new Color(243, 246, 252));
+                new Color(247, 252, 245), new Color(0, 68, 28),
+                new Color(28, 0, 68), new Color(245,247,252));
       }
     };
   }
@@ -119,6 +128,10 @@ public abstract class ContactMapRenderer implements AnnotationRowRendererI
     int column;
     int aaMax = aa_annotations.length - 1;
     ContactMatrixI cm = viewport.getContactMatrix(_aa);
+    if (cm==null)
+    {
+      return;
+    }
     while (x < eRes - sRes)
     {
       column = sRes + x;
@@ -169,14 +182,14 @@ public abstract class ContactMapRenderer implements AnnotationRowRendererI
       for (int ht = 0, botY = topY
               - _aa.height; ht < _aa.graphHeight; ht += cgeom.pixels_step)
       {
-        ContactGeometry.contactInterval ci = cgeom.mapFor(ht,
-                ht + cgeom.pixels_step);
+        ContactGeometry.contactInterval ci = cgeom.mapFor(ht);
         // cstart = (int) Math.floor(((double) y2 - ht) * contacts_per_pixel);
         // cend = (int) Math.min(contact_height,
         // Math.ceil(cstart + contacts_per_pixel * pixels_step));
 
         Color col;
-        boolean rowsel = false, containsHidden = false;
+        boolean rowsel = false;
+        boolean containsHidden = false;
         if (columnSelection != null)
         {
           rowsel = cgeom.intersects(ci, columnSelection, hiddenColumns,
@@ -217,7 +230,7 @@ public abstract class ContactMapRenderer implements AnnotationRowRendererI
         g.setColor(col);
         if (cgeom.pixels_step > 1)
         {
-          g.fillRect(x * charWidth, botY+ht, charWidth, 1 + cgeom.pixels_step);
+          g.fillRect(x * charWidth, botY+ht, charWidth, cgeom.pixels_step);
         }
         else
         {
@@ -248,7 +261,7 @@ public abstract class ContactMapRenderer implements AnnotationRowRendererI
   {
     ContactRange cr = cl.getRangeFor(i, j);
     // average for moment - probably more interested in maxIntProj though
-    return jalview.util.ColorUtils.getGraduatedColour((float) cr.getMean(),
+    return jalview.util.ColorUtils.getGraduatedColour((float) cr.getMin(),
             0, shade.selMinColor, max, shade.selMaxColor);
   }
 
index a37882f..32672dd 100644 (file)
@@ -94,7 +94,7 @@ public class RestHandler extends AbstractRequestHandler
     final String reply = "REST not yet implemented; received "
             + request.getMethod() + ": " + request.getRequestURL()
             + (queryString == null ? "" : "?" + queryString);
-    System.out.println(reply);
+    jalview.bin.Console.outPrintln(reply);
 
     response.setHeader("Cache-Control", "no-cache/no-store");
     response.setHeader("Content-type", "text/plain");
index 061ccd4..f80669d 100644 (file)
@@ -117,7 +117,7 @@ public class ColourSchemeLoader
     } catch (Exception ex)
     {
       // used to try to parse a V1 Castor generated colours file
-      System.err.println("Failed to read colour scheme from " + filePath
+      jalview.bin.Console.errPrintln("Failed to read colour scheme from " + filePath
               + " : " + ex.toString());
     }
 
index 698769c..e2a8cb3 100644 (file)
@@ -77,7 +77,7 @@ public class ColourSchemes
                 cs.getSchemeClass().getDeclaredConstructor().newInstance());
       } catch (InstantiationException | IllegalAccessException e)
       {
-        System.err.println("Error instantiating colour scheme for "
+        jalview.bin.Console.errPrintln("Error instantiating colour scheme for "
                 + cs.toString() + " " + e.getMessage());
         e.printStackTrace();
       } catch (ReflectiveOperationException roe)
@@ -97,7 +97,7 @@ public class ColourSchemes
     String name = cs.getSchemeName();
     if (name == null)
     {
-      System.err.println("ColourScheme name may not be null");
+      jalview.bin.Console.errPrintln("ColourScheme name may not be null");
       return;
     }
 
index 9d2c738..fe71d31 100755 (executable)
@@ -46,7 +46,7 @@ public class Consensus
     this.mask = setNums(s);
 
     // for (int i=0; i < mask.length; i++) {
-    // System.out.println(mask[i] + " " + ResidueProperties.aa[mask[i]]);
+    // jalview.bin.Console.outPrintln(mask[i] + " " + ResidueProperties.aa[mask[i]]);
     // }
   }
 
@@ -56,7 +56,7 @@ public class Consensus
   @Deprecated
   public boolean isConserved(int[][] cons2, int col, int size)
   {
-    System.out.println("DEPRECATED!!!!");
+    jalview.bin.Console.outPrintln("DEPRECATED!!!!");
     return isConserved(cons2, col, size, true);
   }
 
@@ -75,7 +75,7 @@ public class Consensus
 
     if (tot > ((threshold * size) / 100))
     {
-      // System.out.println("True conserved "+tot+" from "+threshold+" out of
+      // jalview.bin.Console.outPrintln("True conserved "+tot+" from "+threshold+" out of
       // "+size+" : "+maskstr);
       return true;
     }
index dc7971b..4884283 100644 (file)
@@ -65,9 +65,9 @@ public class CovariationColourScheme extends ResidueColourScheme
 
     for (int x = 0; x < this.annotation._rnasecstr.length; x++)
     {
-      // System.out.println(this.annotation._rnasecstr[x] + " Begin" +
+      // jalview.bin.Console.outPrintln(this.annotation._rnasecstr[x] + " Begin" +
       // this.annotation._rnasecstr[x].getBegin());
-      // System.out.println(this.annotation._rnasecstr[x].getFeatureGroup());
+      // jalview.bin.Console.outPrintln(this.annotation._rnasecstr[x].getFeatureGroup());
       // pairs.put(this.annotation._rnasecstr[x].getBegin(),
       // this.annotation._rnasecstr[x].getEnd());
 
@@ -104,7 +104,7 @@ public class CovariationColourScheme extends ResidueColourScheme
   @Override
   public Color findColour(char c)
   {
-    // System.out.println("called"); log.debug
+    // jalview.bin.Console.outPrintln("called"); log.debug
     // Generate a random pastel color
 
     return ResidueProperties.purinepyrimidine[ResidueProperties.purinepyrimidineIndex[c]];// jalview.util.ColorUtils.generateRandomColor(Color.white);
@@ -124,16 +124,16 @@ public class CovariationColourScheme extends ResidueColourScheme
   {
     Color currentColour = Color.white;
     String currentHelix = null;
-    // System.out.println(c + " " + j);
+    // jalview.bin.Console.outPrintln(c + " " + j);
     currentHelix = positionsToHelix.get(j);
-    // System.out.println(positionsToHelix.get(j));
+    // jalview.bin.Console.outPrintln(positionsToHelix.get(j));
 
     if (currentHelix != null)
     {
       currentColour = helixcolorhash.get(currentHelix);
     }
 
-    // System.out.println(c + " " + j + " helix " + currentHelix + " " +
+    // jalview.bin.Console.outPrintln(c + " " + j + " helix " + currentHelix + " " +
     // currentColour);
     return currentColour;
   }
index f1bade1..3d91b58 100644 (file)
@@ -395,7 +395,7 @@ public class FeatureColour implements FeatureColourI
         {
           if (!ttype.toLowerCase(Locale.ROOT).startsWith("no"))
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Ignoring unrecognised threshold type : " + ttype);
           }
         }
@@ -409,19 +409,19 @@ public class FeatureColour implements FeatureColourI
           featureColour.setThreshold(Float.valueOf(tval).floatValue());
         } catch (Exception e)
         {
-          System.err.println("Couldn't parse threshold value as a float: ("
+          jalview.bin.Console.errPrintln("Couldn't parse threshold value as a float: ("
                   + tval + ")");
         }
       }
       if (gcol.hasMoreTokens())
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Ignoring additional tokens in parameters in graduated colour specification\n");
         while (gcol.hasMoreTokens())
         {
-          System.err.println(BAR + gcol.nextToken());
+          jalview.bin.Console.errPrintln(BAR + gcol.nextToken());
         }
-        System.err.println("\n");
+        jalview.bin.Console.errPrintln("\n");
       }
       return featureColour;
     } catch (Exception e)
index 33b275d..62b4579 100644 (file)
@@ -142,10 +142,10 @@ public class RNAHelicesColour extends ResidueColourScheme
       {
 
         /*
-         * System.out.println(this.annotation._rnasecstr[x] + " Begin" +
+         * jalview.bin.Console.outPrintln(this.annotation._rnasecstr[x] + " Begin" +
          * this.annotation._rnasecstr[x].getBegin());
          */
-        // System.out.println(this.annotation._rnasecstr[x].getFeatureGroup());
+        // jalview.bin.Console.outPrintln(this.annotation._rnasecstr[x].getFeatureGroup());
 
         positionsToHelix.put(this.annotation._rnasecstr[x].getBegin(),
                 this.annotation._rnasecstr[x].getFeatureGroup());
index 42d03ec..f8b7856 100755 (executable)
@@ -2414,7 +2414,7 @@ public class ResidueProperties
   public static void main(String[] args)
   {
     Hashtable<String, Vector<String>> aaProps = new Hashtable<>();
-    System.out.println("my %aa = {");
+    jalview.bin.Console.outPrintln("my %aa = {");
     // invert property hashes
     for (String pname : propHash.keySet())
     {
@@ -2446,12 +2446,12 @@ public class ResidueProperties
         System.out.print("'" + props.nextElement() + "'");
         if (props.hasMoreElements())
         {
-          System.out.println(", ");
+          jalview.bin.Console.outPrintln(", ");
         }
       }
-      System.out.println("]" + (res.hasMoreElements() ? "," : ""));
+      jalview.bin.Console.outPrintln("]" + (res.hasMoreElements() ? "," : ""));
     }
-    System.out.println("};");
+    jalview.bin.Console.outPrintln("};");
   }
 
   // to here
index d55ffbf..ec0f008 100755 (executable)
@@ -108,7 +108,7 @@ public class UserColourScheme extends ResidueColourScheme
 
     if (col == null)
     {
-      System.out.println("Making colour from name: " + colour);
+      jalview.bin.Console.outPrintln("Making colour from name: " + colour);
       col = ColorUtils.createColourFromName(colour);
     }
 
@@ -234,7 +234,7 @@ public class UserColourScheme extends ResidueColourScheme
       }
     } catch (Exception ex)
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "Error parsing userDefinedColours:\n" + token + "\n" + ex);
     }
 
index 0b5874a..9c2bc6b 100644 (file)
@@ -26,6 +26,8 @@ import java.util.List;
 import java.util.Map;
 import java.util.Map.Entry;
 
+import jalview.bin.Console;
+
 /**
  * A base class holding methods useful to all classes that implement commands
  * for structure viewers
@@ -275,4 +277,10 @@ public abstract class StructureCommandsBase implements StructureCommandsI
   {
     return null;
   }
+  
+  @Override
+  public StructureCommandI restoreSession(String filePath)
+  {
+    return loadFile(filePath);
+  }
 }
index 575f256..8ba94b0 100644 (file)
@@ -21,6 +21,7 @@
 package jalview.structure;
 
 import java.awt.Color;
+import java.util.Collections;
 import java.util.List;
 import java.util.Map;
 
@@ -193,6 +194,15 @@ public interface StructureCommandsI
    * @return
    */
   StructureCommandI openSession(String filepath);
+  
+  /**
+   * Returns command to restore a previously saved version of an existing structure viewer session file. 
+   * Default implementation calls 'openSession' 
+   * @param filePath
+   * @return
+   */
+  StructureCommandI restoreSession(String filePath);
+
 
   /**
    * Returns a command to ask the viewer to close down
@@ -245,4 +255,8 @@ public interface StructureCommandsI
   StructureCommandI getResidueAttributes(String attName);
 
   List<StructureCommandI> centerViewOn(List<AtomSpecModel> residues);
+
+  default List<StructureCommandI> showHetatms(List<String> toShow) {
+    return Collections.EMPTY_LIST;
+  }
 }
index 64c1547..2f1ddc0 100644 (file)
@@ -155,16 +155,16 @@ public class StructureSelectionManager
   {
     if (mappings.isEmpty())
     {
-      System.err.println("reportMapping: No PDB/Sequence mappings.");
+      jalview.bin.Console.errPrintln("reportMapping: No PDB/Sequence mappings.");
     }
     else
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "reportMapping: There are " + mappings.size() + " mappings.");
       int i = 0;
       for (StructureMapping sm : mappings)
       {
-        System.err.println("mapping " + i++ + " : " + sm.pdbfile);
+        jalview.bin.Console.errPrintln("mapping " + i++ + " : " + sm.pdbfile);
       }
     }
   }
@@ -357,6 +357,31 @@ public class StructureSelectionManager
             pdbFile, sourceType, tft, paeFilename, true);
   }
 
+
+  /**
+   * create sequence structure mappings between each sequence and the given
+   * pdbFile (retrieved via the given protocol). Either constructs a mapping
+   * using NW alignment or derives one from any available SIFTS mapping data.
+   * 
+   * @param forStructureView
+   *          when true, record the mapping for use in mouseOvers
+   * 
+   * @param sequenceArray
+   *          - one or more sequences to be mapped to pdbFile
+   * @param targetChainIds
+   *          - optional chain specification for mapping each sequence to pdb
+   *          (may be nill, individual elements may be nill) - JBPNote: JAL-2693
+   *          - this should be List<List<String>>, empty lists indicate no
+   *          predefined mappings
+   * @param pdbFile
+   *          - structure data resource
+   * @param sourceType
+   *          - how to resolve data from resource
+   * @param tft - specify how to interpret the temperature factor column in the atom data
+   * @param paeFilename - when not null, specifies a filename containing a matrix formatted in JSON using one of the known PAE formats
+   * @param doXferSettings - when true, transfer annotation to mapped sequences in sequenceArray 
+   * @return null or the structure data parsed as a pdb file
+   */
   synchronized public StructureFile setMapping(boolean forStructureView,
           SequenceI[] sequenceArray, String[] targetChainIds,
           String pdbFile, DataSourceType sourceType, TFType tft,
@@ -617,12 +642,12 @@ public class StructureSelectionManager
               chain.transferResidueAnnotation(siftsMapping, null);
             } catch (SiftsException e)
             {
-              System.err.println(e.getMessage());
+              jalview.bin.Console.errPrintln(e.getMessage());
             } catch (Exception e)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Unexpected exception during SIFTS mapping - falling back to NW for this sequence/structure pair");
-              System.err.println(e.getMessage());
+              jalview.bin.Console.errPrintln(e.getMessage());
             }
           }
           if (!foundSiftsMappings.isEmpty())
@@ -1025,7 +1050,7 @@ public class StructureSelectionManager
           int indexpos = sm.getSeqPos(atom.getPdbResNum());
           if (lastipos != indexpos || lastseq != sm.sequence)
           {
-            results.addResult(sm.sequence, indexpos, indexpos);
+            results.appendResult(sm.sequence, indexpos, indexpos);
             lastipos = indexpos;
             lastseq = sm.sequence;
             // construct highlighted sequence list
@@ -1254,7 +1279,7 @@ public class StructureSelectionManager
      * 
      * if (mappings[j].sequence == seq && mappings[j].getPdbId().equals(pdbid)
      * && mappings[j].pdbfile.equals(sl.getPdbFile())) {
-     * System.out.println(pdbid+" "+mappings[j].getPdbId() +"
+     * jalview.bin.Console.outPrintln(pdbid+" "+mappings[j].getPdbId() +"
      * "+mappings[j].pdbfile);
      * 
      * java.awt.Color col; for(int index=0; index<seq.getLength(); index++) {
@@ -1351,7 +1376,7 @@ public class StructureSelectionManager
       boolean removed = seqmappings.remove(acf);
       if (removed && seqmappings.isEmpty())
       { // debug
-        System.out.println("All mappings removed");
+        jalview.bin.Console.outPrintln("All mappings removed");
       }
     }
   }
index 7d9674e..9c8afdf 100644 (file)
@@ -26,6 +26,7 @@ import java.io.IOException;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.BitSet;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.LinkedHashMap;
 import java.util.List;
@@ -780,7 +781,7 @@ public abstract class AAStructureBindingModel
 
     if (waiting)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Timed out waiting for structure viewer to load file "
                       + notLoaded);
       return false;
@@ -884,14 +885,7 @@ public abstract class AAStructureBindingModel
       {
         for (int s : cs.getSelected())
         {
-          if (hiddenCols == null)
-          {
             matched.set(s);
-          }
-          else
-          {
-            matched.set(hiddenCols.visibleToAbsoluteColumn(s));
-          }
         }
       }
       else
@@ -1098,7 +1092,7 @@ public abstract class AAStructureBindingModel
    * @param getReply
    * @param msg
    */
-  protected List<String> executeCommands(List<StructureCommandI> commands,
+  public List<String> executeCommands(List<StructureCommandI> commands,
           boolean getReply, String msg)
   {
     return executeCommand(getReply, msg,
@@ -1546,6 +1540,31 @@ public abstract class AAStructureBindingModel
     return f;
   }
 
+
+  /**
+   * Use restoreSession when you want to restore a previously saved sesssion to
+   * the running viewer instance.
+   * 
+   * @param absolutePath
+   */
+  public void restoreSession(String absolutePath)
+  {
+    String prefix = getViewerType().toString();
+    try {
+
+      StructureCommandI cmd = commandGenerator.restoreSession(absolutePath);
+      if (cmd != null)
+      {
+        executeCommand(cmd, false);
+      }
+    } catch (Throwable e)
+    {
+      Console.error(String.format("Error restoring %s session: %s", prefix,
+              e.toString()));
+    }
+
+  }
+
   /**
    * Saves the structure viewer session to the given file
    * 
@@ -1988,4 +2007,22 @@ public abstract class AAStructureBindingModel
   {
     return 0;
   }
+
+  /**
+   * list the ligands available for display/hiding in the current view
+   * @return HETATM CODE:Molecule name
+   */
+  public Map<String, String> getHetatmNames() {
+    return Collections.EMPTY_MAP;
+  }
+  /**
+   * Generates and executes a command to show the given hetatm types as CPK
+   * 
+   * @param toShow - one or more of strings from getHetatmNames
+   */
+  public void showHetatms(List<String> toShow)
+  {
+    executeCommands(commandGenerator.showHetatms(toShow), false, "Adjusting hetatm visibility");
+  }
+
 }
index 850a230..c298639 100644 (file)
@@ -99,7 +99,7 @@ public class IdentifiersUrlProvider extends UrlProviderImpl
       }
       else
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "Unexpected key returned from identifiers jalview service");
         return idData;
       }
@@ -132,7 +132,7 @@ public class IdentifiersUrlProvider extends UrlProviderImpl
     // BH 2018 -- added more valuable report
     if (errorMessage != null)
     {
-      System.err.println("IdentifiersUrlProvider: cannot read " + idFileName
+      jalview.bin.Console.errPrintln("IdentifiersUrlProvider: cannot read " + idFileName
               + ": " + errorMessage);
     }
     return idData;
index 2cb0173..7d8e4e4 100644 (file)
@@ -84,7 +84,7 @@ public class UrlProvider implements UrlProviderI
       }
     }
 
-    System.out.println(
+    jalview.bin.Console.outPrintln(
             "Error initialising UrlProvider - no custom url provider");
     return null;
   }
index cf44dcb..6fa7c5c 100644 (file)
@@ -49,6 +49,7 @@ import java.io.PipedOutputStream;
 import java.io.PrintStream;
 
 import jalview.bin.Jalview;
+import jalview.bin.Jalview.ExitCode;
 
 public class AWTConsole extends WindowAdapter
         implements WindowListener, ActionListener, Runnable
@@ -138,20 +139,20 @@ public class AWTConsole extends WindowAdapter
     // testing part
     // you may omit this part for your application
     //
-    System.out.println("Hello World 2");
-    System.out.println("All fonts available to Graphic2D:\n");
+    jalview.bin.Console.outPrintln("Hello World 2");
+    jalview.bin.Console.outPrintln("All fonts available to Graphic2D:\n");
     GraphicsEnvironment ge = GraphicsEnvironment
             .getLocalGraphicsEnvironment();
     String[] fontNames = ge.getAvailableFontFamilyNames();
     for (int n = 0; n < fontNames.length; n++)
     {
-      System.out.println(fontNames[n]);
+      jalview.bin.Console.outPrintln(fontNames[n]);
     }
     // Testing part: simple an error thrown anywhere in this JVM will be printed
     // on the Console
     // We do it with a seperate Thread becasue we don't wan't to break a Thread
     // used by the Console.
-    System.out.println("\nLets throw an error on this console");
+    jalview.bin.Console.outPrintln("\nLets throw an error on this console");
     errorThrower = new Thread(this);
     errorThrower.setDaemon(true);
     errorThrower.start();
@@ -176,7 +177,7 @@ public class AWTConsole extends WindowAdapter
     } catch (Exception e)
     {
     }
-    Jalview.exit("Window closing. Bye!", 0);
+    Jalview.exit("Window closing. Bye!", ExitCode.OK);
   }
 
   @Override
index 4832588..b0f25eb 100644 (file)
@@ -86,7 +86,7 @@ public class ChannelProperties
     if (channelPropsURL == null)
     {
       // complete failure of channel_properties, set all properties to defaults
-      System.err.println("Failed to find '/" + CHANNEL_PROPERTIES_FILENAME
+      jalview.bin.Console.errPrintln("Failed to find '/" + CHANNEL_PROPERTIES_FILENAME
               + "' file at '"
               + (channelPropsURL == null ? "null"
                       : channelPropsURL.toString())
@@ -102,7 +102,7 @@ public class ChannelProperties
         channelPropsIS.close();
       } catch (IOException e)
       {
-        System.err.println(e.getMessage());
+        jalview.bin.Console.errPrintln(e.getMessage());
         // return false;
       }
     }
@@ -157,10 +157,10 @@ public class ChannelProperties
         channelProps.load(is);
       } catch (FileNotFoundException e)
       {
-        System.err.println(e.getMessage());
+        jalview.bin.Console.errPrintln(e.getMessage());
       } catch (IOException e)
       {
-        System.err.println(e.getMessage());
+        jalview.bin.Console.errPrintln(e.getMessage());
       }
     }
   }
@@ -214,7 +214,7 @@ public class ChannelProperties
       }
       else
       {
-        System.err.println("Failed to get channel property '" + key + "'");
+        jalview.bin.Console.errPrintln("Failed to get channel property '" + key + "'");
       }
     }
     return null;
@@ -266,7 +266,7 @@ public class ChannelProperties
       img = imgIcon == null ? null : imgIcon.getImage();
       if (img == null)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Failed to load channel image " + key + "=" + path);
         if (!useClassDefaultImage)
         {
@@ -293,7 +293,7 @@ public class ChannelProperties
       {
         return urlMap().getOrDefault(key, null);
       }
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Do not use getImageURL(key) before using getImage(key...)");
     }
     return null;
index 98d5e11..a101d82 100755 (executable)
@@ -406,7 +406,7 @@ public class DBRefUtils
         }
         else
         {
-          System.err.println("Malformed PDB DR line:" + acn);
+          jalview.bin.Console.errPrintln("Malformed PDB DR line:" + acn);
         }
       }
       else
index e62a7d6..983ba75 100644 (file)
@@ -36,6 +36,8 @@ public class FileUtils
           boolean allowSingleFilenameThatDoesNotExist)
   {
     pattern = substituteHomeDir(pattern);
+    String relativePattern = pattern.startsWith(File.separator) ? null
+            : pattern;
     List<File> files = new ArrayList<>();
     /*
      * For efficiency of the Files.walkFileTree(), let's find the longest path that doesn't need globbing.
@@ -60,7 +62,11 @@ public class FileUtils
     {
       String pS = pattern.substring(0, lastFS + 1);
       String rest = pattern.substring(lastFS + 1);
-      Path parentDir = Paths.get(pS).toAbsolutePath();
+      if ("".equals(pS))
+      {
+        pS = ".";
+      }
+      Path parentDir = Paths.get(pS);
       if (parentDir.toFile().exists())
       {
         try
@@ -175,18 +181,94 @@ public class FileUtils
       return null;
 
     String dirname = null;
-    try
-    {
-      File p = file.getParentFile();
-      File d = new File(substituteHomeDir(p.getPath()));
-      dirname = d.getCanonicalPath();
-    } catch (IOException e)
+    File p = file.getParentFile();
+    if (p == null)
     {
-      Console.debug(
-              "Exception when getting dirname of '" + file.getPath() + "'",
-              e);
-      dirname = "";
+      p = new File(".");
     }
+    File d = new File(substituteHomeDir(p.getPath()));
+    dirname = d.getPath();
     return dirname;
   }
+
+  public static String convertWildcardsToPath(String value, String wildcard,
+          String dirname, String basename)
+  {
+    if (value == null)
+    {
+      return null;
+    }
+    StringBuilder path = new StringBuilder();
+    int lastFileSeparatorIndex = value.lastIndexOf(File.separatorChar);
+    int wildcardBeforeIndex = value.indexOf(wildcard);
+    if (lastFileSeparatorIndex > wildcard.length() - 1
+            && wildcardBeforeIndex < lastFileSeparatorIndex)
+    {
+      path.append(value.substring(0, wildcardBeforeIndex));
+      path.append(dirname);
+      path.append(value.substring(wildcardBeforeIndex + wildcard.length(),
+              lastFileSeparatorIndex + 1));
+    }
+    else
+    {
+      path.append(value.substring(0, lastFileSeparatorIndex + 1));
+    }
+    int wildcardAfterIndex = value.indexOf(wildcard,
+            lastFileSeparatorIndex);
+    if (wildcardAfterIndex > lastFileSeparatorIndex)
+    {
+      path.append(value.substring(lastFileSeparatorIndex + 1,
+              wildcardAfterIndex));
+      path.append(basename);
+      path.append(value.substring(wildcardAfterIndex + wildcard.length()));
+    }
+    else
+    {
+      path.append(value.substring(lastFileSeparatorIndex + 1));
+    }
+    return path.toString();
+  }
+
+  public static File getParentDir(File file)
+  {
+    if (file == null)
+    {
+      return null;
+    }
+    File parentDir = file.getAbsoluteFile().getParentFile();
+    return parentDir;
+  }
+
+  public static boolean checkParentDir(File file, boolean mkdirs)
+  {
+    if (file == null)
+    {
+      return false;
+    }
+    File parentDir = getParentDir(file);
+    if (parentDir.exists())
+    {
+      // already exists, nothing to do so nothing to worry about!
+      return true;
+    }
+
+    if (!mkdirs)
+    {
+      return false;
+    }
+
+    Path path = file.toPath();
+    for (int i = 0; i < path.getNameCount(); i++)
+    {
+      Path p = path.getName(i);
+      if ("..".equals(p.toString()))
+      {
+        Console.warn("Cautiously not running mkdirs on " + file.toString()
+                + " because the path to be made contains '..'");
+        return false;
+      }
+    }
+
+    return parentDir.mkdirs();
+  }
 }
index ce7ab6d..df2c76c 100755 (executable)
@@ -940,7 +940,7 @@ public class Format
   }
 
   /**
-   * Bespoke method to format percentage float value to the specified number of
+   * Bespoke method to format a percentage (or any other) float value to the specified number of
    * decimal places. Avoids use of general-purpose format parsers as a
    * processing hotspot.
    * 
index 67309a0..bd375bb 100644 (file)
@@ -585,7 +585,7 @@ public class GroupUrlLink
               // debug
               /*
                * for (int s = 0; s <= rg.numSubs(); s++) {
-               * System.err.println("Sub " + s + " : " + rg.matchedFrom(s) +
+               * jalview.bin.Console.errPrintln("Sub " + s + " : " + rg.matchedFrom(s) +
                * " : " + rg.matchedTo(s) + " : '" + rg.stringMatched(s) + "'");
                * }
                */
@@ -787,32 +787,32 @@ public class GroupUrlLink
 
     if (url == null)
     {
-      System.out.println("Created NO urls.");
+      jalview.bin.Console.outPrintln("Created NO urls.");
     }
     else
     {
-      System.out.println("Created a url from " + ((int[]) url[0])[0]
+      jalview.bin.Console.outPrintln("Created a url from " + ((int[]) url[0])[0]
               + "out of " + idstring[0].length + " sequences.");
-      System.out.println("Sequences that did not match:");
+      jalview.bin.Console.outPrintln("Sequences that did not match:");
       for (int sq = 0; sq < idstring[0].length; sq++)
       {
         if (!((boolean[]) url[1])[sq])
         {
-          System.out.println("Seq " + sq + ": " + idstring[0][sq] + "\t: "
+          jalview.bin.Console.outPrintln("Seq " + sq + ": " + idstring[0][sq] + "\t: "
                   + idstring[1][sq]);
         }
       }
-      System.out.println("Sequences that DID match:");
+      jalview.bin.Console.outPrintln("Sequences that DID match:");
       for (int sq = 0; sq < idstring[0].length; sq++)
       {
         if (((boolean[]) url[1])[sq])
         {
-          System.out.println("Seq " + sq + ": " + idstring[0][sq] + "\t: "
+          jalview.bin.Console.outPrintln("Seq " + sq + ": " + idstring[0][sq] + "\t: "
                   + idstring[1][sq]);
         }
       }
-      System.out.println("The generated URL:");
-      System.out.println(((String[]) url[3])[0]);
+      jalview.bin.Console.outPrintln("The generated URL:");
+      jalview.bin.Console.outPrintln(((String[]) url[3])[0]);
     }
   }
 
@@ -849,15 +849,15 @@ public class GroupUrlLink
       GroupUrlLink ul = new GroupUrlLink(links[i]);
       if (ul.isValid())
       {
-        System.out.println("\n\n\n");
-        System.out.println(
+        jalview.bin.Console.outPrintln("\n\n\n");
+        jalview.bin.Console.outPrintln(
                 "Link " + i + " " + links[i] + " : " + ul.toString());
-        System.out.println(" pref : " + ul.getUrl_prefix());
-        System.out.println(" IdReplace : " + ul.getIDRegexReplace());
-        System.out.println(" SeqReplace : " + ul.getSeqRegexReplace());
-        System.out.println(" Suffixes : " + ul.getUrl_suffix());
+        jalview.bin.Console.outPrintln(" pref : " + ul.getUrl_prefix());
+        jalview.bin.Console.outPrintln(" IdReplace : " + ul.getIDRegexReplace());
+        jalview.bin.Console.outPrintln(" SeqReplace : " + ul.getSeqRegexReplace());
+        jalview.bin.Console.outPrintln(" Suffixes : " + ul.getUrl_suffix());
 
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "<insert input id and sequence strings here> Without onlyIfMatches:");
         Object[] urls;
         try
@@ -867,9 +867,9 @@ public class GroupUrlLink
           testUrls(ul, seqsandids, urls);
         } catch (UrlStringTooLongException ex)
         {
-          System.out.println("too long exception " + ex);
+          jalview.bin.Console.outPrintln("too long exception " + ex);
         }
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "<insert input id and sequence strings here> With onlyIfMatches set:");
         try
         {
@@ -878,12 +878,12 @@ public class GroupUrlLink
           testUrls(ul, seqsandids, urls);
         } catch (UrlStringTooLongException ex)
         {
-          System.out.println("too long exception " + ex);
+          jalview.bin.Console.outPrintln("too long exception " + ex);
         }
       }
       else
       {
-        System.err.println("Invalid URLLink : " + links[i] + " : "
+        jalview.bin.Console.errPrintln("Invalid URLLink : " + links[i] + " : "
                 + ul.getInvalidMessage());
       }
     }
index 8379777..5438d4e 100644 (file)
@@ -88,7 +88,7 @@ public class HttpUtils
   public static boolean checkUrlAvailable(URL url, int readTimeout)
           throws IOException, ProtocolException
   {
-    // System.out.println(System.currentTimeMillis() + " " + url);
+    // jalview.bin.Console.outPrintln(System.currentTimeMillis() + " " + url);
 
     HttpURLConnection connection = (HttpURLConnection) url.openConnection();
 
index 3306b0d..fa473f3 100755 (executable)
@@ -189,9 +189,9 @@ public class ImageMaker
 
     BitmapImageSizing bis = ImageMaker.getScaleWidthHeight(width, height,
             userBis);
-    float usescale = bis.scale;
-    int usewidth = bis.width;
-    int useheight = bis.height;
+    float usescale = bis.scale();
+    int usewidth = bis.width();
+    int useheight = bis.height();
 
     bi = new BufferedImage(usewidth, useheight, BufferedImage.TYPE_INT_RGB);
     graphics = bi.getGraphics();
@@ -247,14 +247,22 @@ public class ImageMaker
   }
 
   /**
-   * Takes suggested float scale, int width, int height and create a bounding
-   * box returned as a BitmapImageSizing object with consistent scale, width,
-   * height fields.
+   * Takes initial width and height, and suggested float scale, int width, int
+   * height and create a bounding box returned as a BitmapImageSizing object
+   * with consistent scale, width, height fields.
    * 
+   * @param width
+   *          The unscaled image width
+   * @param height
+   *          The unscaled image height
    * @param scale
+   *          The suggested scaling
    * @param bitmapwidth
+   *          The suggested width
    * @param bitmapheight
-   * @return BitmapImageSizing
+   *          The suggested height
+   * @return BitmapImageSizing A consistent scale,width and height for the final
+   *         image
    */
   public static BitmapImageSizing getScaleWidthHeight(int width, int height,
           float scale, int bitmapwidth, int bitmapheight)
@@ -263,6 +271,13 @@ public class ImageMaker
     int usewidth = width;
     int useheight = height;
 
+    if ((width == 0 && bitmapwidth > 0)
+            || (height == 0 && bitmapheight > 0))
+    {
+      // original image is zero sized! Avoid dividing by zero!
+      return BitmapImageSizing.nullBitmapImageSizing();
+    }
+
     // use the smallest positive scale (i.e. fit in the box)
     if (scale > 0.0f)
     {
@@ -290,7 +305,7 @@ public class ImageMaker
         useheight = bitmapheight;
       }
     }
-    return new BitmapImageSizing(usescale, usewidth, useheight);
+    return new BitmapImageSizing(usescale, usewidth, useheight, false);
   }
 
   /**
@@ -304,8 +319,8 @@ public class ImageMaker
   public static BitmapImageSizing getScaleWidthHeight(int width, int height,
           BitmapImageSizing bis)
   {
-    return ImageMaker.getScaleWidthHeight(width, height, bis.scale,
-            bis.width, bis.height);
+    return ImageMaker.getScaleWidthHeight(width, height, bis.scale(),
+            bis.width(), bis.height());
   }
 
   /**
@@ -321,6 +336,13 @@ public class ImageMaker
   public static BitmapImageSizing parseScaleWidthHeightStrings(
           String scaleS, String widthS, String heightS)
   {
+    if (scaleS == null && widthS == null && heightS == null)
+    {
+      // if all items are null (i.e. not provided) we use the dynamic
+      // preferences set BIS
+      return BitmapImageSizing.defaultBitmapImageSizing();
+    }
+
     float scale = 0.0f;
     int width = 0;
     int height = 0;
@@ -359,6 +381,6 @@ public class ImageMaker
       }
     }
 
-    return new BitmapImageSizing(scale, width, height);
+    return new BitmapImageSizing(scale, width, height, false);
   }
 }
index 5bd4a08..e4f393c 100644 (file)
@@ -29,9 +29,21 @@ import java.net.MalformedURLException;
 import java.net.URL;
 import java.util.Properties;
 
+import jalview.bin.Console;
+
 public class LaunchUtils
 {
 
+  // setting these is LaunchUtils so don't need to import Platform
+  public final static boolean isMac = System.getProperty("os.name")
+          .indexOf("Mac") > -1;
+
+  public final static boolean isWindows = System.getProperty("os.name")
+          .indexOf("Win") > -1;
+
+  private static boolean isJS = /** @j2sNative true || */
+          false;
+
   public static void loadChannelProps(File dir)
   {
     ChannelProperties.loadProps(dir);
@@ -65,7 +77,7 @@ public class LaunchUtils
         return null;
       } catch (IOException e)
       {
-        System.err.println(e.getMessage());
+        jalview.bin.Console.errPrintln(e.getMessage());
         return null;
       }
     }
@@ -81,7 +93,7 @@ public class LaunchUtils
 
   public static int getJavaCompileVersion()
   {
-    if (Platform.isJS())
+    if (LaunchUtils.isJS)
     {
       return -1;
     }
@@ -103,22 +115,22 @@ public class LaunchUtils
               null);
       if (JCV == null)
       {
-        System.out.println(
+        Console.errPrintln(
                 "Could not obtain JAVA_COMPILE_VERSION for comparison");
         return -2;
       }
       JAVA_COMPILE_VERSION = Integer.parseInt(JCV);
     } catch (MalformedURLException e)
     {
-      System.err.println("Could not find " + buildDetails);
+      jalview.bin.Console.errPrintln("Could not find " + buildDetails);
       return -3;
     } catch (IOException e)
     {
-      System.err.println("Could not load " + buildDetails);
+      jalview.bin.Console.errPrintln("Could not load " + buildDetails);
       return -4;
     } catch (NumberFormatException e)
     {
-      System.err.println("Could not parse JAVA_COMPILE_VERSION");
+      jalview.bin.Console.errPrintln("Could not parse JAVA_COMPILE_VERSION");
       return -5;
     }
 
@@ -129,7 +141,7 @@ public class LaunchUtils
 
   public static int getJavaVersion()
   {
-    if (Platform.isJS())
+    if (LaunchUtils.isJS)
     {
       return -1;
     }
@@ -142,7 +154,7 @@ public class LaunchUtils
       String JV = System.getProperty("java.version");
       if (JV == null)
       {
-        System.out.println("Could not obtain java.version for comparison");
+        Console.errPrintln("Could not obtain java.version for comparison");
         return -2;
       }
       if (JV.startsWith("1."))
@@ -153,7 +165,7 @@ public class LaunchUtils
               : Integer.parseInt(JV.substring(0, JV.indexOf(".")));
     } catch (NumberFormatException e)
     {
-      System.err.println("Could not parse java.version");
+      jalview.bin.Console.errPrintln("Could not parse java.version");
       return -3;
     }
     return JAVA_VERSION;
@@ -161,7 +173,7 @@ public class LaunchUtils
 
   public static boolean checkJavaVersion()
   {
-    if (Platform.isJS())
+    if (LaunchUtils.isJS)
     {
       return true;
     }
@@ -174,7 +186,7 @@ public class LaunchUtils
 
     if (java_compile_version <= 0 || java_version <= 0)
     {
-      System.out.println("Could not make Java version check");
+      Console.errPrintln("Could not make Java version check");
       return true;
     }
     // Warn if these java.version and JAVA_COMPILE_VERSION conditions exist
@@ -186,4 +198,88 @@ public class LaunchUtils
 
     return true;
   }
+
+  public static String findJavaBin(boolean winConsole)
+  {
+    return findJavaBin(System.getProperty("java.home"), winConsole, true);
+  }
+
+  /*
+   * Returns a string path to the most likely java binary wanted to run this
+   * installation of Jalview.
+   * 
+   * @param  winConsole  whether to use java.exe (console) in preference to javaw.exe
+   *                     (only affects Windows).
+   * @param  javaHome    Try this javaHome dir (defaults to the running java.home).
+   * @param  generic     Return a generic java command if not found.
+   */
+  public static String findJavaBin(String javaHome, boolean winConsole,
+          boolean generic)
+  {
+    String javaBin = null;
+    final String javaExe = winConsole ? "java.exe" : "javaw.exe";
+    final String java = "java";
+
+    if (javaHome != null)
+    {
+      // property "channel.app_name" is set by install4j when launching getdown
+      String propertyAppName = System.getProperty("channel.app_name");
+      final String appName = (propertyAppName != null
+              && propertyAppName.length() > 0) ? propertyAppName
+                      : ChannelProperties.getProperty("app_name");
+
+      final String javaBinDir = javaHome + File.separator + "bin"
+              + File.separator;
+
+      // appName and "Jalview" will not point to javaw.exe or java.exe but in
+      // this case that's okay because the taskbar display name problem doesn't
+      // manifest in Windows. See JAL-3820, JAL-4189.
+      for (String name : new String[] { appName, "Jalview", java, javaExe })
+      {
+        if (LaunchUtils.checkJVMSymlink(javaBinDir + name, winConsole))
+        {
+          javaBin = javaBinDir + name;
+          break;
+        }
+      }
+    }
+
+    if (javaBin == null && generic)
+    {
+      javaBin = LaunchUtils.isWindows ? javaExe : java;
+    }
+
+    return javaBin;
+  }
+
+  /*
+   * checkJVMSymlink returns true if the path in testBin *is* a java binary, or
+   * points to a java binary.
+   * @param  testBin     The binary or symbolic link to check
+   * @param  winConsole  whether we are in/want a Windows console (only relevant for Windows,
+   *                     determines whether we use java.exe or javaw.exe)
+   */
+  private static boolean checkJVMSymlink(String testBin, boolean winConsole)
+  {
+    File testBinFile = new File(testBin);
+    if (!testBinFile.exists())
+    {
+      return false;
+    }
+    File targetFile = null;
+    try
+    {
+      targetFile = testBinFile.getCanonicalFile();
+    } catch (IOException e)
+    {
+      return false;
+    }
+    final String javaExe = winConsole ? "java.exe" : "javaw.exe";
+    if (targetFile != null && ("java".equals(targetFile.getName())
+            || javaExe.equals(targetFile.getName())))
+    {
+      return true;
+    }
+    return false;
+  }
 }
index 60eef4c..de8f719 100644 (file)
@@ -96,7 +96,7 @@ public class Log4j
       init = true;
     } catch (Exception e)
     {
-      System.err.println("Problems initializing the log4j system\n");
+      jalview.bin.Console.errPrintln("Problems initializing the log4j system\n");
       e.printStackTrace(System.err);
     }
   }
index e0d9c0b..6ab053a 100644 (file)
@@ -4,14 +4,19 @@ import java.util.Map;
 
 public class MapUtils
 {
-  /*
-   * Return the value of the first key that exists in the map
+  /**
+   * Return the value of the first key that exists in the map and has a non-null
+   * value
    */
   public static <K, V> V getFirst(Map<K, V> map, K... keys)
   {
     return getFirst(false, map, keys);
   }
 
+  /**
+   * Return the value of the first key that exists in the map - optionally
+   * limiting to only returning non-null values for first extant key encountered
+   */
   public static <K, V> V getFirst(boolean nonNull, Map<K, V> map, K... keys)
   {
     for (K key : keys)
@@ -31,6 +36,15 @@ public class MapUtils
     return null;
   }
 
+  /**
+   * peeks in to the map and returns true if one of a bunch of keys is contained
+   * in it
+   * 
+   * @param <K>
+   * @param map
+   * @param keys
+   * @return
+   */
   public static <K> boolean containsAKey(Map<K, ?> map, K... keys)
   {
     for (K key : keys)
index f5953bf..4ecf637 100644 (file)
@@ -309,7 +309,7 @@ public class Platform
       time = mark = t;
       if (msg != null)
       {
-        System.err.println("Platform: timer reset\t\t\t" + msg);
+        jalview.bin.Console.errPrintln("Platform: timer reset\t\t\t" + msg);
       }
       break;
     case TIME_MARK:
@@ -325,7 +325,7 @@ public class Platform
         }
         if (msg != null)
         {
-          System.err.println("Platform: timer mark\t" + ((t - time) / 1000f)
+          jalview.bin.Console.errPrintln("Platform: timer mark\t" + ((t - time) / 1000f)
                   + "\t" + ((t - mark) / 1000f) + "\t" + msg);
         }
         mark = t;
@@ -337,7 +337,7 @@ public class Platform
     case TIME_GET:
       if (msg != null)
       {
-        System.err.println("Platform: timer dur\t" + ((t - time) / 1000f)
+        jalview.bin.Console.errPrintln("Platform: timer dur\t" + ((t - time) / 1000f)
                 + "\t" + ((duration) / 1000f) + "\t" + msg);
       }
       set = 0;
@@ -494,7 +494,7 @@ public class Platform
      *            info[key];
      */
 
-    System.out.println(
+    jalview.bin.Console.outPrintln(
             "Platform id=" + id + " reading Info." + key + " = " + value);
     p.put(id + "_" + key, value);
 
@@ -620,7 +620,7 @@ public class Platform
 
     if (isJS())
     {
-      System.out.println(
+      jalview.bin.Console.outPrintln(
               "Platform adding known access-control-allow-origin * for domain "
                       + domain);
       /**
@@ -644,11 +644,11 @@ public class Platform
        * @j2sNative var a =
        *            decodeURI((document.location.href.replace("&","?").split("?j2s")[0]
        *            + "?").split("?")[1].split("#")[0]); a &&
-       *            (System.out.println("URL arguments detected were "+a)) &&
+       *            (jalview.bin.Console.outPrintln("URL arguments detected were "+a)) &&
        *            (J2S.thisApplet.__Info.urlargs = a.split(" "));
        *            (!J2S.thisApplet.__Info.args || J2S.thisApplet.__Info.args
        *            == "" || J2S.thisApplet.__Info.args == "??") &&
-       *            (J2S.thisApplet.__Info.args = a) && (System.out.println("URL
+       *            (J2S.thisApplet.__Info.args = a) && (jalview.bin.Console.outPrintln("URL
        *            arguments were passed to J2S main."));
        */
     } catch (Throwable t)
index 7cbbe1c..89bc36d 100644 (file)
@@ -202,18 +202,18 @@ public class StringUtils
       jv.clear();
       if (DEBUG)
       {
-        System.err.println("Array from '" + delimiter
+        jalview.bin.Console.errPrintln("Array from '" + delimiter
                 + "' separated List:\n" + v.length);
         for (int i = 0; i < v.length; i++)
         {
-          System.err.println("item " + i + " '" + v[i] + "'");
+          jalview.bin.Console.errPrintln("item " + i + " '" + v[i] + "'");
         }
       }
       return v;
     }
     if (DEBUG)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Empty Array from '" + delimiter + "' separated List");
     }
     return null;
@@ -249,13 +249,13 @@ public class StringUtils
       {
         System.err
                 .println("Returning '" + separator + "' separated List:\n");
-        System.err.println(v);
+        jalview.bin.Console.errPrintln(v);
       }
       return v.toString();
     }
     if (DEBUG)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Returning empty '" + separator + "' separated List\n");
     }
     return "" + separator;
index 0141a6a..78d0b4c 100644 (file)
@@ -322,7 +322,7 @@ public class UrlLink
             // debug
             for (int s = 0; s <= rg.numSubs(); s++)
             {
-              System.err.println("Sub " + s + " : " + rg.matchedFrom(s)
+              jalview.bin.Console.errPrintln("Sub " + s + " : " + rg.matchedFrom(s)
                       + " : " + rg.matchedTo(s) + " : '"
                       + rg.stringMatched(s) + "'");
             }
index 312b834..e170f0e 100644 (file)
@@ -1,22 +1,83 @@
 package jalview.util.imagemaker;
 
+import jalview.bin.Cache;
+
 public class BitmapImageSizing
 {
-  public final float scale;
+  private final float scale;
+
+  private final int width;
 
-  public final int width;
+  private final int height;
 
-  public final int height;
+  private boolean isDefault = false;
 
-  public BitmapImageSizing(float scale, int width, int height)
+  public BitmapImageSizing(float scale, int width, int height,
+          boolean isDefault)
   {
     this.scale = scale;
     this.width = width;
     this.height = height;
+    this.isDefault = isDefault;
+  }
+
+  public boolean isNull()
+  {
+    return scale == 0.0f && width == 0 && height == 0;
   }
 
   public static BitmapImageSizing nullBitmapImageSizing()
   {
-    return new BitmapImageSizing(0.0f, 0, 0);
+    return new BitmapImageSizing(0.0f, 0, 0, false);
+  }
+
+  public static final String BITMAP_SCALE = "BITMAP_SCALE";
+
+  public static final String BITMAP_HEIGHT = "BITMAP_HEIGHT";
+
+  public static final String BITMAP_WIDTH = "BITMAP_WIDTH";
+
+  /**
+   * 
+   * @return bean configured from Cache keys
+   */
+  public static BitmapImageSizing defaultBitmapImageSizing()
+  {
+    return new BitmapImageSizing(0f, 0, 0, true);
+  }
+
+  private float defaultScale()
+  {
+    return Cache.getDefault(BITMAP_SCALE, 0f);
+  }
+
+  private int defaultWidth()
+  {
+    return Cache.getDefault(BITMAP_WIDTH, 0);
+  }
+
+  private int defaultHeight()
+  {
+    return Cache.getDefault(BITMAP_HEIGHT, 0);
+  }
+
+  public float scale()
+  {
+    return isDefault() ? defaultScale() : scale;
+  }
+
+  public int width()
+  {
+    return isDefault() ? defaultWidth() : width;
+  }
+
+  public int height()
+  {
+    return isDefault() ? defaultHeight() : height;
+  }
+
+  public boolean isDefault()
+  {
+    return isDefault;
   }
 }
index 33cb9dc..42768a6 100644 (file)
@@ -934,7 +934,7 @@ public abstract class AlignmentViewport
     }
     if (calculator.workingInvolvedWith(alignmentAnnotation))
     {
-      // System.err.println("grey out ("+alignmentAnnotation.label+")");
+      // jalview.bin.Console.errPrintln("grey out ("+alignmentAnnotation.label+")");
       return true;
     }
     return false;
@@ -1207,7 +1207,7 @@ public abstract class AlignmentViewport
   {
     if (sequenceSetID != null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Warning - overwriting a sequenceSetId for a viewport!");
     }
     sequenceSetID = new String(newid);
@@ -2100,7 +2100,7 @@ public abstract class AlignmentViewport
       {
         if (aa == null)
         {
-          System.err.println("Null annotation row: ignoring.");
+          jalview.bin.Console.errPrintln("Null annotation row: ignoring.");
           continue;
         }
         if (!aa.visible)
@@ -2293,7 +2293,7 @@ public abstract class AlignmentViewport
   {
     if (this == av)
     {
-      System.err.println("Ignoring recursive setCodingComplement request");
+      jalview.bin.Console.errPrintln("Ignoring recursive setCodingComplement request");
     }
     else
     {
index 104fb62..33c4c26 100644 (file)
@@ -224,7 +224,7 @@ public class ViewportRanges extends ViewportProperties
    */
   public void setStartEndSeq(int start, int end)
   {
-    // System.out.println("ViewportRange setStartEndSeq " + start + " " + end);
+    // jalview.bin.Console.outPrintln("ViewportRange setStartEndSeq " + start + " " + end);
     int[] oldvalues = updateStartEndSeq(start, end);
     int oldstartseq = oldvalues[0];
     int oldendseq = oldvalues[1];
@@ -438,7 +438,7 @@ public class ViewportRanges extends ViewportProperties
     {
       vpstart = visHeight - h;
     }
-    // System.out.println("ViewportRanges setviewportStartAndHeight " + vpstart
+    // jalview.bin.Console.outPrintln("ViewportRanges setviewportStartAndHeight " + vpstart
     // + " " + start + " " + h + " " + getVisibleAlignmentHeight());
 
     setStartEndSeq(vpstart, vpstart + h - 1);
index 91f2f0c..715645a 100644 (file)
  */
 package jalview.viewmodel.styles;
 
-import jalview.api.ViewStyleI;
-
 import java.awt.Color;
 
+import jalview.api.ViewStyleI;
+
 /**
  * A container for holding alignment view properties. View properties are
  * data-independent, which means they can be safely copied between views
index fc28e53..508a069 100644 (file)
@@ -145,7 +145,7 @@ public class AlignCalcManager implements AlignCalcManagerI
   {
     synchronized (inProgress)
     {
-      // System.err.println("Worker " + worker + " marked as complete.");
+      // jalview.bin.Console.errPrintln("Worker " + worker + " marked as complete.");
       inProgress.remove(worker);
       List<AlignCalcWorkerI> upd = updating.get(worker.getClass());
       if (upd != null)
@@ -192,7 +192,7 @@ public class AlignCalcManager implements AlignCalcManagerI
   public boolean isWorking(AlignCalcWorkerI worker)
   {
     synchronized (inProgress)
-    {// System.err.println("isWorking : worker "+(worker!=null ?
+    {// jalview.bin.Console.errPrintln("isWorking : worker "+(worker!=null ?
      // worker.getClass():"null")+ " "+hashCode());
       return worker != null && inProgress.contains(worker);
     }
@@ -204,7 +204,7 @@ public class AlignCalcManager implements AlignCalcManagerI
     boolean working=false;
     synchronized (inProgress)
     {
-      // System.err.println("isWorking "+hashCode());
+      // jalview.bin.Console.errPrintln("isWorking "+hashCode());
       working |= inProgress.size() > 0;
     }
     synchronized (updating)
@@ -305,14 +305,16 @@ public class AlignCalcManager implements AlignCalcManagerI
           Class<? extends AlignCalcWorkerI> workerClass)
   {
     List<AlignCalcWorkerI> workingClass = new ArrayList<AlignCalcWorkerI>();
+    AlignCalcWorkerI[] workers;
     synchronized (canUpdate)
     {
-      for (AlignCalcWorkerI worker : canUpdate)
+      workers = canUpdate.toArray(new AlignCalcWorkerI[0]);
+    }
+    for (AlignCalcWorkerI worker : workers)
+    {
+      if (workerClass.equals(worker.getClass()))
       {
-        if (workerClass.equals(worker.getClass()))
-        {
-          workingClass.add(worker);
-        }
+        workingClass.add(worker);
       }
     }
     return (workingClass.size() == 0) ? null : workingClass;
@@ -367,7 +369,7 @@ public class AlignCalcManager implements AlignCalcManagerI
      * {
      * 
      * if (isPending(worker)) { worker.abortAndDestroy(); startWorker(worker); }
-     * else { System.err.println("Pending exists for " + workerClass); } }
+     * else { jalview.bin.Console.errPrintln("Pending exists for " + workerClass); } }
      */
   }
 
index 2507bb5..8b5240c 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.workers;
 
+import java.awt.Color;
+
 import jalview.api.AlignViewportI;
 import jalview.api.AlignmentViewPanel;
 import jalview.bin.Jalview;
@@ -27,8 +29,6 @@ import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Annotation;
 import jalview.gui.AlignFrame;
 
-import java.awt.Color;
-
 /**
  * Factory class with methods which allow clients (including external scripts
  * such as Groovy) to 'register and forget' an alignment annotation calculator.
@@ -52,11 +52,11 @@ public class AlignmentAnnotationFactory
    */
   public static void newCalculator(FeatureSetCounterI counter)
   {
-    AlignmentViewPanel currentAlignFrame = Jalview
+    AlignmentViewPanel currentAlignFrame = Jalview.getInstance()
             .getCurrentAlignFrame().alignPanel;
     if (currentAlignFrame == null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Can't register calculator as no alignment window has focus");
       return;
     }
@@ -74,7 +74,8 @@ public class AlignmentAnnotationFactory
   {
     // TODO need an interface for AlignFrame by which to access
     // its AlignViewportI and AlignmentViewPanel
-    AlignFrame currentAlignFrame = Jalview.getCurrentAlignFrame();
+    AlignFrame currentAlignFrame = Jalview.getInstance()
+            .getCurrentAlignFrame();
     if (currentAlignFrame != null)
     {
       new AnnotationWorker(currentAlignFrame.getViewport(),
@@ -82,7 +83,7 @@ public class AlignmentAnnotationFactory
     }
     else
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Can't register calculator as no alignment window has focus");
     }
   }
index 1a5aaa4..8882b53 100644 (file)
@@ -58,7 +58,7 @@ public class ConsensusThread extends AlignCalcWorker
       }
       while (!calcMan.notifyWorking(this))
       {
-        // System.err.println("Thread
+        // jalview.bin.Console.errPrintln("Thread
         // (Consensus"+Thread.currentThread().getName()+") Waiting around.");
         try
         {
index 6746d1a..2e3dddd 100644 (file)
@@ -186,7 +186,7 @@ public abstract class AWSThread extends Thread
         {
           Console.debug("Interrupted sleep waiting for next job poll.", e);
         }
-        // System.out.println("I'm alive "+alTitle);
+        // jalview.bin.Console.outPrintln("I'm alive "+alTitle);
       }
     }
     if (jobComplete && jobs != null)
index d8858a9..0ebd3c3 100644 (file)
@@ -302,7 +302,7 @@ public class DBRefFetcher implements Runnable
       }
     } catch (Exception e)
     {
-      System.err.println("Couldn't locate PICR service instance.\n");
+      jalview.bin.Console.errPrintln("Couldn't locate PICR service instance.\n");
       e.printStackTrace();
     }
 
@@ -316,7 +316,7 @@ public class DBRefFetcher implements Runnable
     while (sdataset.size() > 0 && db < dbSources.length)
     {
       int maxqlen = 1; // default number of queries made at one time
-      System.out.println("Verifying against " + dbSources[db].getDbName());
+      jalview.bin.Console.outPrintln("Verifying against " + dbSources[db].getDbName());
 
       // iterate through db for each remaining un-verified sequence
       SequenceI[] currSeqs = new SequenceI[sdataset.size()];
@@ -425,7 +425,7 @@ public class DBRefFetcher implements Runnable
                             true);
                   } catch (Exception e)
                   {
-                    System.err.println(
+                    jalview.bin.Console.errPrintln(
                             "Exception with Picr for '" + token + "'\n");
                     e.printStackTrace();
                   }
@@ -438,7 +438,7 @@ public class DBRefFetcher implements Runnable
                     // present, and do a transferReferences
                     // otherwise transfer non sequence x-references directly.
                   }
-                  System.out.println(
+                  jalview.bin.Console.outPrintln(
                           "Validated ID against PICR... (for what its worth):"
                                   + token);
                   addSeqId(sequence, token);
@@ -447,7 +447,7 @@ public class DBRefFetcher implements Runnable
                 else
                 {
                   // if ()
-                  // System.out.println("Not querying source with
+                  // jalview.bin.Console.outPrintln("Not querying source with
                   // token="+token+"\n");
                   addSeqId(sequence, token);
                   queries.addElement(token.toUpperCase(Locale.ROOT));
@@ -512,7 +512,7 @@ public class DBRefFetcher implements Runnable
           DbSourceProxy dbSourceProxy, AlignmentI retrievedAl,
           boolean trimDatasetSeqs, List<String> warningMessages)
   {
-    // System.out.println("trimming ? " + trimDatasetSeqs);
+    // jalview.bin.Console.outPrintln("trimming ? " + trimDatasetSeqs);
     if (retrievedAl == null || retrievedAl.getHeight() == 0)
     {
       return false;
@@ -678,7 +678,7 @@ public class DBRefFetcher implements Runnable
           }
         }
 
-        System.out.println("Adding dbrefs to " + sequence.getName()
+        jalview.bin.Console.outPrintln("Adding dbrefs to " + sequence.getName()
                 + " from " + dbSource + " sequence : "
                 + retrievedSeq.getName());
         sequence.transferAnnotation(retrievedSeq, mp);
index 6b86775..ff6f74f 100644 (file)
@@ -153,7 +153,7 @@ public class JobStateSummary
         }
         // } catch (OutOfMemoryError e)
         // {
-        // System.err.println("Out of memory when displaying status. Squashing
+        // jalview.bin.Console.errPrintln("Out of memory when displaying status. Squashing
         // error.");
         // wsInfo.appendProgressText(j.jobnum,
         // "..\n(Out of memory when displaying status)\n");
index 518e7c6..4c22f11 100644 (file)
@@ -62,7 +62,9 @@ public class SequenceFetcher extends ASequenceFetcher
     addDBRefSourceImpl(PfamFull.class);
     addDBRefSourceImpl(PfamSeed.class);
     addDBRefSourceImpl(RfamSeed.class);
-    addDBRefSourceImpl(EBIAlfaFold.class);
+    // Technically not a database cross reference we fetch directly
+    // Useful for AlphaFold debugging
+    // addDBRefSourceImpl(EBIAlfaFold.class);
   }
 
   /**
index 9762428..3f294d0 100644 (file)
@@ -73,4 +73,6 @@ public interface MappableContactMatrixI extends ContactMatrixI
    * @return sequence position(s) corresponding to column in contact matrix
    */
   int[] getMappedPositionsFor(SequenceI localFrame, int from, int to);
+
+  ContactMatrixI getMappedMatrix();
 }
index d545741..5f27a2c 100644 (file)
@@ -7,6 +7,7 @@ import java.util.BitSet;
 import jalview.datamodel.ContactListI;
 import jalview.datamodel.ContactListImpl;
 import jalview.datamodel.ContactListProviderI;
+import jalview.datamodel.ContactMatrixI;
 import jalview.datamodel.GroupSet;
 import jalview.datamodel.GroupSetI;
 import jalview.datamodel.Mapping;
@@ -17,42 +18,77 @@ import jalview.ws.datamodel.MappableContactMatrixI;
 public abstract class MappableContactMatrix<T extends MappableContactMatrix<T>>
         implements MappableContactMatrixI
 {
-  SequenceI refSeq = null;
-
-  MapList toSeq = null;
-
   /**
-   * the length that refSeq is expected to be (excluding gaps, of course)
+   * the matrix that is being mapped to
    */
-  int length;
+  protected ContactMatrixI mappedMatrix=null;
+  
+  public ContactListI getContactList(int column)
+  {
+    return mappedMatrix.getContactList(column);
+  }
+
+  public float getMin()
+  {
+    return mappedMatrix.getMin();
+  }
+
+  public float getMax()
+  {
+    return mappedMatrix.getMax();
+  }
+
+  public int getWidth()
+  {
+    return mappedMatrix.getWidth();
+  }
+
+  public int getHeight()
+  {
+    return mappedMatrix.getHeight();
+  }
 
   @Override
-  public boolean hasReferenceSeq()
+  public ContactMatrixI getMappedMatrix()
   {
-    return (refSeq != null);
+    return mappedMatrix;
   }
+  
+  @Override
+  public GroupSetI getGroupSet()
+  {
+    return mappedMatrix.getGroupSet();
+  };
 
   @Override
-  public SequenceI getReferenceSeq()
+  public void setGroupSet(GroupSet makeGroups)
   {
-    return refSeq;
+    mappedMatrix.setGroupSet(makeGroups);
   }
+  
+  /**
+   * the sequence and how it is mapped to the matrix
+   */
+
+  SequenceI refSeq = null;
+
+  MapList toSeq = null;
 
   /**
-   * container for groups - defined on matrix columns
+   * the length that refSeq is expected to be (excluding gaps, of course)
    */
-  GroupSet grps = new GroupSet();
+  int length;
 
   @Override
-  public GroupSetI getGroupSet()
+  public boolean hasReferenceSeq()
   {
-    return grps;
-  };
+    return (refSeq != null);
+  }
 
   @Override
-  public void setGroupSet(GroupSet makeGroups)
+  public SequenceI getReferenceSeq()
   {
-    grps = makeGroups;
+    return refSeq;
   }
 
   @Override
@@ -439,7 +475,7 @@ public abstract class MappableContactMatrix<T extends MappableContactMatrix<T>>
   }
 
   /**
-   * get a specific element of the contact matrix in its data-local coordinates
+   * get a specific element of the underlying contact matrix in its data-local coordinates
    * rather than the mapped frame. Implementations are allowed to throw
    * RunTimeExceptions if _column/i are out of bounds
    * 
@@ -447,6 +483,29 @@ public abstract class MappableContactMatrix<T extends MappableContactMatrix<T>>
    * @param i
    * @return
    */
-  protected abstract double getElementAt(int _column, int i);
+  public double getElementAt(int _column, int i) {
+    return mappedMatrix.getElementAt(_column, i);
+  }
+
+  @Override
+  public int hashCode()
+  {
+    return 7 * (refSeq != null ? refSeq.hashCode() : 0)
+            + 11 * (toSeq != null ? toSeq.hashCode() : 0)
+            + 13 * (mappedMatrix != null ? mappedMatrix.hashCode() : 0)
+            + length * 3;
+  }
 
+  @Override
+  public boolean equals(Object obj)
+  {
+    if (obj == null || !(obj.getClass().equals(getClass())))
+    {
+      return false;
+    }
+    T them = (T) obj;
+    return mappedMatrix == them.mappedMatrix && length == them.length
+            && refSeq == them.refSeq && toSeq.equals(them.toSeq);
+
+  }
 }
index 22884f1..dcd2022 100644 (file)
@@ -13,6 +13,7 @@ import jalview.datamodel.ContactListI;
 import jalview.datamodel.ContactListImpl;
 import jalview.datamodel.ContactListProviderI;
 import jalview.datamodel.ContactMatrixI;
+import jalview.datamodel.FloatContactMatrix;
 import jalview.datamodel.GroupSet;
 import jalview.datamodel.SequenceDummy;
 import jalview.datamodel.SequenceI;
@@ -41,14 +42,6 @@ public class PAEContactMatrix extends
 {
 
 
-  int maxrow = 0, maxcol = 0;
-
-
-  float[][] elements;
-
-  float maxscore;
-
-
   @SuppressWarnings("unchecked")
   public PAEContactMatrix(SequenceI _refSeq, Map<String, Object> pae_obj)
           throws FileFormatException
@@ -75,26 +68,8 @@ public class PAEContactMatrix extends
    */
   public PAEContactMatrix(SequenceI _refSeq, float[][] matrix)
   {
+    mappedMatrix=new FloatContactMatrix(matrix);
     setRefSeq(_refSeq);
-    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;
-
   }
 
   /**
@@ -108,20 +83,40 @@ public class PAEContactMatrix extends
   public PAEContactMatrix(SequenceI newRefSeq, MapList newFromMapList,
           float[][] elements2, GroupSet grps2)
   {
-    this(newRefSeq, elements2);
+    this(newRefSeq, new FloatContactMatrix(elements2,grps2));
+    toSeq = newFromMapList;
+  }
+
+  public PAEContactMatrix(SequenceI _refSeq,
+          ContactMatrixI floatContactMatrix)
+  {
+    mappedMatrix = floatContactMatrix;
+    setRefSeq(_refSeq);
+  }
+  public PAEContactMatrix(SequenceI _refSeq, MapList newFromMapList,
+          ContactMatrixI floatContactMatrix)
+  {
+    mappedMatrix = floatContactMatrix;
+    setRefSeq(_refSeq);
     toSeq = newFromMapList;
-    grps = grps2;
+  }
+  
+  @Override
+  protected PAEContactMatrix newMappableContactMatrix(SequenceI newRefSeq,
+          MapList newFromMapList)
+  {
+    return new PAEContactMatrix(newRefSeq, newFromMapList, mappedMatrix);
   }
 
   /**
-   * parse a sane JSON representation of the pAE
+   * parse a sane JSON representation of the pAE and update the mappedMatrix
    * 
    * @param pae_obj
    */
   @SuppressWarnings("unchecked")
   private void parse_version_2_pAE(Map<String, Object> pae_obj)
   {
-    maxscore = -1;
+    float maxscore = -1;
     // look for a maxscore element - if there is one...
     try
     {
@@ -134,7 +129,7 @@ public class PAEContactMatrix extends
     }
     List<List<Long>> scoreRows = ((List<List<Long>>) MapUtils
             .getFirst(pae_obj, "predicted_aligned_error", "pae"));
-    elements = new float[scoreRows.size()][scoreRows.size()];
+    float[][] elements = new float[scoreRows.size()][scoreRows.size()];
     int row = 0, col = 0;
     for (List<Long> scoreRow : scoreRows)
     {
@@ -160,8 +155,7 @@ public class PAEContactMatrix extends
       row++;
       col = 0;
     }
-    maxcol = length;
-    maxrow = length;
+    mappedMatrix=new FloatContactMatrix(elements);
   }
 
   /**
@@ -178,6 +172,8 @@ public class PAEContactMatrix extends
     Iterator<Long> rows = ((List<Long>) pae_obj.get("residue1")).iterator();
     Iterator<Long> cols = ((List<Long>) pae_obj.get("residue2")).iterator();
     // two pass - to allocate the elements array
+    
+    int maxrow=-1,maxcol=-1;
     while (rows.hasNext())
     {
       int row = rows.next().intValue();
@@ -196,7 +192,7 @@ public class PAEContactMatrix extends
     cols = ((List<Long>) pae_obj.get("residue2")).iterator();
     Iterator<Double> scores = ((List<Double>) pae_obj.get("distance"))
             .iterator();
-    elements = new float[maxcol][maxrow];
+    float[][] elements = new float[maxcol][maxrow];
     while (scores.hasNext())
     {
       float escore = scores.next().floatValue();
@@ -213,68 +209,7 @@ public class PAEContactMatrix extends
       elements[col - 1][row-1] = escore;
     }
 
-    maxscore = ((Double) MapUtils.getFirst(pae_obj,
-            "max_predicted_aligned_error", "max_pae")).floatValue();
-  }
-
-  /**
-   * 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
-  protected double getElementAt(int _column, int i)
-  {
-    return elements[_column][i];
-  }
-
-  @Override
-  public float getMin()
-  {
-    return 0;
-  }
-
-  @Override
-  public float getMax()
-  {
-    return maxscore;
+    mappedMatrix=new FloatContactMatrix(elements);
   }
 
   @Override
@@ -303,17 +238,7 @@ public class PAEContactMatrix extends
     return PAEMATRIX;
   }
 
-  @Override
-  public int getWidth()
-  {
-    return maxcol;
-  }
 
-  @Override
-  public int getHeight()
-  {
-    return maxrow;
-  }
   public static void validateContactMatrixFile(String fileName)
           throws FileFormatException, IOException
   {
@@ -344,11 +269,13 @@ public class PAEContactMatrix extends
     }
   }
   @Override
-  protected PAEContactMatrix newMappableContactMatrix(SequenceI newRefSeq,
-          MapList newFromMapList)
+  public boolean equals(Object obj)
+  {
+    return super.equals(obj);
+  }
+  @Override
+  public int hashCode()
   {
-    PAEContactMatrix pae = new PAEContactMatrix(newRefSeq, newFromMapList,
-            elements, new GroupSet(grps));
-    return pae;
+    return super.hashCode();
   }
 }
index 5ab05e0..6b27488 100644 (file)
@@ -176,7 +176,7 @@ public class EBIAlfaFold extends EbiFileRetrievedProxy
 
     if (!isValidReference(id))
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "(AFClient) Ignoring invalid alphafold query: '" + id + "'");
       stopQuery();
       return null;
index 7ac6936..bef6976 100644 (file)
@@ -57,7 +57,7 @@ public abstract class EbiFileRetrievedProxy extends DbSourceProxyImpl
       }
     } catch (Exception e)
     {
-      System.err.println("Warning: problems reading temp file " + file);
+      jalview.bin.Console.errPrintln("Warning: problems reading temp file " + file);
       return null;
     }
     return bf;
index 034ea4f..a4d9633 100644 (file)
@@ -161,7 +161,7 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
       }
       else
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "No record found for '" + emprefx + ":" + query + "'");
       }
     }
@@ -283,11 +283,11 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
       }
     } catch (Exception e)
     {
-      System.err.println("EMBL Record Features parsing error!");
+      jalview.bin.Console.errPrintln("EMBL Record Features parsing error!");
       System.err
               .println("Please report the following to help@jalview.org :");
-      System.err.println("EMBL Record " + accession);
-      System.err.println("Resulted in exception: " + e.getMessage());
+      jalview.bin.Console.errPrintln("EMBL Record " + accession);
+      jalview.bin.Console.errPrintln("Resulted in exception: " + e.getMessage());
       e.printStackTrace(System.err);
     }
 
@@ -354,7 +354,7 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
             codonStart = Integer.parseInt(value.trim());
           } catch (NumberFormatException e)
           {
-            System.err.println("Invalid codon_start in XML for "
+            jalview.bin.Console.errPrintln("Invalid codon_start in XML for "
                     + entry.getAccession() + ": " + e.getMessage());
           }
         }
@@ -406,13 +406,13 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
          * workaround until we handle dna location for CDS sequence
          * e.g. location="X53828.1:60..1058" correctly
          */
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Implementation Notice: EMBLCDS records not properly supported yet - Making up the CDNA region of this sequence... may be incorrect ("
                         + sourceDb + ":" + entry.getAccession() + ")");
         int dnaLength = dna.getLength();
         if (translationLength * 3 == (1 - codonStart + dnaLength))
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Not allowing for additional stop codon at end of cDNA fragment... !");
           // this might occur for CDS sequences where no features are marked
           exons = new int[] { dna.getStart() + (codonStart - 1),
@@ -423,7 +423,7 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
         }
         if ((translationLength + 1) * 3 == (1 - codonStart + dnaLength))
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Allowing for additional stop codon at end of cDNA fragment... will probably cause an error in VAMSAs!");
           exons = new int[] { dna.getStart() + (codonStart - 1),
               dna.getEnd() - 3 };
index bb5c165..68a7328 100644 (file)
@@ -138,7 +138,7 @@ public class Pdb extends EbiFileRetrievedProxy
 
     if (!isValidReference(id))
     {
-      System.err.println("Ignoring invalid pdb query: '" + id + "'");
+      jalview.bin.Console.errPrintln("Ignoring invalid pdb query: '" + id + "'");
       stopQuery();
       return null;
     }
index 65b9655..3eef460 100644 (file)
@@ -136,8 +136,8 @@ public class EBIFetchClient
     String database = parseIds(ids, querystring);
     if (database == null)
     {
-      System.err.println("Invalid Query string : '" + ids + "'");
-      System.err.println("Should be of form 'dbname:q1;q2;q3;q4'");
+      jalview.bin.Console.errPrintln("Invalid Query string : '" + ids + "'");
+      jalview.bin.Console.errPrintln("Should be of form 'dbname:q1;q2;q3;q4'");
       return null;
     }
 
@@ -227,11 +227,11 @@ public class EBIFetchClient
         }
         return (String[]) arl.toArray();
       }
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Warning: response code " + responseCode + " for " + url);
     } catch (OutOfMemoryError er)
     {
-      System.out.println("OUT OF MEMORY DOWNLOADING QUERY FROM " + database
+      jalview.bin.Console.outPrintln("OUT OF MEMORY DOWNLOADING QUERY FROM " + database
               + ":\n" + ids);
       throw er;
     } catch (Exception ex)
@@ -239,7 +239,7 @@ public class EBIFetchClient
       if (!ex.getMessage().startsWith(
               "uk.ac.ebi.jdbfetch.exceptions.DbfNoEntryFoundException"))
       {
-        System.err.println("Unexpected exception when retrieving from "
+        jalview.bin.Console.errPrintln("Unexpected exception when retrieving from "
                 + database + "\nQuery was : '" + ids + "'");
         ex.printStackTrace(System.err);
       }
index 022ae6d..4165eae 100644 (file)
@@ -44,7 +44,7 @@ public class Annotate3D
 
   public Annotate3D()
   {
-    System.out.println("Annotate3D");
+    jalview.bin.Console.outPrintln("Annotate3D");
     // try {
     // Create a URL for the desired page
     // String id = "1HR2";
@@ -55,7 +55,7 @@ public class Annotate3D
     // OutputStream out1 = null;
     // out = new BufferedWriter(new OutputStreamWriter(out1, "temp.rnaml"));
     // while ((str = in.readLine()) != null) {
-    // System.out.println(str);
+    // jalview.bin.Console.outPrintln(str);
     // out.write(str);
     // }
     // in.close();
@@ -117,19 +117,19 @@ public class Annotate3D
 
   public Annotate3D(String path) throws InterruptedException
   {
-    System.out.println("Annotate3D");
+    jalview.bin.Console.outPrintln("Annotate3D");
     try
     {
       // //URL url = new
       // URL("http://paradise-ibmc.u-strasbg.fr/webservices/annotate3d?data="+inFile);
-      // System.out.println("Step1");
+      // jalview.bin.Console.outPrintln("Step1");
       // FileReader r = new FileReader(inFile);
       // BufferedReader in = new BufferedReader(r);
       // StringBuffer content = new StringBuffer();
-      // System.out.println("Step2");
+      // jalview.bin.Console.outPrintln("Step2");
       // while(in.readLine()!=null){
       // content.append(in.readLine());
-      // //System.out.println("Step3"+in.readLine());
+      // //jalview.bin.Console.outPrintln("Step3"+in.readLine());
       // }
       //
       // String data = URLEncoder.encode("data", "UTF-8") + "=" +
@@ -145,21 +145,21 @@ public class Annotate3D
       // FileReader r = new FileReader(path);
       // BufferedReader in = new BufferedReader(r);
       // StringBuffer content = new StringBuffer();
-      // System.out.println("Step1");
+      // jalview.bin.Console.outPrintln("Step1");
       // while(in.readLine()!=null){
       // content.append(in.readLine());
       //
       // }
-      // System.out.println("Step2");
+      // jalview.bin.Console.outPrintln("Step2");
       // String data = URLEncoder.encode("data", "UTF-8") + "=" +
       // URLEncoder.encode(content.toString(), "UTF-8");
-      // System.out.println("Step2");
+      // jalview.bin.Console.outPrintln("Step2");
       // URL url = new
       // URL("http://paradise-ibmc.u-strasbg.fr/webservices/annotate3d?data="+data);
       // DataInputStream is = new DataInputStream(url.openStream());
       // String str;
       // while ((str = is.readLine()) != null) {
-      // System.out.println(str);
+      // jalview.bin.Console.outPrintln(str);
       // //out.write(str);
       // }
       FileReader r = new FileReader(path);
@@ -169,14 +169,14 @@ public class Annotate3D
 
       while ((str = in.readLine()) != null)
       {
-        // System.out.println(str);
+        // jalview.bin.Console.outPrintln(str);
 
         content = content + str;
       }
-      System.out.println("pdbfile=" + content.toString());
-      System.out.println("capacité=" + content.length());
+      jalview.bin.Console.outPrintln("pdbfile=" + content.toString());
+      jalview.bin.Console.outPrintln("capacité=" + content.length());
       String paramfile = URLEncoder.encode(content.toString(), "UTF-8");
-      System.out.println("param=" + paramfile);
+      jalview.bin.Console.outPrintln("param=" + paramfile);
       URL url = new URL(
               "http://paradise-ibmc.u-strasbg.fr/webservices/annotate3d?data="
                       + content);
@@ -185,7 +185,7 @@ public class Annotate3D
       String str4;
       while ((str4 = is.readLine()) != null)
       {
-        System.out.println(str4);
+        jalview.bin.Console.outPrintln(str4);
         // out.write(str);
       }
       in.close();
@@ -207,7 +207,7 @@ public class Annotate3D
       // BufferedReader in1 = new BufferedReader(is);
 
       // OutputStream out1 = null;
-      // System.out.println("Step3");
+      // jalview.bin.Console.outPrintln("Step3");
       // BufferedWriter out = new BufferedWriter(new OutputStreamWriter(out1,
       // "temp.rnaml"));
       //
@@ -216,11 +216,11 @@ public class Annotate3D
 
       // return;
 
-      // System.out.println(data.length());
-      // System.out.println("step2");
+      // jalview.bin.Console.outPrintln(data.length());
+      // jalview.bin.Console.outPrintln("step2");
       // URL url = new
       // URL("http://paradise-ibmc.u-strasbg.fr/webservices/annotate3d?data="+data);
-      // System.out.println("step3");
+      // jalview.bin.Console.outPrintln("step3");
       // URLConnection conn = url.openConnection();
       // conn.setDoOutput(true);
       // OutputStreamWriter writer = new
@@ -237,7 +237,7 @@ public class Annotate3D
       // //String line;
       // while ((line = reader.readLine()) != null) {
       // answer.append(line);
-      // System.out.println(line);
+      // jalview.bin.Console.outPrintln(line);
       // }
       // writer.close();
       // reader.close();
@@ -261,9 +261,9 @@ public class Annotate3D
   // out = new BufferedWriter(new FileWriter("temp.rnaml"));
 
   // while ((str = in.readLine()) != null) {
-  // System.out.println(str);
+  // jalview.bin.Console.outPrintln(str);
   // out.write(str);
-  // System.out.println(str);
+  // jalview.bin.Console.outPrintln(str);
   // in.close();
 
   // out.close();
@@ -275,7 +275,7 @@ public class Annotate3D
 
   // public BufferedWriter getReader()
   // {
-  // System.out.println("The buffer");
+  // jalview.bin.Console.outPrintln("The buffer");
 
   // return out;
 
index 69e47a3..d4a2fd4 100644 (file)
@@ -222,7 +222,7 @@ public class Discoverer implements Runnable
 
     } catch (Exception e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "jalview.rootRegistry is not a proper url!\nWas set to "
                       + RootServiceURL + "\n" + e);
     }
@@ -404,7 +404,7 @@ public class Discoverer implements Runnable
     WS1Client instance = serviceClientBindings.get(sh.getAbstractName());
     if (instance == null)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "WARNING - POSSIBLE IMPLEMENTATION ERROR - cannot find WSClient implementation for "
                       + sh.getAbstractName());
     }
index a39945e..a042dee 100644 (file)
@@ -480,7 +480,7 @@ class JPredThread extends JWS1Thread implements WSClientI
         wsInfo.setProgressText(j.getJobnum(),
                 "Failed to submit the prediction. (Just close the window)\n"
                         + "It is most likely that there is a problem with the server.\n");
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "JPredWS Client: Failed to submit the prediction. Quite possibly because of a server error - see below)\n"
                         + e.getMessage() + "\n");
 
index e027038..727f5be 100644 (file)
@@ -479,7 +479,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
         j.setJobId(jobsubmit.getJobId());
         j.setSubmitted(true);
         j.setSubjobComplete(false);
-        // System.out.println(WsURL + " Job Id '" + jobId + "'");
+        // jalview.bin.Console.outPrintln(WsURL + " Job Id '" + jobId + "'");
       }
       else
       {
@@ -497,7 +497,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
     {
       // TODO: JBPNote catch timeout or other fault types explicitly
       // For unexpected errors
-      System.err.println(WebServiceName
+      jalview.bin.Console.errPrintln(WebServiceName
               + "Client: Failed to submit the sequences for alignment (probably a server side problem)\n"
               + "When contacting Server:" + WsUrl + "\n" + e.toString()
               + "\n");
@@ -544,9 +544,9 @@ class MsaWSThread extends JWS1Thread implements WSClientI
           results++;
           // if (Cache.isDebugEnabled())
           // {
-          // System.out.println("Job lob for job
+          // jalview.bin.Console.outPrintln("Job lob for job
           // "+jobs[j].getJobId()+":"+jobs[j].getJobnum());
-          // System.out.println(jobs[j].getStatus());
+          // jalview.bin.Console.outPrintln(jobs[j].getStatus());
           // }
 
           vamsas.objects.simple.Alignment valign = ((MsaResult) ((MsaWSJob) jobs[j]).result)
@@ -709,7 +709,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
     }
     else
     {
-      System.out.println("MERGE WITH OLD FRAME");
+      jalview.bin.Console.outPrintln("MERGE WITH OLD FRAME");
       // TODO: modify alignment in original frame, replacing old for new
       // alignment using the commands.EditCommand model to ensure the update can
       // be undone
index 0f28230..805f64c 100644 (file)
@@ -212,9 +212,9 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
           }
         } catch (Exception e)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Failed to parse the annotation file associated with the alignment.");
-          System.err.println(">>>EOF" + inFile + "\n<<<EOF\n");
+          jalview.bin.Console.errPrintln(">>>EOF" + inFile + "\n<<<EOF\n");
           e.printStackTrace(System.err);
         }
 
@@ -229,9 +229,9 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
           }
         } catch (Exception e)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Failed to parse the Features file associated with the alignment.");
-          System.err.println(">>>EOF" + inFile + "\n<<<EOF\n");
+          jalview.bin.Console.errPrintln(">>>EOF" + inFile + "\n<<<EOF\n");
           e.printStackTrace(System.err);
         }
         jalview.io.NewickFile nf = null;
@@ -250,9 +250,9 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
           }
         } catch (Exception e)
         {
-          System.err.println(
+          jalview.bin.Console.errPrintln(
                   "Failed to parse the treeFile associated with the alignment.");
-          System.err.println(">>>EOF" + inFile + "\n<<<EOF\n");
+          jalview.bin.Console.errPrintln(">>>EOF" + inFile + "\n<<<EOF\n");
           e.printStackTrace(System.err);
         }
 
@@ -496,7 +496,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
         j.setJobId(jobsubmit.getJobId());
         j.setSubmitted(true);
         j.setSubjobComplete(false);
-        // System.out.println(WsURL + " Job Id '" + jobId + "'");
+        // jalview.bin.Console.outPrintln(WsURL + " Job Id '" + jobId + "'");
       }
       else
       {
@@ -514,7 +514,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
     {
       // TODO: JBPNote catch timeout or other fault types explicitly
       // For unexpected errors
-      System.err.println(WebServiceName
+      jalview.bin.Console.errPrintln(WebServiceName
               + "Client: Failed to submit the sequences for alignment (probably a server side problem)\n"
               + "When contacting Server:" + WsUrl + "\n" + e.toString()
               + "\n");
@@ -616,7 +616,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
   {
     if (!newFrame)
     {
-      System.err.println("MERGE WITH OLD FRAME NOT IMPLEMENTED");
+      jalview.bin.Console.errPrintln("MERGE WITH OLD FRAME NOT IMPLEMENTED");
       return;
     }
     // each subjob is an independent alignment for the moment
index 9d56de4..3b56a70 100644 (file)
@@ -259,11 +259,11 @@ public abstract class AbstractJabaCalcWorker extends AlignCalcWorker
           {
             if (cancelJob(rslt))
             {
-              System.err.println("Cancelled AACon job: " + rslt);
+              jalview.bin.Console.errPrintln("Cancelled AACon job: " + rslt);
             }
             else
             {
-              System.err.println("FAILED TO CANCEL AACon job: " + rslt);
+              jalview.bin.Console.errPrintln("FAILED TO CANCEL AACon job: " + rslt);
             }
 
           } catch (Exception x)
@@ -356,13 +356,13 @@ public abstract class AbstractJabaCalcWorker extends AlignCalcWorker
     catch (JobSubmissionException x)
     {
 
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "submission error with " + getServiceActionText() + " :");
       x.printStackTrace();
       calcMan.disableWorker(this);
     } catch (ResultNotAvailableException x)
     {
-      System.err.println("collection error:\nJob ID: " + rslt);
+      jalview.bin.Console.errPrintln("collection error:\nJob ID: " + rslt);
       x.printStackTrace();
       calcMan.disableWorker(this);
 
@@ -441,11 +441,11 @@ public abstract class AbstractJabaCalcWorker extends AlignCalcWorker
       String id = rslt;
       if (cancelJob(rslt))
       {
-        System.err.println("Cancelled job " + id);
+        jalview.bin.Console.errPrintln("Cancelled job " + id);
       }
       else
       {
-        System.err.println("Job " + id + " couldn't be cancelled.");
+        jalview.bin.Console.errPrintln("Job " + id + " couldn't be cancelled.");
       }
     } catch (Exception q)
     {
index 5e034cd..5b46a97 100644 (file)
@@ -84,7 +84,7 @@ public class JabaParamStore implements ParamDatastoreI
           }
           else
           {
-            System.err.println(
+            jalview.bin.Console.errPrintln(
                     "Warning: Ignoring parameter set instance of type "
                             + paramset.getClass()
                             + " : Bound but not applicable for service at "
index 5831df8..e4d0669 100644 (file)
@@ -117,7 +117,7 @@ public class JabaWsServerQuery implements Runnable
           registry = Jws2Client.connectToRegistry(jwsserver);
           if (registry != null)
           {
-            // System.err.println("Test Services Output\n"
+            // jalview.bin.Console.errPrintln("Test Services Output\n"
             // + registry.testAllServices());
             // TODO: enumerate services and test those that haven't been tested
             // in the last n-days/hours/etc.
@@ -126,23 +126,23 @@ public class JabaWsServerQuery implements Runnable
             srv_set = registry.getSupportedServices();
 
             // dan test
-            System.out.println(
+            jalview.bin.Console.outPrintln(
                     "registry.getSupportedServices: " + srv_set.toString());
 
             svccategories = registry.getServiceCategories();
 
             // dan test
-            // System.out.println("registry.getServiceCategories: " +
+            // jalview.bin.Console.outPrintln("registry.getServiceCategories: " +
             // svccategories.toString());
 
           }
         } catch (Exception ex)
         {
-          System.err.println("Exception whilst trying to get at registry:");
+          jalview.bin.Console.errPrintln("Exception whilst trying to get at registry:");
           ex.printStackTrace();
           // if that failed, then we are probably working with a JABAWS1 server.
           // in that case, look for each service endpoint
-          System.err.println("JWS2 Discoverer: " + jwsserver
+          jalview.bin.Console.errPrintln("JWS2 Discoverer: " + jwsserver
                   + " is a JABAWS1 server. Using hardwired list.");
           for (Services srv : JABAWS1SERVERS)
           {
@@ -169,7 +169,7 @@ public class JabaWsServerQuery implements Runnable
               service = Jws2Client.connect(jwsserver, srv);
             } catch (Exception e)
             {
-              System.err.println("Jws2 Discoverer: Problem on " + jwsserver
+              jalview.bin.Console.errPrintln("Jws2 Discoverer: Problem on " + jwsserver
                       + " with service " + srv + ":\n" + e.getMessage());
               if (!(e instanceof javax.xml.ws.WebServiceException))
               {
@@ -245,11 +245,11 @@ public class JabaWsServerQuery implements Runnable
         result = true;
       } catch (MalformedURLException e)
       {
-        System.err.println("Invalid server URL: " + server);
+        jalview.bin.Console.errPrintln("Invalid server URL: " + server);
         result = false;
       } catch (IOException e)
       {
-        System.err.println("Error connecting to server: " + server + ": "
+        jalview.bin.Console.errPrintln("Error connecting to server: " + server + ": "
                 + e.toString());
         result = false;
       }
index fc36205..47e82de 100644 (file)
@@ -142,7 +142,7 @@ public abstract class JabawsCalcWorker extends AbstractJabaCalcWorker
           List<AlignmentAnnotation> ourAnnot, String typeName,
           String calcId, SequenceI dseq, int base, Score scr)
   {
-    System.out.println("Creating annotation on dseq:" + dseq.getStart()
+    jalview.bin.Console.outPrintln("Creating annotation on dseq:" + dseq.getStart()
             + " base is " + base + " and length=" + dseq.getLength()
             + " == " + scr.getScores().size());
     // AlignmentAnnotation annotation = new AlignmentAnnotation(
index ee36d4a..13d60de 100644 (file)
@@ -156,7 +156,7 @@ public abstract class JabawsMsaInterfaceAlignCalcWorker
           List<AlignmentAnnotation> ourAnnot, String typeName,
           String calcId, SequenceI dseq, int base, Score scr)
   {
-    System.out.println("Creating annotation on dseq:" + dseq.getStart()
+    jalview.bin.Console.outPrintln("Creating annotation on dseq:" + dseq.getStart()
             + " base is " + base + " and length=" + dseq.getLength()
             + " == " + scr.getScores().size());
     // AlignmentAnnotation annotation = new AlignmentAnnotation(
index b6b4b2e..ca36a51 100644 (file)
@@ -195,7 +195,7 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
               .loadClass("compbio.ws.client.Jws2Client");
     } catch (ClassNotFoundException e)
     {
-      System.err.println(
+      jalview.bin.Console.errPrintln(
               "Not enabling JABA Webservices : client jar is not available."
                       + "\nPlease check that your webstart JNLP file is up to date!");
       running = false;
@@ -314,7 +314,7 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
     {
       services = new Vector<>();
     }
-    System.out.println(
+    jalview.bin.Console.outPrintln(
             "Discovered service: " + jwsservers + " " + service.toString());
     // Jws2Instance service = new Jws2Instance(jwsservers, srv.toString(),
     // service2);
@@ -600,12 +600,12 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
               {
                 if (getDiscoverer().services != null)
                 {
-                  System.out.println("Changesupport: There are now "
+                  jalview.bin.Console.outPrintln("Changesupport: There are now "
                           + getDiscoverer().services.size() + " services");
                   int i = 1;
                   for (Jws2Instance instance : getDiscoverer().services)
                   {
-                    System.out.println("Service " + i++ + " "
+                    jalview.bin.Console.outPrintln("Service " + i++ + " "
                             + instance.getClass() + "@" + instance.getHost()
                             + ": " + instance.getActionText());
                   }
index ee0fbc5..611aa79 100644 (file)
@@ -703,7 +703,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
       {
         j.setSubmitted(true);
         j.setSubjobComplete(false);
-        // System.out.println(WsURL + " Job Id '" + jobId + "'");
+        // jalview.bin.Console.outPrintln(WsURL + " Job Id '" + jobId + "'");
         return;
       }
       else
@@ -749,7 +749,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
     } catch (Error e)
     {
       // For unexpected errors
-      System.err.println(WebServiceName
+      jalview.bin.Console.errPrintln(WebServiceName
               + "Client: Failed to submit the sequences for alignment (probably a server side problem)\n"
               + "When contacting Server:" + WsUrl + "\n");
       e.printStackTrace(System.err);
@@ -759,7 +759,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
     } catch (Exception e)
     {
       // For unexpected errors
-      System.err.println(WebServiceName
+      jalview.bin.Console.errPrintln(WebServiceName
               + "Client: Failed to submit the sequences for alignment (probably a server side problem)\n"
               + "When contacting Server:" + WsUrl + "\n");
       e.printStackTrace(System.err);
@@ -837,10 +837,10 @@ class MsaWSThread extends AWS2Thread implements WSClientI
 
           if (Console.isDebugEnabled())
           {
-            System.out.println("Job Execution file for job: "
+            jalview.bin.Console.outPrintln("Job Execution file for job: "
                     + msjob.getJobId() + " on server " + WsUrl);
-            System.out.println(msjob.getStatus());
-            System.out.println("*** End of status");
+            jalview.bin.Console.outPrintln(msjob.getStatus());
+            jalview.bin.Console.outPrintln("*** End of status");
 
           }
           try
@@ -986,7 +986,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
     else
     {
       // TODO 2.9.x feature
-      System.out.println("MERGE WITH OLD FRAME");
+      jalview.bin.Console.outPrintln("MERGE WITH OLD FRAME");
       // TODO: modify alignment in original frame, replacing old for new
       // alignment using the commands.EditCommand model to ensure the update can
       // be undone
index c7fad05..0fb36ad 100644 (file)
@@ -79,7 +79,7 @@ public class ParameterUtils
       Option o = options.getArgumentByOptionName(oname);
       if (o == null)
       {
-        System.out.println("WARN ignoring unsuppoted parameter: " + oname);
+        jalview.bin.Console.outPrintln("WARN ignoring unsuppoted parameter: " + oname);
         continue;
       }
       if (o instanceof Parameter)
@@ -98,7 +98,7 @@ public class ParameterUtils
                   : param);
         } catch (WrongParameterException e)
         {
-          System.out.println(
+          jalview.bin.Console.outPrintln(
                   "Problem setting value for the parameter: " + param);
           e.printStackTrace();
         }
index e092192..9e49ce7 100644 (file)
@@ -114,7 +114,7 @@ public class Jws2Instance implements AutoCloseable
         }
       } catch (Exception ex)
       {
-        System.err.println("Exception when retrieving presets for service "
+        jalview.bin.Console.errPrintln("Exception when retrieving presets for service "
                 + serviceType + " at " + hosturl);
       }
     }
@@ -128,7 +128,7 @@ public class Jws2Instance implements AutoCloseable
      * try { URL serviceurl = new URL(hosturl); if (serviceurl.getPort()!=80) {
      * return serviceurl.getHost()+":"+serviceurl.getPort(); } return
      * serviceurl.getHost(); } catch (Exception e) {
-     * System.err.println("Failed to parse service URL '" + hosturl +
+     * jalview.bin.Console.errPrintln("Failed to parse service URL '" + hosturl +
      * "' as a valid URL!"); } return null;
      */
   }
@@ -190,7 +190,7 @@ public class Jws2Instance implements AutoCloseable
                         : null));
       } catch (Exception ex)
       {
-        System.err.println("Unexpected exception creating JabaParamStore.");
+        jalview.bin.Console.errPrintln("Unexpected exception creating JabaParamStore.");
         ex.printStackTrace();
       }
 
index fb291da..6ac720a 100644 (file)
@@ -142,7 +142,7 @@ public abstract class InputType
       }
     } catch (Exception ex)
     {
-      System.err.println("Couldn't transform string\n" + content
+      jalview.bin.Console.errPrintln("Couldn't transform string\n" + content
               + "\nException was :");
       ex.printStackTrace(System.err);
     }
index 255ab58..450f1b4 100644 (file)
@@ -134,7 +134,7 @@ public class RestClient extends WSClient
   @Override
   public void cancelJob()
   {
-    System.err.println("Cannot cancel this job type: " + service);
+    jalview.bin.Console.errPrintln("Cannot cancel this job type: " + service);
   }
 
   @Override
@@ -418,7 +418,7 @@ public class RestClient extends WSClient
         }
       } catch (Exception ex)
       {
-        System.err.println(
+        jalview.bin.Console.errPrintln(
                 "Serious - RSBS descriptions in user preferences are corrupt!");
         ex.printStackTrace();
       }
index eff38fb..c8efcda 100644 (file)
@@ -422,7 +422,7 @@ public class RestJobThread extends AWSThread
   public void pollJob(AWsJob job) throws Exception
   {
     assert (job instanceof RestJob);
-    System.err.println("Debug RestJob: Polling Job");
+    jalview.bin.Console.errPrintln("Debug RestJob: Polling Job");
     doPoll((RestJob) job);
   }
 
@@ -432,7 +432,7 @@ public class RestJobThread extends AWSThread
     assert (job instanceof RestJob);
     try
     {
-      System.err.println("Debug RestJob: Posting Job");
+      jalview.bin.Console.errPrintln("Debug RestJob: Posting Job");
       doPost((RestJob) job);
     } catch (NoValidInputDataException erex)
     {
@@ -1258,7 +1258,7 @@ public class RestJobThread extends AWSThread
         if (!rj.hasValidInput())
         {
           // invalid input for this job
-          System.err.println("Job " + rj.getJobnum()
+          jalview.bin.Console.errPrintln("Job " + rj.getJobnum()
                   + " has invalid input. ( " + rj.getStatus() + ")");
           if (rj.hasStatus() && !_warnings.contains(rj.getStatus()))
           {
index 0d0a314..374147a 100644 (file)
@@ -191,9 +191,9 @@ public class ASequenceFetcher
               seqset = fetcher.getSequenceRecords(qsb.toString());
             } catch (Exception ex)
             {
-              System.err.println(
+              jalview.bin.Console.errPrintln(
                       "Failed to retrieve the following from " + db);
-              System.err.println(qsb);
+              jalview.bin.Console.errPrintln(qsb);
               ex.printStackTrace(System.err);
             }
             // TODO: Merge alignment together - perhaps
@@ -222,7 +222,7 @@ public class ASequenceFetcher
               {
                 if (fetcher.getRawRecords() != null)
                 {
-                  System.out.println(
+                  jalview.bin.Console.outPrintln(
                           "# Retrieved from " + db + ":" + qsb.toString());
                   StringBuffer rrb = fetcher.getRawRecords();
                   /*
@@ -235,12 +235,12 @@ public class ASequenceFetcher
                   /*
                    * } else { hdr = "# part "+rr; }
                    */
-                  System.out.println(hdr);
+                  jalview.bin.Console.outPrintln(hdr);
                   if (rrb != null)
                   {
-                    System.out.println(rrb);
+                    jalview.bin.Console.outPrintln(rrb);
                   }
-                  System.out.println("# end of " + hdr);
+                  jalview.bin.Console.outPrintln("# end of " + hdr);
                 }
 
               }
@@ -253,7 +253,7 @@ public class ASequenceFetcher
         }
         if (queriesMade.size() > 0)
         {
-          System.out.println("# Adding " + queriesMade.size()
+          jalview.bin.Console.outPrintln("# Adding " + queriesMade.size()
                   + " ids back to queries list for searching again (" + db
                   + ")");
           queriesLeft.addAll(queriesMade);
@@ -279,7 +279,7 @@ public class ASequenceFetcher
           Exception ex)
   {
 
-    System.err.println(
+    jalview.bin.Console.errPrintln(
             "Failed to retrieve the following references from " + db);
     int n = 0;
     for (String qv : queriesMade)
@@ -287,11 +287,11 @@ public class ASequenceFetcher
       System.err.print(" " + qv + ";");
       if (n++ > 10)
       {
-        System.err.println();
+        jalview.bin.Console.errPrintln();
         n = 0;
       }
     }
-    System.err.println();
+    jalview.bin.Console.errPrintln();
     ex.printStackTrace();
   }
 
index 24526cf..92cb7af 100644 (file)
@@ -189,7 +189,7 @@ public class SiftsClient implements SiftsClientI
     try (InputStream in = new FileInputStream(siftFile);
             GZIPInputStream gzis = new GZIPInputStream(in);)
     {
-      // System.out.println("File : " + siftFile.getAbsolutePath());
+      // jalview.bin.Console.outPrintln("File : " + siftFile.getAbsolutePath());
       JAXBContext jc = JAXBContext.newInstance("jalview.xml.binding.sifts");
       XMLStreamReader streamReader = XMLInputFactory.newInstance()
               .createXMLStreamReader(gzis);
@@ -227,7 +227,7 @@ public class SiftsClient implements SiftsClientI
     if (siftsFile.exists())
     {
       // The line below is required for unit testing... don't comment it out!!!
-      System.out.println(">>> SIFTS File already downloaded for " + pdbId);
+      jalview.bin.Console.outPrintln(">>> SIFTS File already downloaded for " + pdbId);
 
       if (isFileOlderThanThreshold(siftsFile,
               SiftsSettings.getCacheThresholdInDays()))
@@ -282,7 +282,7 @@ public class SiftsClient implements SiftsClientI
       diffInDays = (int) ((new Date().getTime()
               - attr.lastModifiedTime().toMillis())
               / (1000 * 60 * 60 * 24));
-      // System.out.println("Diff in days : " + diffInDays);
+      // jalview.bin.Console.outPrintln("Diff in days : " + diffInDays);
     } catch (IOException e)
     {
       e.printStackTrace();
@@ -330,7 +330,7 @@ public class SiftsClient implements SiftsClientI
       }
     }
 
-    // System.out.println(">> Download ftp url : " + siftsFileFTPURL);
+    // jalview.bin.Console.outPrintln(">> Download ftp url : " + siftsFileFTPURL);
     // long now = System.currentTimeMillis();
     URL url = new URL(siftsFileFTPURL);
     URLConnection conn = url.openConnection();
@@ -344,7 +344,7 @@ public class SiftsClient implements SiftsClientI
     }
     outputStream.close();
     inputStream.close();
-    // System.out.println(">>> File downloaded : " + downloadedSiftsFile
+    // jalview.bin.Console.outPrintln(">>> File downloaded : " + downloadedSiftsFile
     // + " took " + (System.currentTimeMillis() - now) + "ms");
     return downloadTo;
   }
@@ -459,7 +459,7 @@ public class SiftsClient implements SiftsClientI
       seq = seq.getDatasetSequence();
     }
     structId = (chain == null) ? pdbId : pdbId + "|" + chain;
-    System.out.println("Getting SIFTS mapping for " + structId + ": seq "
+    jalview.bin.Console.outPrintln("Getting SIFTS mapping for " + structId + ": seq "
             + seq.getName());
 
     final StringBuilder mappingDetails = new StringBuilder(128);
@@ -492,7 +492,7 @@ public class SiftsClient implements SiftsClientI
   {
     List<Integer> omitNonObserved = new ArrayList<>();
     int nonObservedShiftIndex = 0, pdbeNonObserved = 0;
-    // System.out.println("Generating mappings for : " + entityId);
+    // jalview.bin.Console.outPrintln("Generating mappings for : " + entityId);
     Entity entity = null;
     entity = getEntityById(entityId);
     String originalSeq = AlignSeq.extractGaps(
@@ -662,7 +662,7 @@ public class SiftsClient implements SiftsClientI
     int firstPDBResNum = UNASSIGNED;
     for (Segment segment : segments)
     {
-      // System.out.println("Mapping segments : " + segment.getSegId() + "\\"s
+      // jalview.bin.Console.outPrintln("Mapping segments : " + segment.getSegId() + "\\"s
       // + segStartEnd);
       List<Residue> residues = segment.getListResidue().getResidue();
       for (Residue residue : residues)
@@ -931,8 +931,8 @@ public class SiftsClient implements SiftsClientI
     // Arrays.sort(keys);
     int firstIndex = keys[0];
     int lastIndex = keys[keys.length - 1];
-    // System.out.println("Min value " + firstIndex);
-    // System.out.println("Max value " + lastIndex);
+    // jalview.bin.Console.outPrintln("Min value " + firstIndex);
+    // jalview.bin.Console.outPrintln("Max value " + lastIndex);
     for (int x = firstIndex; x <= lastIndex; x++)
     {
       if (!resNumMap.containsKey(x) && !omitNonObserved.contains(x))
@@ -965,7 +965,7 @@ public class SiftsClient implements SiftsClientI
    */
   public Entity getEntityByMostOptimalMatchedId(String chainId)
   {
-    // System.out.println("---> advanced greedy entityId matching block
+    // jalview.bin.Console.outPrintln("---> advanced greedy entityId matching block
     // entered..");
     List<Entity> entities = siftsEntry.getEntity();
     SiftsEntitySortPojo[] sPojo = new SiftsEntitySortPojo[entities.size()];
@@ -1001,8 +1001,8 @@ public class SiftsClient implements SiftsClientI
       ++count;
     }
     Arrays.sort(sPojo, Collections.reverseOrder());
-    // System.out.println("highest matched entity : " + sPojo[0].entityId);
-    // System.out.println("highest matched pid : " + sPojo[0].pid);
+    // jalview.bin.Console.outPrintln("highest matched entity : " + sPojo[0].entityId);
+    // jalview.bin.Console.outPrintln("highest matched pid : " + sPojo[0].pid);
 
     if (sPojo[0].entityId != null)
     {
index e2fb1b8..8299b02 100644 (file)
@@ -78,7 +78,7 @@ public class UrlDownloadClient
         }
       } catch (IOException e)
       {
-        System.out.println(
+        jalview.bin.Console.outPrintln(
                 "Exception while closing download file output stream: "
                         + e.getMessage());
       }
@@ -90,7 +90,7 @@ public class UrlDownloadClient
         }
       } catch (IOException e)
       {
-        System.out.println("Exception while closing download channel: "
+        jalview.bin.Console.outPrintln("Exception while closing download channel: "
                 + e.getMessage());
       }
       try
@@ -101,7 +101,7 @@ public class UrlDownloadClient
         }
       } catch (IOException e)
       {
-        System.out.println("Exception while deleting download temp file: "
+        jalview.bin.Console.outPrintln("Exception while deleting download temp file: "
                 + e.getMessage());
       }
     }
index 6b98b6a..c412c36 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.math.BigInteger;
@@ -17,320 +18,314 @@ import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for anonymous complex type.
+ * &lt;p&gt;Java class for anonymous complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType>
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="alcodon" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="pos1" type="{http://www.w3.org/2001/XMLSchema}integer" />
- *                 &lt;attribute name="pos2" type="{http://www.w3.org/2001/XMLSchema}integer" />
- *                 &lt;attribute name="pos3" type="{http://www.w3.org/2001/XMLSchema}integer" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *         &lt;element name="alcodMap" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;sequence>
- *                   &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping"/>
- *                 &lt;/sequence>
- *                 &lt;attribute name="dnasq" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/sequence>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="alcodon" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="pos1" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+ *                 &amp;lt;attribute name="pos2" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+ *                 &amp;lt;attribute name="pos3" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *         &amp;lt;element name="alcodMap" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;sequence&amp;gt;
+ *                   &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping"/&amp;gt;
+ *                 &amp;lt;/sequence&amp;gt;
+ *                 &amp;lt;attribute name="dnasq" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "", propOrder = { "alcodon", "alcodMap" })
+@XmlType(name = "", propOrder = {
+    "alcodon",
+    "alcodMap"
+})
 @XmlRootElement(name = "AlcodonFrame")
-public class AlcodonFrame
-{
-
-  protected List<AlcodonFrame.Alcodon> alcodon;
-
-  protected List<AlcodonFrame.AlcodMap> alcodMap;
+public class AlcodonFrame {
 
-  /**
-   * Gets the value of the alcodon property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the alcodon property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getAlcodon().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link AlcodonFrame.Alcodon }
-   * 
-   * 
-   */
-  public List<AlcodonFrame.Alcodon> getAlcodon()
-  {
-    if (alcodon == null)
-    {
-      alcodon = new ArrayList<AlcodonFrame.Alcodon>();
-    }
-    return this.alcodon;
-  }
-
-  /**
-   * Gets the value of the alcodMap property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the alcodMap property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getAlcodMap().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link AlcodonFrame.AlcodMap }
-   * 
-   * 
-   */
-  public List<AlcodonFrame.AlcodMap> getAlcodMap()
-  {
-    if (alcodMap == null)
-    {
-      alcodMap = new ArrayList<AlcodonFrame.AlcodMap>();
-    }
-    return this.alcodMap;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="dnasq" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "mapping" })
-  public static class AlcodMap
-  {
-
-    @XmlElement(name = "Mapping", required = true)
-    protected Mapping mapping;
-
-    @XmlAttribute(name = "dnasq", required = true)
-    protected String dnasq;
+    protected List<AlcodonFrame.Alcodon> alcodon;
+    protected List<AlcodonFrame.AlcodMap> alcodMap;
 
     /**
+     * Gets the value of the alcodon property.
      * 
-     * a Mapping entry and an associated protein sequence
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the alcodon property.
      * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getAlcodon().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Mapping }
      * 
-     */
-    public Mapping getMapping()
-    {
-      return mapping;
-    }
-
-    /**
-     * Sets the value of the mapping property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link AlcodonFrame.Alcodon }
      * 
-     * @param value
-     *          allowed object is {@link Mapping }
      * 
      */
-    public void setMapping(Mapping value)
-    {
-      this.mapping = value;
+    public List<AlcodonFrame.Alcodon> getAlcodon() {
+        if (alcodon == null) {
+            alcodon = new ArrayList<AlcodonFrame.Alcodon>();
+        }
+        return this.alcodon;
     }
 
     /**
-     * Gets the value of the dnasq property.
+     * Gets the value of the alcodMap property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the alcodMap property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getAlcodMap().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link AlcodonFrame.AlcodMap }
      * 
-     * @return possible object is {@link String }
      * 
      */
-    public String getDnasq()
-    {
-      return dnasq;
+    public List<AlcodonFrame.AlcodMap> getAlcodMap() {
+        if (alcodMap == null) {
+            alcodMap = new ArrayList<AlcodonFrame.AlcodMap>();
+        }
+        return this.alcodMap;
     }
 
+
     /**
-     * Sets the value of the dnasq property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="dnasq" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link String }
      * 
      */
-    public void setDnasq(String value)
-    {
-      this.dnasq = value;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "mapping"
+    })
+    public static class AlcodMap {
 
-  }
+        @XmlElement(name = "Mapping", required = true)
+        protected Mapping mapping;
+        @XmlAttribute(name = "dnasq", required = true)
+        protected String dnasq;
 
-  /**
-   * 
-   * 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).
-   * 
-   * 
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="pos1" type="{http://www.w3.org/2001/XMLSchema}integer" />
-   *       &lt;attribute name="pos2" type="{http://www.w3.org/2001/XMLSchema}integer" />
-   *       &lt;attribute name="pos3" type="{http://www.w3.org/2001/XMLSchema}integer" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class Alcodon
-  {
+        /**
+         * 
+         *                                                                             a Mapping entry and an associated protein
+         *                                                                             sequence
+         *                                                                     
+         * 
+         * @return
+         *     possible object is
+         *     {@link Mapping }
+         *     
+         */
+        public Mapping getMapping() {
+            return mapping;
+        }
 
-    @XmlAttribute(name = "pos1")
-    protected BigInteger pos1;
+        /**
+         * Sets the value of the mapping property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Mapping }
+         *     
+         */
+        public void setMapping(Mapping value) {
+            this.mapping = value;
+        }
 
-    @XmlAttribute(name = "pos2")
-    protected BigInteger pos2;
+        /**
+         * Gets the value of the dnasq property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getDnasq() {
+            return dnasq;
+        }
 
-    @XmlAttribute(name = "pos3")
-    protected BigInteger pos3;
+        /**
+         * Sets the value of the dnasq property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setDnasq(String value) {
+            this.dnasq = value;
+        }
 
-    /**
-     * Gets the value of the pos1 property.
-     * 
-     * @return possible object is {@link BigInteger }
-     * 
-     */
-    public BigInteger getPos1()
-    {
-      return pos1;
     }
 
-    /**
-     * Sets the value of the pos1 property.
-     * 
-     * @param value
-     *          allowed object is {@link BigInteger }
-     * 
-     */
-    public void setPos1(BigInteger value)
-    {
-      this.pos1 = value;
-    }
 
     /**
-     * Gets the value of the pos2 property.
      * 
-     * @return possible object is {@link BigInteger }
+     *                                                                 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).
+     *                                                         
      * 
-     */
-    public BigInteger getPos2()
-    {
-      return pos2;
-    }
-
-    /**
-     * Sets the value of the pos2 property.
+     * &lt;p&gt;Java class for anonymous complex type.
      * 
-     * @param value
-     *          allowed object is {@link BigInteger }
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
      * 
-     */
-    public void setPos2(BigInteger value)
-    {
-      this.pos2 = value;
-    }
-
-    /**
-     * Gets the value of the pos3 property.
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="pos1" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+     *       &amp;lt;attribute name="pos2" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+     *       &amp;lt;attribute name="pos3" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link BigInteger }
      * 
      */
-    public BigInteger getPos3()
-    {
-      return pos3;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class Alcodon {
 
-    /**
-     * Sets the value of the pos3 property.
-     * 
-     * @param value
-     *          allowed object is {@link BigInteger }
-     * 
-     */
-    public void setPos3(BigInteger value)
-    {
-      this.pos3 = value;
-    }
+        @XmlAttribute(name = "pos1")
+        protected BigInteger pos1;
+        @XmlAttribute(name = "pos2")
+        protected BigInteger pos2;
+        @XmlAttribute(name = "pos3")
+        protected BigInteger pos3;
+
+        /**
+         * Gets the value of the pos1 property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link BigInteger }
+         *     
+         */
+        public BigInteger getPos1() {
+            return pos1;
+        }
 
-  }
+        /**
+         * Sets the value of the pos1 property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link BigInteger }
+         *     
+         */
+        public void setPos1(BigInteger value) {
+            this.pos1 = value;
+        }
+
+        /**
+         * Gets the value of the pos2 property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link BigInteger }
+         *     
+         */
+        public BigInteger getPos2() {
+            return pos2;
+        }
+
+        /**
+         * Sets the value of the pos2 property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link BigInteger }
+         *     
+         */
+        public void setPos2(BigInteger value) {
+            this.pos2 = value;
+        }
+
+        /**
+         * Gets the value of the pos3 property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link BigInteger }
+         *     
+         */
+        public BigInteger getPos3() {
+            return pos3;
+        }
+
+        /**
+         * Sets the value of the pos3 property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link BigInteger }
+         *     
+         */
+        public void setPos3(BigInteger value) {
+            this.pos3 = value;
+        }
+
+    }
 
 }
index 2feda64..261e0ed 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -16,810 +17,786 @@ import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for anonymous complex type.
+ * &lt;p&gt;Java class for anonymous complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType>
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}annotationElement" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="label" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *         &lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="thresholdLine" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="label" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                 &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *         &lt;element name="contactmatrix" type="{www.vamsas.ac.uk/jalview/version2}MatrixType" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="property" type="{www.vamsas.ac.uk/jalview/version2}property" maxOccurs="unbounded" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="graph" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="graphType" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="groupRef" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="graphColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="graphGroup" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="graphHeight" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="scoreOnly" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *       &lt;attribute name="score" type="{http://www.w3.org/2001/XMLSchema}double" />
- *       &lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="centreColLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="scaleColLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="showAllColLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="autoCalculated" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *       &lt;attribute name="belowAlignment" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *       &lt;attribute name="calcId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}annotationElement" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="label" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *         &amp;lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="thresholdLine" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="label" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                 &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *         &amp;lt;element name="contactmatrix" type="{www.vamsas.ac.uk/jalview/version2}MapOnAMatrixType" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="property" type="{www.vamsas.ac.uk/jalview/version2}property" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="graph" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *       &amp;lt;attribute name="graphType" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="groupRef" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="graphColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="graphGroup" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="graphHeight" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="scoreOnly" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *       &amp;lt;attribute name="score" type="{http://www.w3.org/2001/XMLSchema}double" /&amp;gt;
+ *       &amp;lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *       &amp;lt;attribute name="centreColLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *       &amp;lt;attribute name="scaleColLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *       &amp;lt;attribute name="showAllColLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *       &amp;lt;attribute name="autoCalculated" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *       &amp;lt;attribute name="belowAlignment" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *       &amp;lt;attribute name="calcId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "",
-  propOrder =
-  { "annotationElement", "label", "description", "thresholdLine",
-      "contactmatrix", "property" })
+@XmlType(name = "", propOrder = {
+    "annotationElement",
+    "label",
+    "description",
+    "thresholdLine",
+    "contactmatrix",
+    "property"
+})
 @XmlRootElement(name = "Annotation")
-public class Annotation
-{
+public class Annotation {
 
-  protected List<AnnotationElement> annotationElement;
+    protected List<AnnotationElement> annotationElement;
+    @XmlElement(required = true)
+    protected String label;
+    protected String description;
+    protected Annotation.ThresholdLine thresholdLine;
+    protected List<MapOnAMatrixType> contactmatrix;
+    protected List<Property> property;
+    @XmlAttribute(name = "graph", required = true)
+    protected boolean graph;
+    @XmlAttribute(name = "graphType")
+    protected Integer graphType;
+    @XmlAttribute(name = "sequenceRef")
+    protected String sequenceRef;
+    @XmlAttribute(name = "groupRef")
+    protected String groupRef;
+    @XmlAttribute(name = "graphColour")
+    protected Integer graphColour;
+    @XmlAttribute(name = "graphGroup")
+    protected Integer graphGroup;
+    @XmlAttribute(name = "graphHeight")
+    protected Integer graphHeight;
+    @XmlAttribute(name = "id")
+    protected String id;
+    @XmlAttribute(name = "scoreOnly")
+    protected Boolean scoreOnly;
+    @XmlAttribute(name = "score")
+    protected Double score;
+    @XmlAttribute(name = "visible")
+    protected Boolean visible;
+    @XmlAttribute(name = "centreColLabels")
+    protected Boolean centreColLabels;
+    @XmlAttribute(name = "scaleColLabels")
+    protected Boolean scaleColLabels;
+    @XmlAttribute(name = "showAllColLabels")
+    protected Boolean showAllColLabels;
+    @XmlAttribute(name = "autoCalculated")
+    protected Boolean autoCalculated;
+    @XmlAttribute(name = "belowAlignment")
+    protected Boolean belowAlignment;
+    @XmlAttribute(name = "calcId")
+    protected String calcId;
 
-  @XmlElement(required = true)
-  protected String label;
-
-  protected String description;
+    /**
+     * Gets the value of the annotationElement property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the annotationElement property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getAnnotationElement().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link AnnotationElement }
+     * 
+     * 
+     */
+    public List<AnnotationElement> getAnnotationElement() {
+        if (annotationElement == null) {
+            annotationElement = new ArrayList<AnnotationElement>();
+        }
+        return this.annotationElement;
+    }
 
-  protected Annotation.ThresholdLine thresholdLine;
-
-  protected List<MatrixType> contactmatrix;
-
-  protected List<Property> property;
-
-  @XmlAttribute(name = "graph", required = true)
-  protected boolean graph;
-
-  @XmlAttribute(name = "graphType")
-  protected Integer graphType;
-
-  @XmlAttribute(name = "sequenceRef")
-  protected String sequenceRef;
-
-  @XmlAttribute(name = "groupRef")
-  protected String groupRef;
-
-  @XmlAttribute(name = "graphColour")
-  protected Integer graphColour;
-
-  @XmlAttribute(name = "graphGroup")
-  protected Integer graphGroup;
-
-  @XmlAttribute(name = "graphHeight")
-  protected Integer graphHeight;
-
-  @XmlAttribute(name = "id")
-  protected String id;
-
-  @XmlAttribute(name = "scoreOnly")
-  protected Boolean scoreOnly;
-
-  @XmlAttribute(name = "score")
-  protected Double score;
-
-  @XmlAttribute(name = "visible")
-  protected Boolean visible;
-
-  @XmlAttribute(name = "centreColLabels")
-  protected Boolean centreColLabels;
-
-  @XmlAttribute(name = "scaleColLabels")
-  protected Boolean scaleColLabels;
-
-  @XmlAttribute(name = "showAllColLabels")
-  protected Boolean showAllColLabels;
-
-  @XmlAttribute(name = "autoCalculated")
-  protected Boolean autoCalculated;
-
-  @XmlAttribute(name = "belowAlignment")
-  protected Boolean belowAlignment;
-
-  @XmlAttribute(name = "calcId")
-  protected String calcId;
-
-  /**
-   * Gets the value of the annotationElement property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the annotationElement property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getAnnotationElement().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link AnnotationElement }
-   * 
-   * 
-   */
-  public List<AnnotationElement> getAnnotationElement()
-  {
-    if (annotationElement == null)
-    {
-      annotationElement = new ArrayList<AnnotationElement>();
-    }
-    return this.annotationElement;
-  }
-
-  /**
-   * Gets the value of the label property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getLabel()
-  {
-    return label;
-  }
-
-  /**
-   * Sets the value of the label property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setLabel(String value)
-  {
-    this.label = value;
-  }
-
-  /**
-   * Gets the value of the description property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDescription()
-  {
-    return description;
-  }
-
-  /**
-   * Sets the value of the description property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDescription(String value)
-  {
-    this.description = value;
-  }
-
-  /**
-   * Gets the value of the thresholdLine property.
-   * 
-   * @return possible object is {@link Annotation.ThresholdLine }
-   * 
-   */
-  public Annotation.ThresholdLine getThresholdLine()
-  {
-    return thresholdLine;
-  }
-
-  /**
-   * Sets the value of the thresholdLine property.
-   * 
-   * @param value
-   *          allowed object is {@link Annotation.ThresholdLine }
-   * 
-   */
-  public void setThresholdLine(Annotation.ThresholdLine value)
-  {
-    this.thresholdLine = value;
-  }
-
-  /**
-   * Gets the value of the contactmatrix property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the contactmatrix property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getContactmatrix().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link MatrixType
-   * }
-   * 
-   * 
-   */
-  public List<MatrixType> getContactmatrix()
-  {
-    if (contactmatrix == null)
-    {
-      contactmatrix = new ArrayList<MatrixType>();
-    }
-    return this.contactmatrix;
-  }
-
-  /**
-   * Gets the value of the property property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the property property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getProperty().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link Property }
-   * 
-   * 
-   */
-  public List<Property> getProperty()
-  {
-    if (property == null)
-    {
-      property = new ArrayList<Property>();
-    }
-    return this.property;
-  }
-
-  /**
-   * Gets the value of the graph property.
-   * 
-   */
-  public boolean isGraph()
-  {
-    return graph;
-  }
-
-  /**
-   * Sets the value of the graph property.
-   * 
-   */
-  public void setGraph(boolean value)
-  {
-    this.graph = value;
-  }
-
-  /**
-   * Gets the value of the graphType property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getGraphType()
-  {
-    return graphType;
-  }
-
-  /**
-   * Sets the value of the graphType property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setGraphType(Integer value)
-  {
-    this.graphType = value;
-  }
-
-  /**
-   * Gets the value of the sequenceRef property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getSequenceRef()
-  {
-    return sequenceRef;
-  }
-
-  /**
-   * Sets the value of the sequenceRef property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setSequenceRef(String value)
-  {
-    this.sequenceRef = value;
-  }
-
-  /**
-   * Gets the value of the groupRef property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getGroupRef()
-  {
-    return groupRef;
-  }
-
-  /**
-   * Sets the value of the groupRef property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setGroupRef(String value)
-  {
-    this.groupRef = value;
-  }
-
-  /**
-   * Gets the value of the graphColour property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getGraphColour()
-  {
-    return graphColour;
-  }
-
-  /**
-   * Sets the value of the graphColour property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setGraphColour(Integer value)
-  {
-    this.graphColour = value;
-  }
-
-  /**
-   * Gets the value of the graphGroup property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getGraphGroup()
-  {
-    return graphGroup;
-  }
-
-  /**
-   * Sets the value of the graphGroup property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setGraphGroup(Integer value)
-  {
-    this.graphGroup = value;
-  }
-
-  /**
-   * Gets the value of the graphHeight property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getGraphHeight()
-  {
-    return graphHeight;
-  }
-
-  /**
-   * Sets the value of the graphHeight property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setGraphHeight(Integer value)
-  {
-    this.graphHeight = value;
-  }
-
-  /**
-   * Gets the value of the id property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getId()
-  {
-    return id;
-  }
-
-  /**
-   * Sets the value of the id property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setId(String value)
-  {
-    this.id = value;
-  }
-
-  /**
-   * Gets the value of the scoreOnly property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public boolean isScoreOnly()
-  {
-    if (scoreOnly == null)
-    {
-      return false;
-    }
-    else
-    {
-      return scoreOnly;
-    }
-  }
-
-  /**
-   * Sets the value of the scoreOnly property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setScoreOnly(Boolean value)
-  {
-    this.scoreOnly = value;
-  }
-
-  /**
-   * Gets the value of the score property.
-   * 
-   * @return possible object is {@link Double }
-   * 
-   */
-  public Double getScore()
-  {
-    return score;
-  }
-
-  /**
-   * Sets the value of the score property.
-   * 
-   * @param value
-   *          allowed object is {@link Double }
-   * 
-   */
-  public void setScore(Double value)
-  {
-    this.score = value;
-  }
-
-  /**
-   * Gets the value of the visible property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public Boolean isVisible()
-  {
-    return visible;
-  }
-
-  /**
-   * Sets the value of the visible property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setVisible(Boolean value)
-  {
-    this.visible = value;
-  }
-
-  /**
-   * Gets the value of the centreColLabels property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public Boolean isCentreColLabels()
-  {
-    return centreColLabels;
-  }
-
-  /**
-   * Sets the value of the centreColLabels property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setCentreColLabels(Boolean value)
-  {
-    this.centreColLabels = value;
-  }
-
-  /**
-   * Gets the value of the scaleColLabels property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public Boolean isScaleColLabels()
-  {
-    return scaleColLabels;
-  }
-
-  /**
-   * Sets the value of the scaleColLabels property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setScaleColLabels(Boolean value)
-  {
-    this.scaleColLabels = value;
-  }
-
-  /**
-   * Gets the value of the showAllColLabels property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public Boolean isShowAllColLabels()
-  {
-    return showAllColLabels;
-  }
-
-  /**
-   * Sets the value of the showAllColLabels property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setShowAllColLabels(Boolean value)
-  {
-    this.showAllColLabels = value;
-  }
-
-  /**
-   * Gets the value of the autoCalculated property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public boolean isAutoCalculated()
-  {
-    if (autoCalculated == null)
-    {
-      return false;
-    }
-    else
-    {
-      return autoCalculated;
-    }
-  }
-
-  /**
-   * Sets the value of the autoCalculated property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setAutoCalculated(Boolean value)
-  {
-    this.autoCalculated = value;
-  }
-
-  /**
-   * Gets the value of the belowAlignment property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public boolean isBelowAlignment()
-  {
-    if (belowAlignment == null)
-    {
-      return true;
-    }
-    else
-    {
-      return belowAlignment;
-    }
-  }
-
-  /**
-   * Sets the value of the belowAlignment property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setBelowAlignment(Boolean value)
-  {
-    this.belowAlignment = value;
-  }
-
-  /**
-   * Gets the value of the calcId property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getCalcId()
-  {
-    return calcId;
-  }
-
-  /**
-   * Sets the value of the calcId property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setCalcId(String value)
-  {
-    this.calcId = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="label" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *       &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class ThresholdLine
-  {
-
-    @XmlAttribute(name = "label")
-    protected String label;
+    /**
+     * Gets the value of the label property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setLabel(String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the description property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getDescription() {
+        return description;
+    }
 
-    @XmlAttribute(name = "value")
-    protected Float value;
+    /**
+     * Sets the value of the description property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDescription(String value) {
+        this.description = value;
+    }
 
-    @XmlAttribute(name = "colour")
-    protected Integer colour;
+    /**
+     * Gets the value of the thresholdLine property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Annotation.ThresholdLine }
+     *     
+     */
+    public Annotation.ThresholdLine getThresholdLine() {
+        return thresholdLine;
+    }
 
     /**
-     * Gets the value of the label property.
+     * Sets the value of the thresholdLine property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Annotation.ThresholdLine }
+     *     
+     */
+    public void setThresholdLine(Annotation.ThresholdLine value) {
+        this.thresholdLine = value;
+    }
+
+    /**
+     * Gets the value of the contactmatrix property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the contactmatrix property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getContactmatrix().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link MapOnAMatrixType }
      * 
-     * @return possible object is {@link String }
      * 
      */
-    public String getLabel()
-    {
-      return label;
+    public List<MapOnAMatrixType> getContactmatrix() {
+        if (contactmatrix == null) {
+            contactmatrix = new ArrayList<MapOnAMatrixType>();
+        }
+        return this.contactmatrix;
     }
 
     /**
-     * Sets the value of the label property.
+     * Gets the value of the property property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the property property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getProperty().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Property }
+     * 
+     * 
+     */
+    public List<Property> getProperty() {
+        if (property == null) {
+            property = new ArrayList<Property>();
+        }
+        return this.property;
+    }
+
+    /**
+     * Gets the value of the graph property.
+     * 
+     */
+    public boolean isGraph() {
+        return graph;
+    }
+
+    /**
+     * Sets the value of the graph property.
+     * 
+     */
+    public void setGraph(boolean value) {
+        this.graph = value;
+    }
+
+    /**
+     * Gets the value of the graphType property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getGraphType() {
+        return graphType;
+    }
+
+    /**
+     * Sets the value of the graphType property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setGraphType(Integer value) {
+        this.graphType = value;
+    }
+
+    /**
+     * Gets the value of the sequenceRef property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getSequenceRef() {
+        return sequenceRef;
+    }
+
+    /**
+     * Sets the value of the sequenceRef property.
      * 
      * @param value
-     *          allowed object is {@link String }
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setSequenceRef(String value) {
+        this.sequenceRef = value;
+    }
+
+    /**
+     * Gets the value of the groupRef property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public void setLabel(String value)
-    {
-      this.label = value;
+    public String getGroupRef() {
+        return groupRef;
     }
 
     /**
-     * Gets the value of the value property.
+     * Sets the value of the groupRef property.
      * 
-     * @return possible object is {@link Float }
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setGroupRef(String value) {
+        this.groupRef = value;
+    }
+
+    /**
+     * Gets the value of the graphColour property.
      * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
      */
-    public Float getValue()
-    {
-      return value;
+    public Integer getGraphColour() {
+        return graphColour;
     }
 
     /**
-     * Sets the value of the value property.
+     * Sets the value of the graphColour property.
      * 
      * @param value
-     *          allowed object is {@link Float }
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setGraphColour(Integer value) {
+        this.graphColour = value;
+    }
+
+    /**
+     * Gets the value of the graphGroup property.
      * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
      */
-    public void setValue(Float value)
-    {
-      this.value = value;
+    public Integer getGraphGroup() {
+        return graphGroup;
     }
 
     /**
-     * Gets the value of the colour property.
+     * Sets the value of the graphGroup property.
      * 
-     * @return possible object is {@link Integer }
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setGraphGroup(Integer value) {
+        this.graphGroup = value;
+    }
+
+    /**
+     * Gets the value of the graphHeight property.
      * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
      */
-    public Integer getColour()
-    {
-      return colour;
+    public Integer getGraphHeight() {
+        return graphHeight;
     }
 
     /**
-     * Sets the value of the colour property.
+     * Sets the value of the graphHeight property.
      * 
      * @param value
-     *          allowed object is {@link Integer }
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setGraphHeight(Integer value) {
+        this.graphHeight = value;
+    }
+
+    /**
+     * Gets the value of the id property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public void setColour(Integer value)
-    {
-      this.colour = value;
+    public String getId() {
+        return id;
     }
 
-  }
+    /**
+     * Sets the value of the id property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setId(String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the scoreOnly property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public boolean isScoreOnly() {
+        if (scoreOnly == null) {
+            return false;
+        } else {
+            return scoreOnly;
+        }
+    }
+
+    /**
+     * Sets the value of the scoreOnly property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setScoreOnly(Boolean value) {
+        this.scoreOnly = value;
+    }
+
+    /**
+     * Gets the value of the score property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Double }
+     *     
+     */
+    public Double getScore() {
+        return score;
+    }
+
+    /**
+     * Sets the value of the score property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Double }
+     *     
+     */
+    public void setScore(Double value) {
+        this.score = value;
+    }
+
+    /**
+     * Gets the value of the visible property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public Boolean isVisible() {
+        return visible;
+    }
+
+    /**
+     * Sets the value of the visible property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setVisible(Boolean value) {
+        this.visible = value;
+    }
+
+    /**
+     * Gets the value of the centreColLabels property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public Boolean isCentreColLabels() {
+        return centreColLabels;
+    }
+
+    /**
+     * Sets the value of the centreColLabels property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setCentreColLabels(Boolean value) {
+        this.centreColLabels = value;
+    }
+
+    /**
+     * Gets the value of the scaleColLabels property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public Boolean isScaleColLabels() {
+        return scaleColLabels;
+    }
+
+    /**
+     * Sets the value of the scaleColLabels property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setScaleColLabels(Boolean value) {
+        this.scaleColLabels = value;
+    }
+
+    /**
+     * Gets the value of the showAllColLabels property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public Boolean isShowAllColLabels() {
+        return showAllColLabels;
+    }
+
+    /**
+     * Sets the value of the showAllColLabels property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setShowAllColLabels(Boolean value) {
+        this.showAllColLabels = value;
+    }
+
+    /**
+     * Gets the value of the autoCalculated property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public boolean isAutoCalculated() {
+        if (autoCalculated == null) {
+            return false;
+        } else {
+            return autoCalculated;
+        }
+    }
+
+    /**
+     * Sets the value of the autoCalculated property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setAutoCalculated(Boolean value) {
+        this.autoCalculated = value;
+    }
+
+    /**
+     * Gets the value of the belowAlignment property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public boolean isBelowAlignment() {
+        if (belowAlignment == null) {
+            return true;
+        } else {
+            return belowAlignment;
+        }
+    }
+
+    /**
+     * Sets the value of the belowAlignment property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setBelowAlignment(Boolean value) {
+        this.belowAlignment = value;
+    }
+
+    /**
+     * Gets the value of the calcId property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getCalcId() {
+        return calcId;
+    }
+
+    /**
+     * Sets the value of the calcId property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setCalcId(String value) {
+        this.calcId = value;
+    }
+
+
+    /**
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="label" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *       &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
+     * 
+     */
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class ThresholdLine {
+
+        @XmlAttribute(name = "label")
+        protected String label;
+        @XmlAttribute(name = "value")
+        protected Float value;
+        @XmlAttribute(name = "colour")
+        protected Integer colour;
+
+        /**
+         * Gets the value of the label property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getLabel() {
+            return label;
+        }
+
+        /**
+         * Sets the value of the label property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setLabel(String value) {
+            this.label = value;
+        }
+
+        /**
+         * Gets the value of the value property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Float }
+         *     
+         */
+        public Float getValue() {
+            return value;
+        }
+
+        /**
+         * Sets the value of the value property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Float }
+         *     
+         */
+        public void setValue(Float value) {
+            this.value = value;
+        }
+
+        /**
+         * Gets the value of the colour property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getColour() {
+            return colour;
+        }
+
+        /**
+         * Sets the value of the colour property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setColour(Integer value) {
+            this.colour = value;
+        }
+
+    }
 
 }
index c820076..f7e974b 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlAccessType;
@@ -12,244 +13,242 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for AnnotationColourScheme complex type.
+ * &lt;p&gt;Java class for AnnotationColourScheme complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="AnnotationColourScheme">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;attribute name="aboveThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="annotation" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="minColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="maxColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="colourScheme" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
- *       &lt;attribute name="perSequence" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="predefinedColours" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="AnnotationColourScheme"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;attribute name="aboveThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="annotation" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="minColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="maxColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="colourScheme" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *       &amp;lt;attribute name="perSequence" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *       &amp;lt;attribute name="predefinedColours" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
 @XmlType(name = "AnnotationColourScheme", namespace = "www.jalview.org")
-public class AnnotationColourScheme
-{
-
-  @XmlAttribute(name = "aboveThreshold")
-  protected Integer aboveThreshold;
-
-  @XmlAttribute(name = "annotation")
-  protected String annotation;
-
-  @XmlAttribute(name = "minColour")
-  protected Integer minColour;
-
-  @XmlAttribute(name = "maxColour")
-  protected Integer maxColour;
-
-  @XmlAttribute(name = "colourScheme")
-  protected String colourScheme;
-
-  @XmlAttribute(name = "threshold")
-  protected Float threshold;
-
-  @XmlAttribute(name = "perSequence")
-  protected Boolean perSequence;
-
-  @XmlAttribute(name = "predefinedColours")
-  protected Boolean predefinedColours;
-
-  /**
-   * Gets the value of the aboveThreshold property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getAboveThreshold()
-  {
-    return aboveThreshold;
-  }
-
-  /**
-   * Sets the value of the aboveThreshold property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setAboveThreshold(Integer value)
-  {
-    this.aboveThreshold = value;
-  }
-
-  /**
-   * Gets the value of the annotation property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getAnnotation()
-  {
-    return annotation;
-  }
-
-  /**
-   * Sets the value of the annotation property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setAnnotation(String value)
-  {
-    this.annotation = value;
-  }
-
-  /**
-   * Gets the value of the minColour property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getMinColour()
-  {
-    return minColour;
-  }
-
-  /**
-   * Sets the value of the minColour property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setMinColour(Integer value)
-  {
-    this.minColour = value;
-  }
-
-  /**
-   * Gets the value of the maxColour property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getMaxColour()
-  {
-    return maxColour;
-  }
-
-  /**
-   * Sets the value of the maxColour property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setMaxColour(Integer value)
-  {
-    this.maxColour = value;
-  }
-
-  /**
-   * Gets the value of the colourScheme property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getColourScheme()
-  {
-    return colourScheme;
-  }
-
-  /**
-   * Sets the value of the colourScheme property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setColourScheme(String value)
-  {
-    this.colourScheme = value;
-  }
-
-  /**
-   * Gets the value of the threshold property.
-   * 
-   * @return possible object is {@link Float }
-   * 
-   */
-  public Float getThreshold()
-  {
-    return threshold;
-  }
-
-  /**
-   * Sets the value of the threshold property.
-   * 
-   * @param value
-   *          allowed object is {@link Float }
-   * 
-   */
-  public void setThreshold(Float value)
-  {
-    this.threshold = value;
-  }
-
-  /**
-   * Gets the value of the perSequence property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public Boolean isPerSequence()
-  {
-    return perSequence;
-  }
-
-  /**
-   * Sets the value of the perSequence property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setPerSequence(Boolean value)
-  {
-    this.perSequence = value;
-  }
-
-  /**
-   * Gets the value of the predefinedColours property.
-   * 
-   * @return possible object is {@link Boolean }
-   * 
-   */
-  public Boolean isPredefinedColours()
-  {
-    return predefinedColours;
-  }
-
-  /**
-   * Sets the value of the predefinedColours property.
-   * 
-   * @param value
-   *          allowed object is {@link Boolean }
-   * 
-   */
-  public void setPredefinedColours(Boolean value)
-  {
-    this.predefinedColours = value;
-  }
+public class AnnotationColourScheme {
+
+    @XmlAttribute(name = "aboveThreshold")
+    protected Integer aboveThreshold;
+    @XmlAttribute(name = "annotation")
+    protected String annotation;
+    @XmlAttribute(name = "minColour")
+    protected Integer minColour;
+    @XmlAttribute(name = "maxColour")
+    protected Integer maxColour;
+    @XmlAttribute(name = "colourScheme")
+    protected String colourScheme;
+    @XmlAttribute(name = "threshold")
+    protected Float threshold;
+    @XmlAttribute(name = "perSequence")
+    protected Boolean perSequence;
+    @XmlAttribute(name = "predefinedColours")
+    protected Boolean predefinedColours;
+
+    /**
+     * Gets the value of the aboveThreshold property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getAboveThreshold() {
+        return aboveThreshold;
+    }
+
+    /**
+     * Sets the value of the aboveThreshold property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setAboveThreshold(Integer value) {
+        this.aboveThreshold = value;
+    }
+
+    /**
+     * Gets the value of the annotation property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getAnnotation() {
+        return annotation;
+    }
+
+    /**
+     * Sets the value of the annotation property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setAnnotation(String value) {
+        this.annotation = value;
+    }
+
+    /**
+     * Gets the value of the minColour property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getMinColour() {
+        return minColour;
+    }
+
+    /**
+     * Sets the value of the minColour property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setMinColour(Integer value) {
+        this.minColour = value;
+    }
+
+    /**
+     * Gets the value of the maxColour property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getMaxColour() {
+        return maxColour;
+    }
+
+    /**
+     * Sets the value of the maxColour property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setMaxColour(Integer value) {
+        this.maxColour = value;
+    }
+
+    /**
+     * Gets the value of the colourScheme property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getColourScheme() {
+        return colourScheme;
+    }
+
+    /**
+     * Sets the value of the colourScheme property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setColourScheme(String value) {
+        this.colourScheme = value;
+    }
+
+    /**
+     * Gets the value of the threshold property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Float }
+     *     
+     */
+    public Float getThreshold() {
+        return threshold;
+    }
+
+    /**
+     * Sets the value of the threshold property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Float }
+     *     
+     */
+    public void setThreshold(Float value) {
+        this.threshold = value;
+    }
+
+    /**
+     * Gets the value of the perSequence property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public Boolean isPerSequence() {
+        return perSequence;
+    }
+
+    /**
+     * Sets the value of the perSequence property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setPerSequence(Boolean value) {
+        this.perSequence = value;
+    }
+
+    /**
+     * Gets the value of the predefinedColours property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Boolean }
+     *     
+     */
+    public Boolean isPredefinedColours() {
+        return predefinedColours;
+    }
+
+    /**
+     * Sets the value of the predefinedColours property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Boolean }
+     *     
+     */
+    public void setPredefinedColours(Boolean value) {
+        this.predefinedColours = value;
+    }
 
 }
index 087667a..a57101a 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlAccessType;
@@ -13,193 +14,190 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for anonymous complex type.
+ * &lt;p&gt;Java class for anonymous complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType>
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="displayCharacter" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="secondaryStructure" minOccurs="0">
- *           &lt;simpleType>
- *             &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
- *               &lt;length value="1"/>
- *             &lt;/restriction>
- *           &lt;/simpleType>
- *         &lt;/element>
- *         &lt;element name="value" type="{http://www.w3.org/2001/XMLSchema}float" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="position" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="displayCharacter" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="secondaryStructure" minOccurs="0"&amp;gt;
+ *           &amp;lt;simpleType&amp;gt;
+ *             &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}string"&amp;gt;
+ *               &amp;lt;length value="1"/&amp;gt;
+ *             &amp;lt;/restriction&amp;gt;
+ *           &amp;lt;/simpleType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *         &amp;lt;element name="value" type="{http://www.w3.org/2001/XMLSchema}float" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="position" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "",
-  propOrder =
-  { "displayCharacter", "description", "secondaryStructure", "value" })
+@XmlType(name = "", propOrder = {
+    "displayCharacter",
+    "description",
+    "secondaryStructure",
+    "value"
+})
 @XmlRootElement(name = "annotationElement")
-public class AnnotationElement
-{
-
-  protected String displayCharacter;
-
-  protected String description;
-
-  protected String secondaryStructure;
-
-  protected Float value;
-
-  @XmlAttribute(name = "position", required = true)
-  protected int position;
-
-  @XmlAttribute(name = "colour")
-  protected Integer colour;
-
-  /**
-   * Gets the value of the displayCharacter property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDisplayCharacter()
-  {
-    return displayCharacter;
-  }
-
-  /**
-   * Sets the value of the displayCharacter property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDisplayCharacter(String value)
-  {
-    this.displayCharacter = value;
-  }
-
-  /**
-   * Gets the value of the description property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDescription()
-  {
-    return description;
-  }
-
-  /**
-   * Sets the value of the description property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDescription(String value)
-  {
-    this.description = value;
-  }
-
-  /**
-   * Gets the value of the secondaryStructure property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getSecondaryStructure()
-  {
-    return secondaryStructure;
-  }
-
-  /**
-   * Sets the value of the secondaryStructure property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setSecondaryStructure(String value)
-  {
-    this.secondaryStructure = value;
-  }
-
-  /**
-   * Gets the value of the value property.
-   * 
-   * @return possible object is {@link Float }
-   * 
-   */
-  public Float getValue()
-  {
-    return value;
-  }
-
-  /**
-   * Sets the value of the value property.
-   * 
-   * @param value
-   *          allowed object is {@link Float }
-   * 
-   */
-  public void setValue(Float value)
-  {
-    this.value = value;
-  }
-
-  /**
-   * Gets the value of the position property.
-   * 
-   */
-  public int getPosition()
-  {
-    return position;
-  }
-
-  /**
-   * Sets the value of the position property.
-   * 
-   */
-  public void setPosition(int value)
-  {
-    this.position = value;
-  }
-
-  /**
-   * Gets the value of the colour property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getColour()
-  {
-    return colour;
-  }
-
-  /**
-   * Sets the value of the colour property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setColour(Integer value)
-  {
-    this.colour = value;
-  }
+public class AnnotationElement {
+
+    protected String displayCharacter;
+    protected String description;
+    protected String secondaryStructure;
+    protected Float value;
+    @XmlAttribute(name = "position", required = true)
+    protected int position;
+    @XmlAttribute(name = "colour")
+    protected Integer colour;
+
+    /**
+     * Gets the value of the displayCharacter property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getDisplayCharacter() {
+        return displayCharacter;
+    }
+
+    /**
+     * Sets the value of the displayCharacter property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDisplayCharacter(String value) {
+        this.displayCharacter = value;
+    }
+
+    /**
+     * Gets the value of the description property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDescription(String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the secondaryStructure property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getSecondaryStructure() {
+        return secondaryStructure;
+    }
+
+    /**
+     * Sets the value of the secondaryStructure property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setSecondaryStructure(String value) {
+        this.secondaryStructure = value;
+    }
+
+    /**
+     * Gets the value of the value property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Float }
+     *     
+     */
+    public Float getValue() {
+        return value;
+    }
+
+    /**
+     * Sets the value of the value property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Float }
+     *     
+     */
+    public void setValue(Float value) {
+        this.value = value;
+    }
+
+    /**
+     * Gets the value of the position property.
+     * 
+     */
+    public int getPosition() {
+        return position;
+    }
+
+    /**
+     * Sets the value of the position property.
+     * 
+     */
+    public void setPosition(int value) {
+        this.position = value;
+    }
+
+    /**
+     * Gets the value of the colour property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getColour() {
+        return colour;
+    }
+
+    /**
+     * Sets the value of the colour property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setColour(Integer value) {
+        this.colour = value;
+    }
 
 }
index b42a170..4ef5abc 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -15,177 +16,171 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for DoubleMatrix complex type.
+ * &lt;p&gt;Java class for DoubleMatrix complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="DoubleMatrix">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="row" type="{www.jalview.org}DoubleVector" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="D" type="{www.jalview.org}DoubleVector" minOccurs="0"/>
- *         &lt;element name="E" type="{www.jalview.org}DoubleVector" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="rows" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="columns" type="{http://www.w3.org/2001/XMLSchema}int" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="DoubleMatrix"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="row" type="{www.jalview.org}DoubleVector" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="D" type="{www.jalview.org}DoubleVector" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="E" type="{www.jalview.org}DoubleVector" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="rows" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="columns" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "DoubleMatrix",
-  namespace = "www.jalview.org",
-  propOrder =
-  { "row", "d", "e" })
-public class DoubleMatrix
-{
-
-  protected List<DoubleVector> row;
-
-  @XmlElement(name = "D")
-  protected DoubleVector d;
-
-  @XmlElement(name = "E")
-  protected DoubleVector e;
-
-  @XmlAttribute(name = "rows")
-  protected Integer rows;
-
-  @XmlAttribute(name = "columns")
-  protected Integer columns;
-
-  /**
-   * Gets the value of the row property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the row property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getRow().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link DoubleVector }
-   * 
-   * 
-   */
-  public List<DoubleVector> getRow()
-  {
-    if (row == null)
-    {
-      row = new ArrayList<DoubleVector>();
+@XmlType(name = "DoubleMatrix", namespace = "www.jalview.org", propOrder = {
+    "row",
+    "d",
+    "e"
+})
+public class DoubleMatrix {
+
+    protected List<DoubleVector> row;
+    @XmlElement(name = "D")
+    protected DoubleVector d;
+    @XmlElement(name = "E")
+    protected DoubleVector e;
+    @XmlAttribute(name = "rows")
+    protected Integer rows;
+    @XmlAttribute(name = "columns")
+    protected Integer columns;
+
+    /**
+     * Gets the value of the row property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the row property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getRow().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link DoubleVector }
+     * 
+     * 
+     */
+    public List<DoubleVector> getRow() {
+        if (row == null) {
+            row = new ArrayList<DoubleVector>();
+        }
+        return this.row;
+    }
+
+    /**
+     * Gets the value of the d property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link DoubleVector }
+     *     
+     */
+    public DoubleVector getD() {
+        return d;
+    }
+
+    /**
+     * Sets the value of the d property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link DoubleVector }
+     *     
+     */
+    public void setD(DoubleVector value) {
+        this.d = value;
+    }
+
+    /**
+     * Gets the value of the e property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link DoubleVector }
+     *     
+     */
+    public DoubleVector getE() {
+        return e;
+    }
+
+    /**
+     * Sets the value of the e property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link DoubleVector }
+     *     
+     */
+    public void setE(DoubleVector value) {
+        this.e = value;
+    }
+
+    /**
+     * Gets the value of the rows property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getRows() {
+        return rows;
+    }
+
+    /**
+     * Sets the value of the rows property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setRows(Integer value) {
+        this.rows = value;
+    }
+
+    /**
+     * Gets the value of the columns property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Integer }
+     *     
+     */
+    public Integer getColumns() {
+        return columns;
+    }
+
+    /**
+     * Sets the value of the columns property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Integer }
+     *     
+     */
+    public void setColumns(Integer value) {
+        this.columns = value;
     }
-    return this.row;
-  }
-
-  /**
-   * Gets the value of the d property.
-   * 
-   * @return possible object is {@link DoubleVector }
-   * 
-   */
-  public DoubleVector getD()
-  {
-    return d;
-  }
-
-  /**
-   * Sets the value of the d property.
-   * 
-   * @param value
-   *          allowed object is {@link DoubleVector }
-   * 
-   */
-  public void setD(DoubleVector value)
-  {
-    this.d = value;
-  }
-
-  /**
-   * Gets the value of the e property.
-   * 
-   * @return possible object is {@link DoubleVector }
-   * 
-   */
-  public DoubleVector getE()
-  {
-    return e;
-  }
-
-  /**
-   * Sets the value of the e property.
-   * 
-   * @param value
-   *          allowed object is {@link DoubleVector }
-   * 
-   */
-  public void setE(DoubleVector value)
-  {
-    this.e = value;
-  }
-
-  /**
-   * Gets the value of the rows property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getRows()
-  {
-    return rows;
-  }
-
-  /**
-   * Sets the value of the rows property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setRows(Integer value)
-  {
-    this.rows = value;
-  }
-
-  /**
-   * Gets the value of the columns property.
-   * 
-   * @return possible object is {@link Integer }
-   * 
-   */
-  public Integer getColumns()
-  {
-    return columns;
-  }
-
-  /**
-   * Sets the value of the columns property.
-   * 
-   * @param value
-   *          allowed object is {@link Integer }
-   * 
-   */
-  public void setColumns(Integer value)
-  {
-    this.columns = value;
-  }
 
 }
index 3b449fe..19a0d24 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -14,69 +15,62 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for DoubleVector complex type.
+ * &lt;p&gt;Java class for DoubleVector complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="DoubleVector">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="v" type="{http://www.w3.org/2001/XMLSchema}double" maxOccurs="unbounded" minOccurs="0"/>
- *       &lt;/sequence>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="DoubleVector"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="v" type="{http://www.w3.org/2001/XMLSchema}double" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "DoubleVector",
-  namespace = "www.jalview.org",
-  propOrder =
-  { "v" })
-public class DoubleVector
-{
+@XmlType(name = "DoubleVector", namespace = "www.jalview.org", propOrder = {
+    "v"
+})
+public class DoubleVector {
 
-  @XmlElement(type = Double.class)
-  protected List<Double> v;
+    @XmlElement(type = Double.class)
+    protected List<Double> v;
 
-  /**
-   * Gets the value of the v property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the v property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getV().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link Double }
-   * 
-   * 
-   */
-  public List<Double> getV()
-  {
-    if (v == null)
-    {
-      v = new ArrayList<Double>();
+    /**
+     * Gets the value of the v property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the v property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getV().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Double }
+     * 
+     * 
+     */
+    public List<Double> getV() {
+        if (v == null) {
+            v = new ArrayList<Double>();
+        }
+        return this.v;
     }
-    return this.v;
-  }
 
 }
index afedb4c..97bedae 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -14,365 +15,349 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for feature complex type.
+ * &lt;p&gt;Java class for feature complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="feature">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="otherData" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="key" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="key2" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/sequence>
- *       &lt;attribute name="begin" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="status" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="featureGroup" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="score" type="{http://www.w3.org/2001/XMLSchema}float" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="feature"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="otherData" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="key" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="key2" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="begin" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *       &amp;lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="status" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="featureGroup" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="score" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "feature",
-  namespace = "www.jalview.org",
-  propOrder =
-  { "otherData" })
-public class Feature
-{
-
-  protected List<Feature.OtherData> otherData;
-
-  @XmlAttribute(name = "begin", required = true)
-  protected int begin;
-
-  @XmlAttribute(name = "end", required = true)
-  protected int end;
-
-  @XmlAttribute(name = "type", required = true)
-  protected String type;
-
-  @XmlAttribute(name = "description")
-  protected String description;
-
-  @XmlAttribute(name = "status")
-  protected String status;
-
-  @XmlAttribute(name = "featureGroup")
-  protected String featureGroup;
-
-  @XmlAttribute(name = "score")
-  protected Float score;
-
-  /**
-   * Gets the value of the otherData property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the otherData property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getOtherData().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link Feature.OtherData }
-   * 
-   * 
-   */
-  public List<Feature.OtherData> getOtherData()
-  {
-    if (otherData == null)
-    {
-      otherData = new ArrayList<Feature.OtherData>();
+@XmlType(name = "feature", namespace = "www.jalview.org", propOrder = {
+    "otherData"
+})
+public class Feature {
+
+    protected List<Feature.OtherData> otherData;
+    @XmlAttribute(name = "begin", required = true)
+    protected int begin;
+    @XmlAttribute(name = "end", required = true)
+    protected int end;
+    @XmlAttribute(name = "type", required = true)
+    protected String type;
+    @XmlAttribute(name = "description")
+    protected String description;
+    @XmlAttribute(name = "status")
+    protected String status;
+    @XmlAttribute(name = "featureGroup")
+    protected String featureGroup;
+    @XmlAttribute(name = "score")
+    protected Float score;
+
+    /**
+     * Gets the value of the otherData property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the otherData property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getOtherData().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Feature.OtherData }
+     * 
+     * 
+     */
+    public List<Feature.OtherData> getOtherData() {
+        if (otherData == null) {
+            otherData = new ArrayList<Feature.OtherData>();
+        }
+        return this.otherData;
     }
-    return this.otherData;
-  }
-
-  /**
-   * Gets the value of the begin property.
-   * 
-   */
-  public int getBegin()
-  {
-    return begin;
-  }
-
-  /**
-   * Sets the value of the begin property.
-   * 
-   */
-  public void setBegin(int value)
-  {
-    this.begin = value;
-  }
-
-  /**
-   * Gets the value of the end property.
-   * 
-   */
-  public int getEnd()
-  {
-    return end;
-  }
-
-  /**
-   * Sets the value of the end property.
-   * 
-   */
-  public void setEnd(int value)
-  {
-    this.end = value;
-  }
-
-  /**
-   * Gets the value of the type property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getType()
-  {
-    return type;
-  }
-
-  /**
-   * Sets the value of the type property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setType(String value)
-  {
-    this.type = value;
-  }
-
-  /**
-   * Gets the value of the description property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDescription()
-  {
-    return description;
-  }
-
-  /**
-   * Sets the value of the description property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDescription(String value)
-  {
-    this.description = value;
-  }
-
-  /**
-   * Gets the value of the status property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getStatus()
-  {
-    return status;
-  }
-
-  /**
-   * Sets the value of the status property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setStatus(String value)
-  {
-    this.status = value;
-  }
-
-  /**
-   * Gets the value of the featureGroup property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getFeatureGroup()
-  {
-    return featureGroup;
-  }
-
-  /**
-   * Sets the value of the featureGroup property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setFeatureGroup(String value)
-  {
-    this.featureGroup = value;
-  }
-
-  /**
-   * Gets the value of the score property.
-   * 
-   * @return possible object is {@link Float }
-   * 
-   */
-  public Float getScore()
-  {
-    return score;
-  }
-
-  /**
-   * Sets the value of the score property.
-   * 
-   * @param value
-   *          allowed object is {@link Float }
-   * 
-   */
-  public void setScore(Float value)
-  {
-    this.score = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="key" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="key2" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class OtherData
-  {
-
-    @XmlAttribute(name = "key", required = true)
-    protected String key;
-
-    @XmlAttribute(name = "key2")
-    protected String key2;
-
-    @XmlAttribute(name = "value", required = true)
-    protected String value;
 
     /**
-     * Gets the value of the key property.
+     * Gets the value of the begin property.
      * 
-     * @return possible object is {@link String }
+     */
+    public int getBegin() {
+        return begin;
+    }
+
+    /**
+     * Sets the value of the begin property.
      * 
      */
-    public String getKey()
-    {
-      return key;
+    public void setBegin(int value) {
+        this.begin = value;
     }
 
     /**
-     * Sets the value of the key property.
+     * Gets the value of the end property.
      * 
-     * @param value
-     *          allowed object is {@link String }
+     */
+    public int getEnd() {
+        return end;
+    }
+
+    /**
+     * Sets the value of the end property.
+     * 
+     */
+    public void setEnd(int value) {
+        this.end = value;
+    }
+
+    /**
+     * Gets the value of the type property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public void setKey(String value)
-    {
-      this.key = value;
+    public String getType() {
+        return type;
     }
 
     /**
-     * Gets the value of the key2 property.
+     * Sets the value of the type property.
      * 
-     * @return possible object is {@link String }
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setType(String value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the description property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getKey2()
-    {
-      return key2;
+    public String getDescription() {
+        return description;
     }
 
     /**
-     * Sets the value of the key2 property.
+     * Sets the value of the description property.
      * 
      * @param value
-     *          allowed object is {@link String }
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDescription(String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the status property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public void setKey2(String value)
-    {
-      this.key2 = value;
+    public String getStatus() {
+        return status;
     }
 
     /**
-     * Gets the value of the value property.
+     * Sets the value of the status property.
      * 
-     * @return possible object is {@link String }
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setStatus(String value) {
+        this.status = value;
+    }
+
+    /**
+     * Gets the value of the featureGroup property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getValue()
-    {
-      return value;
+    public String getFeatureGroup() {
+        return featureGroup;
     }
 
     /**
-     * Sets the value of the value property.
+     * Sets the value of the featureGroup property.
      * 
      * @param value
-     *          allowed object is {@link String }
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setFeatureGroup(String value) {
+        this.featureGroup = value;
+    }
+
+    /**
+     * Gets the value of the score property.
      * 
+     * @return
+     *     possible object is
+     *     {@link Float }
+     *     
      */
-    public void setValue(String value)
-    {
-      this.value = value;
+    public Float getScore() {
+        return score;
     }
 
-  }
+    /**
+     * Sets the value of the score property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Float }
+     *     
+     */
+    public void setScore(Float value) {
+        this.score = value;
+    }
+
+
+    /**
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="key" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="key2" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
+     * 
+     */
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class OtherData {
+
+        @XmlAttribute(name = "key", required = true)
+        protected String key;
+        @XmlAttribute(name = "key2")
+        protected String key2;
+        @XmlAttribute(name = "value", required = true)
+        protected String value;
+
+        /**
+         * Gets the value of the key property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getKey() {
+            return key;
+        }
+
+        /**
+         * Sets the value of the key property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setKey(String value) {
+            this.key = value;
+        }
+
+        /**
+         * Gets the value of the key2 property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getKey2() {
+            return key2;
+        }
+
+        /**
+         * Sets the value of the key2 property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setKey2(String value) {
+            this.key2 = value;
+        }
+
+        /**
+         * Gets the value of the value property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getValue() {
+            return value;
+        }
+
+        /**
+         * Sets the value of the value property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setValue(String value) {
+            this.value = value;
+        }
+
+    }
 
 }
index fa80569..9913337 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -15,150 +16,145 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for FeatureMatcher complex type.
+ * &lt;p&gt;Java class for FeatureMatcher complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="FeatureMatcher">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/>
- *         &lt;element name="condition" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *         &lt;element name="value" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *       &lt;/sequence>
- *       &lt;attribute name="by" type="{www.jalview.org/colours}FilterBy" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="FeatureMatcher"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="condition" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *         &amp;lt;element name="value" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="by" type="{www.jalview.org/colours}FilterBy" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "FeatureMatcher",
-  namespace = "www.jalview.org/colours",
-  propOrder =
-  { "attributeName", "condition", "value" })
-public class FeatureMatcher
-{
-
-  @XmlElement(namespace = "")
-  protected List<String> attributeName;
+@XmlType(name = "FeatureMatcher", namespace = "www.jalview.org/colours", propOrder = {
+    "attributeName",
+    "condition",
+    "value"
+})
+public class FeatureMatcher {
 
-  @XmlElement(namespace = "", required = true)
-  protected String condition;
+    @XmlElement(namespace = "")
+    protected List<String> attributeName;
+    @XmlElement(namespace = "", required = true)
+    protected String condition;
+    @XmlElement(namespace = "", required = true)
+    protected String value;
+    @XmlAttribute(name = "by")
+    protected FilterBy by;
 
-  @XmlElement(namespace = "", required = true)
-  protected String value;
-
-  @XmlAttribute(name = "by")
-  protected FilterBy by;
-
-  /**
-   * Gets the value of the attributeName property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the attributeName property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getAttributeName().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link String }
-   * 
-   * 
-   */
-  public List<String> getAttributeName()
-  {
-    if (attributeName == null)
-    {
-      attributeName = new ArrayList<String>();
+    /**
+     * Gets the value of the attributeName property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the attributeName property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getAttributeName().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link String }
+     * 
+     * 
+     */
+    public List<String> getAttributeName() {
+        if (attributeName == null) {
+            attributeName = new ArrayList<String>();
+        }
+        return this.attributeName;
     }
-    return this.attributeName;
-  }
 
-  /**
-   * Gets the value of the condition property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getCondition()
-  {
-    return condition;
-  }
+    /**
+     * Gets the value of the condition property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getCondition() {
+        return condition;
+    }
 
-  /**
-   * Sets the value of the condition property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setCondition(String value)
-  {
-    this.condition = value;
-  }
+    /**
+     * Sets the value of the condition property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setCondition(String value) {
+        this.condition = value;
+    }
 
-  /**
-   * Gets the value of the value property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getValue()
-  {
-    return value;
-  }
+    /**
+     * Gets the value of the value property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getValue() {
+        return value;
+    }
 
-  /**
-   * Sets the value of the value property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setValue(String value)
-  {
-    this.value = value;
-  }
+    /**
+     * Sets the value of the value property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setValue(String value) {
+        this.value = value;
+    }
 
-  /**
-   * Gets the value of the by property.
-   * 
-   * @return possible object is {@link FilterBy }
-   * 
-   */
-  public FilterBy getBy()
-  {
-    return by;
-  }
+    /**
+     * Gets the value of the by property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link FilterBy }
+     *     
+     */
+    public FilterBy getBy() {
+        return by;
+    }
 
-  /**
-   * Sets the value of the by property.
-   * 
-   * @param value
-   *          allowed object is {@link FilterBy }
-   * 
-   */
-  public void setBy(FilterBy value)
-  {
-    this.by = value;
-  }
+    /**
+     * Sets the value of the by property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link FilterBy }
+     *     
+     */
+    public void setBy(FilterBy value) {
+        this.by = value;
+    }
 
 }
index 45077af..a51e7d5 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -15,187 +16,177 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
  * A feature match condition, which may be simple or compound
  * 
- * <p>
- * Java class for FeatureMatcherSet complex type.
+ * &lt;p&gt;Java class for FeatureMatcherSet complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="FeatureMatcherSet">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;element name="matchCondition" type="{www.jalview.org/colours}FeatureMatcher"/>
- *         &lt;element name="compoundMatcher">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;sequence>
- *                   &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" maxOccurs="2" minOccurs="2"/>
- *                 &lt;/sequence>
- *                 &lt;attribute name="and" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/choice>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="FeatureMatcherSet"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;choice&amp;gt;
+ *         &amp;lt;element name="matchCondition" type="{www.jalview.org/colours}FeatureMatcher"/&amp;gt;
+ *         &amp;lt;element name="compoundMatcher"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;sequence&amp;gt;
+ *                   &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" maxOccurs="2" minOccurs="2"/&amp;gt;
+ *                 &amp;lt;/sequence&amp;gt;
+ *                 &amp;lt;attribute name="and" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/choice&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "FeatureMatcherSet",
-  namespace = "www.jalview.org/colours",
-  propOrder =
-  { "matchCondition", "compoundMatcher" })
-public class FeatureMatcherSet
-{
-
-  @XmlElement(namespace = "")
-  protected FeatureMatcher matchCondition;
-
-  @XmlElement(namespace = "")
-  protected FeatureMatcherSet.CompoundMatcher compoundMatcher;
-
-  /**
-   * Gets the value of the matchCondition property.
-   * 
-   * @return possible object is {@link FeatureMatcher }
-   * 
-   */
-  public FeatureMatcher getMatchCondition()
-  {
-    return matchCondition;
-  }
-
-  /**
-   * Sets the value of the matchCondition property.
-   * 
-   * @param value
-   *          allowed object is {@link FeatureMatcher }
-   * 
-   */
-  public void setMatchCondition(FeatureMatcher value)
-  {
-    this.matchCondition = value;
-  }
-
-  /**
-   * Gets the value of the compoundMatcher property.
-   * 
-   * @return possible object is {@link FeatureMatcherSet.CompoundMatcher }
-   * 
-   */
-  public FeatureMatcherSet.CompoundMatcher getCompoundMatcher()
-  {
-    return compoundMatcher;
-  }
-
-  /**
-   * Sets the value of the compoundMatcher property.
-   * 
-   * @param value
-   *          allowed object is {@link FeatureMatcherSet.CompoundMatcher }
-   * 
-   */
-  public void setCompoundMatcher(FeatureMatcherSet.CompoundMatcher value)
-  {
-    this.compoundMatcher = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" maxOccurs="2" minOccurs="2"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="and" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "matcherSet" })
-  public static class CompoundMatcher
-  {
-
-    @XmlElement(namespace = "", required = true)
-    protected List<FeatureMatcherSet> matcherSet;
-
-    @XmlAttribute(name = "and", required = true)
-    protected boolean and;
+@XmlType(name = "FeatureMatcherSet", namespace = "www.jalview.org/colours", propOrder = {
+    "matchCondition",
+    "compoundMatcher"
+})
+public class FeatureMatcherSet {
+
+    @XmlElement(namespace = "")
+    protected FeatureMatcher matchCondition;
+    @XmlElement(namespace = "")
+    protected FeatureMatcherSet.CompoundMatcher compoundMatcher;
 
     /**
-     * Gets the value of the matcherSet property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the matcherSet property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getMatcherSet().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link FeatureMatcherSet }
+     * Gets the value of the matchCondition property.
      * 
+     * @return
+     *     possible object is
+     *     {@link FeatureMatcher }
+     *     
+     */
+    public FeatureMatcher getMatchCondition() {
+        return matchCondition;
+    }
+
+    /**
+     * Sets the value of the matchCondition property.
      * 
+     * @param value
+     *     allowed object is
+     *     {@link FeatureMatcher }
+     *     
      */
-    public List<FeatureMatcherSet> getMatcherSet()
-    {
-      if (matcherSet == null)
-      {
-        matcherSet = new ArrayList<FeatureMatcherSet>();
-      }
-      return this.matcherSet;
+    public void setMatchCondition(FeatureMatcher value) {
+        this.matchCondition = value;
     }
 
     /**
-     * Gets the value of the and property.
+     * Gets the value of the compoundMatcher property.
      * 
+     * @return
+     *     possible object is
+     *     {@link FeatureMatcherSet.CompoundMatcher }
+     *     
      */
-    public boolean isAnd()
-    {
-      return and;
+    public FeatureMatcherSet.CompoundMatcher getCompoundMatcher() {
+        return compoundMatcher;
     }
 
     /**
-     * Sets the value of the and property.
+     * Sets the value of the compoundMatcher property.
      * 
+     * @param value
+     *     allowed object is
+     *     {@link FeatureMatcherSet.CompoundMatcher }
+     *     
      */
-    public void setAnd(boolean value)
-    {
-      this.and = value;
+    public void setCompoundMatcher(FeatureMatcherSet.CompoundMatcher value) {
+        this.compoundMatcher = value;
     }
 
-  }
+
+    /**
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" maxOccurs="2" minOccurs="2"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="and" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
+     * 
+     */
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "matcherSet"
+    })
+    public static class CompoundMatcher {
+
+        @XmlElement(namespace = "", required = true)
+        protected List<FeatureMatcherSet> matcherSet;
+        @XmlAttribute(name = "and", required = true)
+        protected boolean and;
+
+        /**
+         * Gets the value of the matcherSet property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the matcherSet property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getMatcherSet().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link FeatureMatcherSet }
+         * 
+         * 
+         */
+        public List<FeatureMatcherSet> getMatcherSet() {
+            if (matcherSet == null) {
+                matcherSet = new ArrayList<FeatureMatcherSet>();
+            }
+            return this.matcherSet;
+        }
+
+        /**
+         * Gets the value of the and property.
+         * 
+         */
+        public boolean isAnd() {
+            return and;
+        }
+
+        /**
+         * Sets the value of the and property.
+         * 
+         */
+        public void setAnd(boolean value) {
+            this.and = value;
+        }
+
+    }
 
 }
index 76fc6cd..5723e3d 100644 (file)
@@ -1,68 +1,60 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlEnum;
 import javax.xml.bind.annotation.XmlEnumValue;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for FilterBy.
+ * &lt;p&gt;Java class for FilterBy.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p>
- * 
- * <pre>
- * &lt;simpleType name="FilterBy">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
- *     &lt;enumeration value="byLabel"/>
- *     &lt;enumeration value="byScore"/>
- *     &lt;enumeration value="byAttribute"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+ * &lt;pre&gt;
+ * &amp;lt;simpleType name="FilterBy"&amp;gt;
+ *   &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}string"&amp;gt;
+ *     &amp;lt;enumeration value="byLabel"/&amp;gt;
+ *     &amp;lt;enumeration value="byScore"/&amp;gt;
+ *     &amp;lt;enumeration value="byAttribute"/&amp;gt;
+ *   &amp;lt;/restriction&amp;gt;
+ * &amp;lt;/simpleType&amp;gt;
+ * &lt;/pre&gt;
  * 
  */
 @XmlType(name = "FilterBy", namespace = "www.jalview.org/colours")
 @XmlEnum
-public enum FilterBy
-{
-
-  @XmlEnumValue("byLabel")
-  BY_LABEL("byLabel"), @XmlEnumValue("byScore")
-  BY_SCORE("byScore"), @XmlEnumValue("byAttribute")
-  BY_ATTRIBUTE("byAttribute");
-
-  private final String value;
-
-  FilterBy(String v)
-  {
-    value = v;
-  }
+public enum FilterBy {
+
+    @XmlEnumValue("byLabel")
+    BY_LABEL("byLabel"),
+    @XmlEnumValue("byScore")
+    BY_SCORE("byScore"),
+    @XmlEnumValue("byAttribute")
+    BY_ATTRIBUTE("byAttribute");
+    private final String value;
+
+    FilterBy(String v) {
+        value = v;
+    }
 
-  public String value()
-  {
-    return value;
-  }
+    public String value() {
+        return value;
+    }
 
-  public static FilterBy fromValue(String v)
-  {
-    for (FilterBy c : FilterBy.values())
-    {
-      if (c.value.equals(v))
-      {
-        return c;
-      }
+    public static FilterBy fromValue(String v) {
+        for (FilterBy c: FilterBy.values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v);
     }
-    throw new IllegalArgumentException(v);
-  }
 
 }
index 94f9373..360c074 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -21,6968 +22,6849 @@ import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
 import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
 import javax.xml.datatype.XMLGregorianCalendar;
 
+
 /**
- * <p>
- * Java class for JalviewModel complex type.
+ * &lt;p&gt;Java class for JalviewModel complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="JalviewModel">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="creationDate" type="{http://www.w3.org/2001/XMLSchema}dateTime"/>
- *         &lt;element name="version" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *         &lt;element name="vamsasModel" type="{www.vamsas.ac.uk/jalview/version2}VAMSAS"/>
- *         &lt;sequence>
- *           &lt;element name="JSeq" maxOccurs="unbounded" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence>
- *                     &lt;element name="features" type="{www.jalview.org}feature" maxOccurs="unbounded" minOccurs="0"/>
- *                     &lt;element name="pdbids" maxOccurs="unbounded" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;extension base="{www.jalview.org}pdbentry">
- *                             &lt;sequence>
- *                               &lt;element name="structureState" maxOccurs="unbounded" minOccurs="0">
- *                                 &lt;complexType>
- *                                   &lt;simpleContent>
- *                                     &lt;extension base="&lt;http://www.w3.org/2001/XMLSchema>string">
- *                                       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
- *                                       &lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                                       &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                                       &lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                                       &lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                                       &lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                                       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                                     &lt;/extension>
- *                                   &lt;/simpleContent>
- *                                 &lt;/complexType>
- *                               &lt;/element>
- *                             &lt;/sequence>
- *                           &lt;/extension>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="hiddenSequences" type="{http://www.w3.org/2001/XMLSchema}int" maxOccurs="unbounded" minOccurs="0"/>
- *                     &lt;element name="rnaViewer" maxOccurs="unbounded" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;sequence>
- *                               &lt;element name="secondaryStructure" maxOccurs="unbounded">
- *                                 &lt;complexType>
- *                                   &lt;complexContent>
- *                                     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                                       &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                                       &lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                                       &lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                                       &lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                                     &lt;/restriction>
- *                                   &lt;/complexContent>
- *                                 &lt;/complexType>
- *                               &lt;/element>
- *                             &lt;/sequence>
- *                             &lt;attGroup ref="{www.jalview.org}swingwindow"/>
- *                             &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                             &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                             &lt;attribute name="dividerLocation" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="selectedRna" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                   &lt;/sequence>
- *                   &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="hidden" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="viewreference" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *           &lt;element name="JGroup" maxOccurs="unbounded" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence>
- *                     &lt;element name="seq" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
- *                     &lt;element name="annotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/>
- *                   &lt;/sequence>
- *                   &lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="outlineColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="displayBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="displayText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="colourText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *           &lt;element name="Viewport" maxOccurs="unbounded" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence>
- *                     &lt;element name="AnnotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/>
- *                     &lt;element name="hiddenColumns" maxOccurs="unbounded" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="calcIdParam" maxOccurs="unbounded" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;extension base="{www.jalview.org/xml/wsparamset}WebServiceParameterSet">
- *                             &lt;attribute name="calcId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                             &lt;attribute name="needsUpdate" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                             &lt;attribute name="autoUpdate" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                           &lt;/extension>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="overview" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attGroup ref="{www.jalview.org}swingwindow"/>
- *                             &lt;attribute name="showHidden" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                             &lt;attribute name="residueColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="gapColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="hiddenColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                   &lt;/sequence>
- *                   &lt;attGroup ref="{www.jalview.org}swingwindow"/>
- *                   &lt;attribute name="conservationSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="pidSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="showFullId" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="rightAlignIds" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showColourText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="showBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="wrapAlignment" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="renderGaps" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showSequenceFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showNPfeatureTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showDbRefTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="followHighlight" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="followSelection" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="showAnnotation" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="centreColumnLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="showGroupConservation" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="showGroupConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="startRes" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="startSeq" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="charWidth" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="charHeight" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="scaleProteinAsCdna" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
- *                   &lt;attribute name="viewName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="sequenceSetId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="gatheredViews" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
- *                   &lt;attribute name="complementId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="showComplementFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="showComplementFeaturesOnTop" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *           &lt;element name="UserColours" maxOccurs="unbounded" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence>
- *                     &lt;element name="UserColourScheme" type="{www.jalview.org/colours}JalviewUserColours"/>
- *                   &lt;/sequence>
- *                   &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *           &lt;element name="tree" maxOccurs="unbounded" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence minOccurs="0">
- *                     &lt;element name="title" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *                     &lt;element name="newick" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *                   &lt;/sequence>
- *                   &lt;attGroup ref="{www.jalview.org}swingwindow"/>
- *                   &lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                   &lt;attribute name="showBootstrap" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="showDistances" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="markUnlinked" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="fitToWindow" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="currentTree" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="columnWise" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                   &lt;attribute name="columnReference" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
- *                   &lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *           &lt;element name="PcaViewer" maxOccurs="unbounded" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence>
- *                     &lt;element name="sequencePoint" maxOccurs="unbounded">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attGroup ref="{www.jalview.org}position"/>
- *                             &lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="axis" maxOccurs="3" minOccurs="3">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attGroup ref="{www.jalview.org}position"/>
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="seqPointMin">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attGroup ref="{www.jalview.org}position"/>
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="seqPointMax">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attGroup ref="{www.jalview.org}position"/>
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="pcaData" type="{www.jalview.org}PcaDataType"/>
- *                   &lt;/sequence>
- *                   &lt;attGroup ref="{www.jalview.org}SimilarityParams"/>
- *                   &lt;attGroup ref="{www.jalview.org}swingwindow"/>
- *                   &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="scoreModelName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                   &lt;attribute name="xDim" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="yDim" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="zDim" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                   &lt;attribute name="scaleFactor" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                   &lt;attribute name="showLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                   &lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *           &lt;element name="FeatureSettings" minOccurs="0">
- *             &lt;complexType>
- *               &lt;complexContent>
- *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                   &lt;sequence>
- *                     &lt;element name="setting" maxOccurs="unbounded" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;sequence>
- *                               &lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/>
- *                               &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" minOccurs="0"/>
- *                             &lt;/sequence>
- *                             &lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                             &lt;attribute name="colour" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                             &lt;attribute name="order" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                             &lt;attribute name="mincolour" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" />
- *                             &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                             &lt;attribute name="threshstate" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                             &lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                             &lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                             &lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                             &lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                     &lt;element name="group" maxOccurs="unbounded" minOccurs="0">
- *                       &lt;complexType>
- *                         &lt;complexContent>
- *                           &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                             &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                             &lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                           &lt;/restriction>
- *                         &lt;/complexContent>
- *                       &lt;/complexType>
- *                     &lt;/element>
- *                   &lt;/sequence>
- *                 &lt;/restriction>
- *               &lt;/complexContent>
- *             &lt;/complexType>
- *           &lt;/element>
- *         &lt;/sequence>
- *       &lt;/sequence>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="JalviewModel"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="creationDate" type="{http://www.w3.org/2001/XMLSchema}dateTime"/&amp;gt;
+ *         &amp;lt;element name="version" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *         &amp;lt;element name="vamsasModel" type="{www.vamsas.ac.uk/jalview/version2}VAMSAS"/&amp;gt;
+ *         &amp;lt;sequence&amp;gt;
+ *           &amp;lt;element name="JSeq" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence&amp;gt;
+ *                     &amp;lt;element name="features" type="{www.jalview.org}feature" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *                     &amp;lt;element name="pdbids" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;extension base="{www.jalview.org}pdbentry"&amp;gt;
+ *                             &amp;lt;sequence&amp;gt;
+ *                               &amp;lt;element name="structureState" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                                 &amp;lt;complexType&amp;gt;
+ *                                   &amp;lt;simpleContent&amp;gt;
+ *                                     &amp;lt;extension base="&amp;lt;http://www.w3.org/2001/XMLSchema&amp;gt;string"&amp;gt;
+ *                                       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+ *                                       &amp;lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                                       &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                                       &amp;lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                                       &amp;lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                                       &amp;lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                                       &amp;lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                                     &amp;lt;/extension&amp;gt;
+ *                                   &amp;lt;/simpleContent&amp;gt;
+ *                                 &amp;lt;/complexType&amp;gt;
+ *                               &amp;lt;/element&amp;gt;
+ *                             &amp;lt;/sequence&amp;gt;
+ *                           &amp;lt;/extension&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="hiddenSequences" type="{http://www.w3.org/2001/XMLSchema}int" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *                     &amp;lt;element name="rnaViewer" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;sequence&amp;gt;
+ *                               &amp;lt;element name="secondaryStructure" maxOccurs="unbounded"&amp;gt;
+ *                                 &amp;lt;complexType&amp;gt;
+ *                                   &amp;lt;complexContent&amp;gt;
+ *                                     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                                       &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                                       &amp;lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                                       &amp;lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                                       &amp;lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                                     &amp;lt;/restriction&amp;gt;
+ *                                   &amp;lt;/complexContent&amp;gt;
+ *                                 &amp;lt;/complexType&amp;gt;
+ *                               &amp;lt;/element&amp;gt;
+ *                             &amp;lt;/sequence&amp;gt;
+ *                             &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+ *                             &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                             &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                             &amp;lt;attribute name="dividerLocation" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="selectedRna" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                   &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="hidden" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="viewreference" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *           &amp;lt;element name="JGroup" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence&amp;gt;
+ *                     &amp;lt;element name="seq" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/&amp;gt;
+ *                     &amp;lt;element name="annotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                   &amp;lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="outlineColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="displayBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="displayText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="colourText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *           &amp;lt;element name="Viewport" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence&amp;gt;
+ *                     &amp;lt;element name="AnnotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/&amp;gt;
+ *                     &amp;lt;element name="hiddenColumns" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="calcIdParam" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;extension base="{www.jalview.org/xml/wsparamset}WebServiceParameterSet"&amp;gt;
+ *                             &amp;lt;attribute name="calcId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                             &amp;lt;attribute name="needsUpdate" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                             &amp;lt;attribute name="autoUpdate" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                           &amp;lt;/extension&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="overview" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+ *                             &amp;lt;attribute name="showHidden" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                             &amp;lt;attribute name="residueColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="gapColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="hiddenColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                   &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+ *                   &amp;lt;attribute name="conservationSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="pidSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="showFullId" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="rightAlignIds" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showColourText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="showBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="wrapAlignment" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="renderGaps" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showSequenceFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showNPfeatureTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showDbRefTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="followHighlight" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="followSelection" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="showAnnotation" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="centreColumnLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="showGroupConservation" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="showGroupConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="startRes" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="startSeq" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="charWidth" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="charHeight" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="idWidth" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="idWidthManuallyAdjusted" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="scaleProteinAsCdna" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+ *                   &amp;lt;attribute name="viewName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="sequenceSetId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="gatheredViews" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" /&amp;gt;
+ *                   &amp;lt;attribute name="complementId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="showComplementFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="showComplementFeaturesOnTop" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *           &amp;lt;element name="UserColours" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence&amp;gt;
+ *                     &amp;lt;element name="UserColourScheme" type="{www.jalview.org/colours}JalviewUserColours"/&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                   &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *           &amp;lt;element name="tree" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence minOccurs="0"&amp;gt;
+ *                     &amp;lt;element name="title" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *                     &amp;lt;element name="newick" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                   &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+ *                   &amp;lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                   &amp;lt;attribute name="showBootstrap" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="showDistances" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="markUnlinked" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="fitToWindow" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="currentTree" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="columnWise" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                   &amp;lt;attribute name="columnReference" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" /&amp;gt;
+ *                   &amp;lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *           &amp;lt;element name="PcaViewer" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence&amp;gt;
+ *                     &amp;lt;element name="sequencePoint" maxOccurs="unbounded"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+ *                             &amp;lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="axis" maxOccurs="3" minOccurs="3"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="seqPointMin"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="seqPointMax"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="pcaData" type="{www.jalview.org}PcaDataType"/&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                   &amp;lt;attGroup ref="{www.jalview.org}SimilarityParams"/&amp;gt;
+ *                   &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+ *                   &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="scoreModelName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                   &amp;lt;attribute name="xDim" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="yDim" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="zDim" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                   &amp;lt;attribute name="scaleFactor" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                   &amp;lt;attribute name="showLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                   &amp;lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *           &amp;lt;element name="FeatureSettings" minOccurs="0"&amp;gt;
+ *             &amp;lt;complexType&amp;gt;
+ *               &amp;lt;complexContent&amp;gt;
+ *                 &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                   &amp;lt;sequence&amp;gt;
+ *                     &amp;lt;element name="setting" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;sequence&amp;gt;
+ *                               &amp;lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/&amp;gt;
+ *                               &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" minOccurs="0"/&amp;gt;
+ *                             &amp;lt;/sequence&amp;gt;
+ *                             &amp;lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                             &amp;lt;attribute name="colour" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                             &amp;lt;attribute name="order" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                             &amp;lt;attribute name="mincolour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" /&amp;gt;
+ *                             &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                             &amp;lt;attribute name="threshstate" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                             &amp;lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                             &amp;lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                             &amp;lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                             &amp;lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                     &amp;lt;element name="group" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *                       &amp;lt;complexType&amp;gt;
+ *                         &amp;lt;complexContent&amp;gt;
+ *                           &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                             &amp;lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                             &amp;lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                           &amp;lt;/restriction&amp;gt;
+ *                         &amp;lt;/complexContent&amp;gt;
+ *                       &amp;lt;/complexType&amp;gt;
+ *                     &amp;lt;/element&amp;gt;
+ *                   &amp;lt;/sequence&amp;gt;
+ *                 &amp;lt;/restriction&amp;gt;
+ *               &amp;lt;/complexContent&amp;gt;
+ *             &amp;lt;/complexType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *         &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "JalviewModel",
-  namespace = "www.jalview.org",
-  propOrder =
-  { "creationDate", "version", "vamsasModel", "jSeq", "jGroup", "viewport",
-      "userColours", "tree", "pcaViewer", "featureSettings" })
-public class JalviewModel
-{
-
-  @XmlElement(required = true)
-  @XmlSchemaType(name = "dateTime")
-  protected XMLGregorianCalendar creationDate;
-
-  @XmlElement(required = true)
-  protected String version;
-
-  @XmlElement(required = true)
-  protected VAMSAS vamsasModel;
-
-  @XmlElement(name = "JSeq")
-  protected List<JalviewModel.JSeq> jSeq;
-
-  @XmlElement(name = "JGroup")
-  protected List<JalviewModel.JGroup> jGroup;
-
-  @XmlElement(name = "Viewport")
-  protected List<JalviewModel.Viewport> viewport;
-
-  @XmlElement(name = "UserColours")
-  protected List<JalviewModel.UserColours> userColours;
-
-  protected List<JalviewModel.Tree> tree;
-
-  @XmlElement(name = "PcaViewer")
-  protected List<JalviewModel.PcaViewer> pcaViewer;
-
-  @XmlElement(name = "FeatureSettings")
-  protected JalviewModel.FeatureSettings featureSettings;
-
-  /**
-   * Gets the value of the creationDate property.
-   * 
-   * @return possible object is {@link XMLGregorianCalendar }
-   * 
-   */
-  public XMLGregorianCalendar getCreationDate()
-  {
-    return creationDate;
-  }
-
-  /**
-   * Sets the value of the creationDate property.
-   * 
-   * @param value
-   *          allowed object is {@link XMLGregorianCalendar }
-   * 
-   */
-  public void setCreationDate(XMLGregorianCalendar value)
-  {
-    this.creationDate = value;
-  }
-
-  /**
-   * Gets the value of the version property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getVersion()
-  {
-    return version;
-  }
-
-  /**
-   * Sets the value of the version property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setVersion(String value)
-  {
-    this.version = value;
-  }
-
-  /**
-   * Gets the value of the vamsasModel property.
-   * 
-   * @return possible object is {@link VAMSAS }
-   * 
-   */
-  public VAMSAS getVamsasModel()
-  {
-    return vamsasModel;
-  }
-
-  /**
-   * Sets the value of the vamsasModel property.
-   * 
-   * @param value
-   *          allowed object is {@link VAMSAS }
-   * 
-   */
-  public void setVamsasModel(VAMSAS value)
-  {
-    this.vamsasModel = value;
-  }
-
-  /**
-   * Gets the value of the jSeq property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the jSeq property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getJSeq().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewModel.JSeq }
-   * 
-   * 
-   */
-  public List<JalviewModel.JSeq> getJSeq()
-  {
-    if (jSeq == null)
-    {
-      jSeq = new ArrayList<JalviewModel.JSeq>();
-    }
-    return this.jSeq;
-  }
-
-  /**
-   * Gets the value of the jGroup property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the jGroup property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getJGroup().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewModel.JGroup }
-   * 
-   * 
-   */
-  public List<JalviewModel.JGroup> getJGroup()
-  {
-    if (jGroup == null)
-    {
-      jGroup = new ArrayList<JalviewModel.JGroup>();
-    }
-    return this.jGroup;
-  }
-
-  /**
-   * Gets the value of the viewport property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the viewport property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getViewport().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewModel.Viewport }
-   * 
-   * 
-   */
-  public List<JalviewModel.Viewport> getViewport()
-  {
-    if (viewport == null)
-    {
-      viewport = new ArrayList<JalviewModel.Viewport>();
-    }
-    return this.viewport;
-  }
-
-  /**
-   * Gets the value of the userColours property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the userColours property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getUserColours().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewModel.UserColours }
-   * 
-   * 
-   */
-  public List<JalviewModel.UserColours> getUserColours()
-  {
-    if (userColours == null)
-    {
-      userColours = new ArrayList<JalviewModel.UserColours>();
-    }
-    return this.userColours;
-  }
-
-  /**
-   * Gets the value of the tree property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the tree property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getTree().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewModel.Tree }
-   * 
-   * 
-   */
-  public List<JalviewModel.Tree> getTree()
-  {
-    if (tree == null)
-    {
-      tree = new ArrayList<JalviewModel.Tree>();
-    }
-    return this.tree;
-  }
-
-  /**
-   * Gets the value of the pcaViewer property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the pcaViewer property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getPcaViewer().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewModel.PcaViewer }
-   * 
-   * 
-   */
-  public List<JalviewModel.PcaViewer> getPcaViewer()
-  {
-    if (pcaViewer == null)
-    {
-      pcaViewer = new ArrayList<JalviewModel.PcaViewer>();
-    }
-    return this.pcaViewer;
-  }
-
-  /**
-   * Gets the value of the featureSettings property.
-   * 
-   * @return possible object is {@link JalviewModel.FeatureSettings }
-   * 
-   */
-  public JalviewModel.FeatureSettings getFeatureSettings()
-  {
-    return featureSettings;
-  }
-
-  /**
-   * Sets the value of the featureSettings property.
-   * 
-   * @param value
-   *          allowed object is {@link JalviewModel.FeatureSettings }
-   * 
-   */
-  public void setFeatureSettings(JalviewModel.FeatureSettings value)
-  {
-    this.featureSettings = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="setting" maxOccurs="unbounded" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;sequence>
-   *                   &lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/>
-   *                   &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" minOccurs="0"/>
-   *                 &lt;/sequence>
-   *                 &lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                 &lt;attribute name="colour" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *                 &lt;attribute name="order" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *                 &lt;attribute name="mincolour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" />
-   *                 &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *                 &lt;attribute name="threshstate" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *                 &lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *                 &lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *                 &lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="group" maxOccurs="unbounded" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                 &lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *       &lt;/sequence>
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "setting", "group" })
-  public static class FeatureSettings
-  {
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<JalviewModel.FeatureSettings.Setting> setting;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<JalviewModel.FeatureSettings.Group> group;
-
-    /**
-     * Gets the value of the setting property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the setting property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getSetting().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.FeatureSettings.Setting }
-     * 
-     * 
-     */
-    public List<JalviewModel.FeatureSettings.Setting> getSetting()
-    {
-      if (setting == null)
-      {
-        setting = new ArrayList<JalviewModel.FeatureSettings.Setting>();
-      }
-      return this.setting;
-    }
-
-    /**
-     * Gets the value of the group property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the group property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getGroup().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.FeatureSettings.Group }
-     * 
-     * 
-     */
-    public List<JalviewModel.FeatureSettings.Group> getGroup()
-    {
-      if (group == null)
-      {
-        group = new ArrayList<JalviewModel.FeatureSettings.Group>();
-      }
-      return this.group;
-    }
-
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *       &lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class Group
-    {
-
-      @XmlAttribute(name = "name", required = true)
-      protected String name;
-
-      @XmlAttribute(name = "display", required = true)
-      protected boolean display;
-
-      /**
-       * Gets the value of the name property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getName()
-      {
-        return name;
-      }
-
-      /**
-       * Sets the value of the name property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setName(String value)
-      {
-        this.name = value;
-      }
-
-      /**
-       * Gets the value of the display property.
-       * 
-       */
-      public boolean isDisplay()
-      {
-        return display;
-      }
-
-      /**
-       * Sets the value of the display property.
-       * 
-       */
-      public void setDisplay(boolean value)
-      {
-        this.display = value;
-      }
-
-    }
-
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;sequence>
-     *         &lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/>
-     *         &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" minOccurs="0"/>
-     *       &lt;/sequence>
-     *       &lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *       &lt;attribute name="colour" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *       &lt;attribute name="order" type="{http://www.w3.org/2001/XMLSchema}float" />
-     *       &lt;attribute name="mincolour" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" />
-     *       &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
-     *       &lt;attribute name="threshstate" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" />
-     *       &lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" />
-     *       &lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *       &lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "", propOrder = { "attributeName", "matcherSet" })
-    public static class Setting
-    {
-
-      @XmlElement(namespace = "www.jalview.org")
-      protected List<String> attributeName;
-
-      @XmlElement(namespace = "www.jalview.org")
-      protected FeatureMatcherSet matcherSet;
-
-      @XmlAttribute(name = "type", required = true)
-      protected String type;
-
-      @XmlAttribute(name = "colour", required = true)
-      protected int colour;
-
-      @XmlAttribute(name = "display", required = true)
-      protected boolean display;
-
-      @XmlAttribute(name = "order")
-      protected Float order;
-
-      @XmlAttribute(name = "mincolour")
-      protected Integer mincolour;
-
-      @XmlAttribute(name = "noValueColour")
-      protected NoValueColour noValueColour;
-
-      @XmlAttribute(name = "threshold")
-      protected Float threshold;
-
-      @XmlAttribute(name = "threshstate")
-      protected Integer threshstate;
-
-      @XmlAttribute(name = "max")
-      protected Float max;
-
-      @XmlAttribute(name = "min")
-      protected Float min;
-
-      @XmlAttribute(name = "colourByLabel")
-      protected Boolean colourByLabel;
-
-      @XmlAttribute(name = "autoScale")
-      protected Boolean autoScale;
-
-      /**
-       * Gets the value of the attributeName property.
-       * 
-       * <p>
-       * This accessor method returns a reference to the live list, not a
-       * snapshot. Therefore any modification you make to the returned list will
-       * be present inside the JAXB object. This is why there is not a
-       * <CODE>set</CODE> method for the attributeName property.
-       * 
-       * <p>
-       * For example, to add a new item, do as follows:
-       * 
-       * <pre>
-       * getAttributeName().add(newItem);
-       * </pre>
-       * 
-       * 
-       * <p>
-       * Objects of the following type(s) are allowed in the list {@link String
-       * }
-       * 
-       * 
-       */
-      public List<String> getAttributeName()
-      {
-        if (attributeName == null)
-        {
-          attributeName = new ArrayList<String>();
-        }
-        return this.attributeName;
-      }
-
-      /**
-       * Gets the value of the matcherSet property.
-       * 
-       * @return possible object is {@link FeatureMatcherSet }
-       * 
-       */
-      public FeatureMatcherSet getMatcherSet()
-      {
-        return matcherSet;
-      }
-
-      /**
-       * Sets the value of the matcherSet property.
-       * 
-       * @param value
-       *          allowed object is {@link FeatureMatcherSet }
-       * 
-       */
-      public void setMatcherSet(FeatureMatcherSet value)
-      {
-        this.matcherSet = value;
-      }
-
-      /**
-       * Gets the value of the type property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getType()
-      {
-        return type;
-      }
-
-      /**
-       * Sets the value of the type property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setType(String value)
-      {
-        this.type = value;
-      }
-
-      /**
-       * Gets the value of the colour property.
-       * 
-       */
-      public int getColour()
-      {
-        return colour;
-      }
-
-      /**
-       * Sets the value of the colour property.
-       * 
-       */
-      public void setColour(int value)
-      {
-        this.colour = value;
-      }
-
-      /**
-       * Gets the value of the display property.
-       * 
-       */
-      public boolean isDisplay()
-      {
-        return display;
-      }
-
-      /**
-       * Sets the value of the display property.
-       * 
-       */
-      public void setDisplay(boolean value)
-      {
-        this.display = value;
-      }
-
-      /**
-       * Gets the value of the order property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getOrder()
-      {
-        return order;
-      }
-
-      /**
-       * Sets the value of the order property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setOrder(Float value)
-      {
-        this.order = value;
-      }
-
-      /**
-       * Gets the value of the mincolour property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getMincolour()
-      {
-        return mincolour;
-      }
-
-      /**
-       * Sets the value of the mincolour property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setMincolour(Integer value)
-      {
-        this.mincolour = value;
-      }
-
-      /**
-       * Gets the value of the noValueColour property.
-       * 
-       * @return possible object is {@link NoValueColour }
-       * 
-       */
-      public NoValueColour getNoValueColour()
-      {
-        if (noValueColour == null)
-        {
-          return NoValueColour.MIN;
-        }
-        else
-        {
-          return noValueColour;
-        }
-      }
-
-      /**
-       * Sets the value of the noValueColour property.
-       * 
-       * @param value
-       *          allowed object is {@link NoValueColour }
-       * 
-       */
-      public void setNoValueColour(NoValueColour value)
-      {
-        this.noValueColour = value;
-      }
-
-      /**
-       * Gets the value of the threshold property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getThreshold()
-      {
-        return threshold;
-      }
-
-      /**
-       * Sets the value of the threshold property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setThreshold(Float value)
-      {
-        this.threshold = value;
-      }
-
-      /**
-       * Gets the value of the threshstate property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getThreshstate()
-      {
-        return threshstate;
-      }
-
-      /**
-       * Sets the value of the threshstate property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setThreshstate(Integer value)
-      {
-        this.threshstate = value;
-      }
-
-      /**
-       * Gets the value of the max property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getMax()
-      {
-        return max;
-      }
-
-      /**
-       * Sets the value of the max property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setMax(Float value)
-      {
-        this.max = value;
-      }
-
-      /**
-       * Gets the value of the min property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getMin()
-      {
-        return min;
-      }
-
-      /**
-       * Sets the value of the min property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setMin(Float value)
-      {
-        this.min = value;
-      }
-
-      /**
-       * Gets the value of the colourByLabel property.
-       * 
-       * @return possible object is {@link Boolean }
-       * 
-       */
-      public Boolean isColourByLabel()
-      {
-        return colourByLabel;
-      }
-
-      /**
-       * Sets the value of the colourByLabel property.
-       * 
-       * @param value
-       *          allowed object is {@link Boolean }
-       * 
-       */
-      public void setColourByLabel(Boolean value)
-      {
-        this.colourByLabel = value;
-      }
-
-      /**
-       * Gets the value of the autoScale property.
-       * 
-       * @return possible object is {@link Boolean }
-       * 
-       */
-      public Boolean isAutoScale()
-      {
-        return autoScale;
-      }
-
-      /**
-       * Sets the value of the autoScale property.
-       * 
-       * @param value
-       *          allowed object is {@link Boolean }
-       * 
-       */
-      public void setAutoScale(Boolean value)
-      {
-        this.autoScale = value;
-      }
-
-    }
-
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="seq" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
-   *         &lt;element name="annotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="outlineColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="displayBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="displayText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="colourText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "seq", "annotationColours" })
-  public static class JGroup
-  {
-
-    @XmlElement(namespace = "www.jalview.org", required = true)
-    protected List<String> seq;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected AnnotationColourScheme annotationColours;
-
-    @XmlAttribute(name = "start")
-    protected Integer start;
-
-    @XmlAttribute(name = "end")
-    protected Integer end;
-
-    @XmlAttribute(name = "name")
-    protected String name;
-
-    @XmlAttribute(name = "colour")
-    protected String colour;
-
-    @XmlAttribute(name = "consThreshold")
-    protected Integer consThreshold;
-
-    @XmlAttribute(name = "pidThreshold")
-    protected Integer pidThreshold;
-
-    @XmlAttribute(name = "outlineColour")
-    protected Integer outlineColour;
-
-    @XmlAttribute(name = "displayBoxes")
-    protected Boolean displayBoxes;
-
-    @XmlAttribute(name = "displayText")
-    protected Boolean displayText;
-
-    @XmlAttribute(name = "colourText")
-    protected Boolean colourText;
-
-    @XmlAttribute(name = "textCol1")
-    protected Integer textCol1;
-
-    @XmlAttribute(name = "textCol2")
-    protected Integer textCol2;
-
-    @XmlAttribute(name = "textColThreshold")
-    protected Integer textColThreshold;
-
-    @XmlAttribute(name = "showUnconserved")
-    protected Boolean showUnconserved;
-
-    @XmlAttribute(name = "ignoreGapsinConsensus")
-    protected Boolean ignoreGapsinConsensus;
-
-    @XmlAttribute(name = "showConsensusHistogram")
-    protected Boolean showConsensusHistogram;
-
-    @XmlAttribute(name = "showSequenceLogo")
-    protected Boolean showSequenceLogo;
-
-    @XmlAttribute(name = "normaliseSequenceLogo")
-    protected Boolean normaliseSequenceLogo;
-
-    @XmlAttribute(name = "id")
-    protected String id;
-
-    /**
-     * Gets the value of the seq property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the seq property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getSeq().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list {@link String }
-     * 
+@XmlType(name = "JalviewModel", namespace = "www.jalview.org", propOrder = {
+    "creationDate",
+    "version",
+    "vamsasModel",
+    "jSeq",
+    "jGroup",
+    "viewport",
+    "userColours",
+    "tree",
+    "pcaViewer",
+    "featureSettings"
+})
+public class JalviewModel {
+
+    @XmlElement(required = true)
+    @XmlSchemaType(name = "dateTime")
+    protected XMLGregorianCalendar creationDate;
+    @XmlElement(required = true)
+    protected String version;
+    @XmlElement(required = true)
+    protected VAMSAS vamsasModel;
+    @XmlElement(name = "JSeq")
+    protected List<JalviewModel.JSeq> jSeq;
+    @XmlElement(name = "JGroup")
+    protected List<JalviewModel.JGroup> jGroup;
+    @XmlElement(name = "Viewport")
+    protected List<JalviewModel.Viewport> viewport;
+    @XmlElement(name = "UserColours")
+    protected List<JalviewModel.UserColours> userColours;
+    protected List<JalviewModel.Tree> tree;
+    @XmlElement(name = "PcaViewer")
+    protected List<JalviewModel.PcaViewer> pcaViewer;
+    @XmlElement(name = "FeatureSettings")
+    protected JalviewModel.FeatureSettings featureSettings;
+
+    /**
+     * Gets the value of the creationDate property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link XMLGregorianCalendar }
+     *     
+     */
+    public XMLGregorianCalendar getCreationDate() {
+        return creationDate;
+    }
+
+    /**
+     * Sets the value of the creationDate property.
      * 
+     * @param value
+     *     allowed object is
+     *     {@link XMLGregorianCalendar }
+     *     
      */
-    public List<String> getSeq()
-    {
-      if (seq == null)
-      {
-        seq = new ArrayList<String>();
-      }
-      return this.seq;
+    public void setCreationDate(XMLGregorianCalendar value) {
+        this.creationDate = value;
     }
 
     /**
-     * Gets the value of the annotationColours property.
-     * 
-     * @return possible object is {@link AnnotationColourScheme }
+     * Gets the value of the version property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public AnnotationColourScheme getAnnotationColours()
-    {
-      return annotationColours;
+    public String getVersion() {
+        return version;
     }
 
     /**
-     * Sets the value of the annotationColours property.
+     * Sets the value of the version property.
      * 
      * @param value
-     *          allowed object is {@link AnnotationColourScheme }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public void setAnnotationColours(AnnotationColourScheme value)
-    {
-      this.annotationColours = value;
+    public void setVersion(String value) {
+        this.version = value;
     }
 
     /**
-     * Gets the value of the start property.
-     * 
-     * @return possible object is {@link Integer }
+     * Gets the value of the vamsasModel property.
      * 
+     * @return
+     *     possible object is
+     *     {@link VAMSAS }
+     *     
      */
-    public Integer getStart()
-    {
-      return start;
+    public VAMSAS getVamsasModel() {
+        return vamsasModel;
     }
 
     /**
-     * Sets the value of the start property.
+     * Sets the value of the vamsasModel property.
      * 
      * @param value
-     *          allowed object is {@link Integer }
-     * 
+     *     allowed object is
+     *     {@link VAMSAS }
+     *     
      */
-    public void setStart(Integer value)
-    {
-      this.start = value;
+    public void setVamsasModel(VAMSAS value) {
+        this.vamsasModel = value;
     }
 
     /**
-     * Gets the value of the end property.
+     * Gets the value of the jSeq property.
      * 
-     * @return possible object is {@link Integer }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the jSeq property.
      * 
-     */
-    public Integer getEnd()
-    {
-      return end;
-    }
-
-    /**
-     * Sets the value of the end property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getJSeq().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link Integer }
      * 
-     */
-    public void setEnd(Integer value)
-    {
-      this.end = value;
-    }
-
-    /**
-     * Gets the value of the name property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewModel.JSeq }
      * 
-     * @return possible object is {@link String }
      * 
      */
-    public String getName()
-    {
-      return name;
+    public List<JalviewModel.JSeq> getJSeq() {
+        if (jSeq == null) {
+            jSeq = new ArrayList<JalviewModel.JSeq>();
+        }
+        return this.jSeq;
     }
 
     /**
-     * Sets the value of the name property.
+     * Gets the value of the jGroup property.
      * 
-     * @param value
-     *          allowed object is {@link String }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the jGroup property.
      * 
-     */
-    public void setName(String value)
-    {
-      this.name = value;
-    }
-
-    /**
-     * Gets the value of the colour property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getJGroup().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link String }
      * 
-     */
-    public String getColour()
-    {
-      return colour;
-    }
-
-    /**
-     * Sets the value of the colour property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewModel.JGroup }
      * 
-     * @param value
-     *          allowed object is {@link String }
      * 
      */
-    public void setColour(String value)
-    {
-      this.colour = value;
+    public List<JalviewModel.JGroup> getJGroup() {
+        if (jGroup == null) {
+            jGroup = new ArrayList<JalviewModel.JGroup>();
+        }
+        return this.jGroup;
     }
 
     /**
-     * Gets the value of the consThreshold property.
+     * Gets the value of the viewport property.
      * 
-     * @return possible object is {@link Integer }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the viewport property.
      * 
-     */
-    public Integer getConsThreshold()
-    {
-      return consThreshold;
-    }
-
-    /**
-     * Sets the value of the consThreshold property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getViewport().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link Integer }
      * 
-     */
-    public void setConsThreshold(Integer value)
-    {
-      this.consThreshold = value;
-    }
-
-    /**
-     * Gets the value of the pidThreshold property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewModel.Viewport }
      * 
-     * @return possible object is {@link Integer }
      * 
      */
-    public Integer getPidThreshold()
-    {
-      return pidThreshold;
+    public List<JalviewModel.Viewport> getViewport() {
+        if (viewport == null) {
+            viewport = new ArrayList<JalviewModel.Viewport>();
+        }
+        return this.viewport;
     }
 
     /**
-     * Sets the value of the pidThreshold property.
+     * Gets the value of the userColours property.
      * 
-     * @param value
-     *          allowed object is {@link Integer }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the userColours property.
      * 
-     */
-    public void setPidThreshold(Integer value)
-    {
-      this.pidThreshold = value;
-    }
-
-    /**
-     * Gets the value of the outlineColour property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getUserColours().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Integer }
      * 
-     */
-    public Integer getOutlineColour()
-    {
-      return outlineColour;
-    }
-
-    /**
-     * Sets the value of the outlineColour property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewModel.UserColours }
      * 
-     * @param value
-     *          allowed object is {@link Integer }
      * 
      */
-    public void setOutlineColour(Integer value)
-    {
-      this.outlineColour = value;
+    public List<JalviewModel.UserColours> getUserColours() {
+        if (userColours == null) {
+            userColours = new ArrayList<JalviewModel.UserColours>();
+        }
+        return this.userColours;
     }
 
     /**
-     * Gets the value of the displayBoxes property.
+     * Gets the value of the tree property.
      * 
-     * @return possible object is {@link Boolean }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the tree property.
      * 
-     */
-    public Boolean isDisplayBoxes()
-    {
-      return displayBoxes;
-    }
-
-    /**
-     * Sets the value of the displayBoxes property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getTree().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link Boolean }
      * 
-     */
-    public void setDisplayBoxes(Boolean value)
-    {
-      this.displayBoxes = value;
-    }
-
-    /**
-     * Gets the value of the displayText property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewModel.Tree }
      * 
-     * @return possible object is {@link Boolean }
      * 
      */
-    public Boolean isDisplayText()
-    {
-      return displayText;
+    public List<JalviewModel.Tree> getTree() {
+        if (tree == null) {
+            tree = new ArrayList<JalviewModel.Tree>();
+        }
+        return this.tree;
     }
 
     /**
-     * Sets the value of the displayText property.
+     * Gets the value of the pcaViewer property.
      * 
-     * @param value
-     *          allowed object is {@link Boolean }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the pcaViewer property.
      * 
-     */
-    public void setDisplayText(Boolean value)
-    {
-      this.displayText = value;
-    }
-
-    /**
-     * Gets the value of the colourText property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getPcaViewer().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Boolean }
      * 
-     */
-    public Boolean isColourText()
-    {
-      return colourText;
-    }
-
-    /**
-     * Sets the value of the colourText property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewModel.PcaViewer }
      * 
-     * @param value
-     *          allowed object is {@link Boolean }
      * 
      */
-    public void setColourText(Boolean value)
-    {
-      this.colourText = value;
+    public List<JalviewModel.PcaViewer> getPcaViewer() {
+        if (pcaViewer == null) {
+            pcaViewer = new ArrayList<JalviewModel.PcaViewer>();
+        }
+        return this.pcaViewer;
     }
 
     /**
-     * Gets the value of the textCol1 property.
-     * 
-     * @return possible object is {@link Integer }
+     * Gets the value of the featureSettings property.
      * 
+     * @return
+     *     possible object is
+     *     {@link JalviewModel.FeatureSettings }
+     *     
      */
-    public Integer getTextCol1()
-    {
-      return textCol1;
+    public JalviewModel.FeatureSettings getFeatureSettings() {
+        return featureSettings;
     }
 
     /**
-     * Sets the value of the textCol1 property.
+     * Sets the value of the featureSettings property.
      * 
      * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setTextCol1(Integer value)
-    {
-      this.textCol1 = value;
-    }
-
-    /**
-     * Gets the value of the textCol2 property.
+     *     allowed object is
+     *     {@link JalviewModel.FeatureSettings }
+     *     
+     */
+    public void setFeatureSettings(JalviewModel.FeatureSettings value) {
+        this.featureSettings = value;
+    }
+
+
+    /**
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="setting" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;sequence&amp;gt;
+     *                   &amp;lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/&amp;gt;
+     *                   &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" minOccurs="0"/&amp;gt;
+     *                 &amp;lt;/sequence&amp;gt;
+     *                 &amp;lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                 &amp;lt;attribute name="colour" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *                 &amp;lt;attribute name="order" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *                 &amp;lt;attribute name="mincolour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" /&amp;gt;
+     *                 &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *                 &amp;lt;attribute name="threshstate" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *                 &amp;lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *                 &amp;lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *                 &amp;lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="group" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                 &amp;lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Integer }
      * 
      */
-    public Integer getTextCol2()
-    {
-      return textCol2;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "setting",
+        "group"
+    })
+    public static class FeatureSettings {
 
-    /**
-     * Sets the value of the textCol2 property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setTextCol2(Integer value)
-    {
-      this.textCol2 = value;
-    }
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<JalviewModel.FeatureSettings.Setting> setting;
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<JalviewModel.FeatureSettings.Group> group;
 
-    /**
-     * Gets the value of the textColThreshold property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getTextColThreshold()
-    {
-      return textColThreshold;
-    }
+        /**
+         * Gets the value of the setting property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the setting property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getSetting().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.FeatureSettings.Setting }
+         * 
+         * 
+         */
+        public List<JalviewModel.FeatureSettings.Setting> getSetting() {
+            if (setting == null) {
+                setting = new ArrayList<JalviewModel.FeatureSettings.Setting>();
+            }
+            return this.setting;
+        }
 
-    /**
-     * Sets the value of the textColThreshold property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setTextColThreshold(Integer value)
-    {
-      this.textColThreshold = value;
-    }
+        /**
+         * Gets the value of the group property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the group property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getGroup().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.FeatureSettings.Group }
+         * 
+         * 
+         */
+        public List<JalviewModel.FeatureSettings.Group> getGroup() {
+            if (group == null) {
+                group = new ArrayList<JalviewModel.FeatureSettings.Group>();
+            }
+            return this.group;
+        }
 
-    /**
-     * Gets the value of the showUnconserved property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowUnconserved()
-    {
-      return showUnconserved;
-    }
 
-    /**
-     * Sets the value of the showUnconserved property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowUnconserved(Boolean value)
-    {
-      this.showUnconserved = value;
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *       &amp;lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class Group {
+
+            @XmlAttribute(name = "name", required = true)
+            protected String name;
+            @XmlAttribute(name = "display", required = true)
+            protected boolean display;
+
+            /**
+             * Gets the value of the name property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getName() {
+                return name;
+            }
+
+            /**
+             * Sets the value of the name property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setName(String value) {
+                this.name = value;
+            }
+
+            /**
+             * Gets the value of the display property.
+             * 
+             */
+            public boolean isDisplay() {
+                return display;
+            }
+
+            /**
+             * Sets the value of the display property.
+             * 
+             */
+            public void setDisplay(boolean value) {
+                this.display = value;
+            }
 
-    /**
-     * Gets the value of the ignoreGapsinConsensus property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isIgnoreGapsinConsensus()
-    {
-      if (ignoreGapsinConsensus == null)
-      {
-        return true;
-      }
-      else
-      {
-        return ignoreGapsinConsensus;
-      }
-    }
+        }
 
-    /**
-     * Sets the value of the ignoreGapsinConsensus property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setIgnoreGapsinConsensus(Boolean value)
-    {
-      this.ignoreGapsinConsensus = value;
-    }
 
-    /**
-     * Gets the value of the showConsensusHistogram property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowConsensusHistogram()
-    {
-      if (showConsensusHistogram == null)
-      {
-        return true;
-      }
-      else
-      {
-        return showConsensusHistogram;
-      }
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;sequence&amp;gt;
+         *         &amp;lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/&amp;gt;
+         *         &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet" minOccurs="0"/&amp;gt;
+         *       &amp;lt;/sequence&amp;gt;
+         *       &amp;lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *       &amp;lt;attribute name="colour" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="display" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *       &amp;lt;attribute name="order" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+         *       &amp;lt;attribute name="mincolour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" /&amp;gt;
+         *       &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+         *       &amp;lt;attribute name="threshstate" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+         *       &amp;lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+         *       &amp;lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *       &amp;lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "", propOrder = {
+            "attributeName",
+            "matcherSet"
+        })
+        public static class Setting {
+
+            @XmlElement(namespace = "www.jalview.org")
+            protected List<String> attributeName;
+            @XmlElement(namespace = "www.jalview.org")
+            protected FeatureMatcherSet matcherSet;
+            @XmlAttribute(name = "type", required = true)
+            protected String type;
+            @XmlAttribute(name = "colour", required = true)
+            protected int colour;
+            @XmlAttribute(name = "display", required = true)
+            protected boolean display;
+            @XmlAttribute(name = "order")
+            protected Float order;
+            @XmlAttribute(name = "mincolour")
+            protected Integer mincolour;
+            @XmlAttribute(name = "noValueColour")
+            protected NoValueColour noValueColour;
+            @XmlAttribute(name = "threshold")
+            protected Float threshold;
+            @XmlAttribute(name = "threshstate")
+            protected Integer threshstate;
+            @XmlAttribute(name = "max")
+            protected Float max;
+            @XmlAttribute(name = "min")
+            protected Float min;
+            @XmlAttribute(name = "colourByLabel")
+            protected Boolean colourByLabel;
+            @XmlAttribute(name = "autoScale")
+            protected Boolean autoScale;
+
+            /**
+             * Gets the value of the attributeName property.
+             * 
+             * &lt;p&gt;
+             * This accessor method returns a reference to the live list,
+             * not a snapshot. Therefore any modification you make to the
+             * returned list will be present inside the JAXB object.
+             * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the attributeName property.
+             * 
+             * &lt;p&gt;
+             * For example, to add a new item, do as follows:
+             * &lt;pre&gt;
+             *    getAttributeName().add(newItem);
+             * &lt;/pre&gt;
+             * 
+             * 
+             * &lt;p&gt;
+             * Objects of the following type(s) are allowed in the list
+             * {@link String }
+             * 
+             * 
+             */
+            public List<String> getAttributeName() {
+                if (attributeName == null) {
+                    attributeName = new ArrayList<String>();
+                }
+                return this.attributeName;
+            }
+
+            /**
+             * Gets the value of the matcherSet property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link FeatureMatcherSet }
+             *     
+             */
+            public FeatureMatcherSet getMatcherSet() {
+                return matcherSet;
+            }
+
+            /**
+             * Sets the value of the matcherSet property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link FeatureMatcherSet }
+             *     
+             */
+            public void setMatcherSet(FeatureMatcherSet value) {
+                this.matcherSet = value;
+            }
+
+            /**
+             * Gets the value of the type property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getType() {
+                return type;
+            }
+
+            /**
+             * Sets the value of the type property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setType(String value) {
+                this.type = value;
+            }
+
+            /**
+             * Gets the value of the colour property.
+             * 
+             */
+            public int getColour() {
+                return colour;
+            }
+
+            /**
+             * Sets the value of the colour property.
+             * 
+             */
+            public void setColour(int value) {
+                this.colour = value;
+            }
+
+            /**
+             * Gets the value of the display property.
+             * 
+             */
+            public boolean isDisplay() {
+                return display;
+            }
+
+            /**
+             * Sets the value of the display property.
+             * 
+             */
+            public void setDisplay(boolean value) {
+                this.display = value;
+            }
+
+            /**
+             * Gets the value of the order property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getOrder() {
+                return order;
+            }
+
+            /**
+             * Sets the value of the order property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setOrder(Float value) {
+                this.order = value;
+            }
+
+            /**
+             * Gets the value of the mincolour property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getMincolour() {
+                return mincolour;
+            }
+
+            /**
+             * Sets the value of the mincolour property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setMincolour(Integer value) {
+                this.mincolour = value;
+            }
+
+            /**
+             * Gets the value of the noValueColour property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link NoValueColour }
+             *     
+             */
+            public NoValueColour getNoValueColour() {
+                if (noValueColour == null) {
+                    return NoValueColour.MIN;
+                } else {
+                    return noValueColour;
+                }
+            }
+
+            /**
+             * Sets the value of the noValueColour property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link NoValueColour }
+             *     
+             */
+            public void setNoValueColour(NoValueColour value) {
+                this.noValueColour = value;
+            }
+
+            /**
+             * Gets the value of the threshold property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getThreshold() {
+                return threshold;
+            }
+
+            /**
+             * Sets the value of the threshold property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setThreshold(Float value) {
+                this.threshold = value;
+            }
+
+            /**
+             * Gets the value of the threshstate property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getThreshstate() {
+                return threshstate;
+            }
+
+            /**
+             * Sets the value of the threshstate property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setThreshstate(Integer value) {
+                this.threshstate = value;
+            }
+
+            /**
+             * Gets the value of the max property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getMax() {
+                return max;
+            }
+
+            /**
+             * Sets the value of the max property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setMax(Float value) {
+                this.max = value;
+            }
+
+            /**
+             * Gets the value of the min property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getMin() {
+                return min;
+            }
+
+            /**
+             * Sets the value of the min property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setMin(Float value) {
+                this.min = value;
+            }
+
+            /**
+             * Gets the value of the colourByLabel property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Boolean }
+             *     
+             */
+            public Boolean isColourByLabel() {
+                return colourByLabel;
+            }
+
+            /**
+             * Sets the value of the colourByLabel property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Boolean }
+             *     
+             */
+            public void setColourByLabel(Boolean value) {
+                this.colourByLabel = value;
+            }
+
+            /**
+             * Gets the value of the autoScale property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Boolean }
+             *     
+             */
+            public Boolean isAutoScale() {
+                return autoScale;
+            }
+
+            /**
+             * Sets the value of the autoScale property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Boolean }
+             *     
+             */
+            public void setAutoScale(Boolean value) {
+                this.autoScale = value;
+            }
 
-    /**
-     * Sets the value of the showConsensusHistogram property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowConsensusHistogram(Boolean value)
-    {
-      this.showConsensusHistogram = value;
-    }
+        }
 
-    /**
-     * Gets the value of the showSequenceLogo property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowSequenceLogo()
-    {
-      if (showSequenceLogo == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showSequenceLogo;
-      }
     }
 
-    /**
-     * Sets the value of the showSequenceLogo property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowSequenceLogo(Boolean value)
-    {
-      this.showSequenceLogo = value;
-    }
 
     /**
-     * Gets the value of the normaliseSequenceLogo property.
+     * &lt;p&gt;Java class for anonymous complex type.
      * 
-     * @return possible object is {@link Boolean }
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
      * 
-     */
-    public boolean isNormaliseSequenceLogo()
-    {
-      if (normaliseSequenceLogo == null)
-      {
-        return false;
-      }
-      else
-      {
-        return normaliseSequenceLogo;
-      }
-    }
-
-    /**
-     * Sets the value of the normaliseSequenceLogo property.
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="seq" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/&amp;gt;
+     *         &amp;lt;element name="annotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="outlineColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="displayBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="displayText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="colourText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link Boolean }
      * 
      */
-    public void setNormaliseSequenceLogo(Boolean value)
-    {
-      this.normaliseSequenceLogo = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getId()
-    {
-      return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setId(String value)
-    {
-      this.id = value;
-    }
-
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="features" type="{www.jalview.org}feature" maxOccurs="unbounded" minOccurs="0"/>
-   *         &lt;element name="pdbids" maxOccurs="unbounded" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;extension base="{www.jalview.org}pdbentry">
-   *                 &lt;sequence>
-   *                   &lt;element name="structureState" maxOccurs="unbounded" minOccurs="0">
-   *                     &lt;complexType>
-   *                       &lt;simpleContent>
-   *                         &lt;extension base="&lt;http://www.w3.org/2001/XMLSchema>string">
-   *                           &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-   *                           &lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *                           &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                           &lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *                           &lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *                           &lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *                           &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                         &lt;/extension>
-   *                       &lt;/simpleContent>
-   *                     &lt;/complexType>
-   *                   &lt;/element>
-   *                 &lt;/sequence>
-   *               &lt;/extension>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="hiddenSequences" type="{http://www.w3.org/2001/XMLSchema}int" maxOccurs="unbounded" minOccurs="0"/>
-   *         &lt;element name="rnaViewer" maxOccurs="unbounded" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;sequence>
-   *                   &lt;element name="secondaryStructure" maxOccurs="unbounded">
-   *                     &lt;complexType>
-   *                       &lt;complexContent>
-   *                         &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                           &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                           &lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                           &lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *                           &lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                         &lt;/restriction>
-   *                       &lt;/complexContent>
-   *                     &lt;/complexType>
-   *                   &lt;/element>
-   *                 &lt;/sequence>
-   *                 &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-   *                 &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                 &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                 &lt;attribute name="dividerLocation" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="selectedRna" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *       &lt;/sequence>
-   *       &lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="hidden" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="viewreference" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(
-    name = "",
-    propOrder =
-    { "features", "pdbids", "hiddenSequences", "rnaViewer" })
-  public static class JSeq
-  {
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<Feature> features;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<JalviewModel.JSeq.Pdbids> pdbids;
-
-    @XmlElement(namespace = "www.jalview.org", type = Integer.class)
-    protected List<Integer> hiddenSequences;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<JalviewModel.JSeq.RnaViewer> rnaViewer;
-
-    @XmlAttribute(name = "colour")
-    protected Integer colour;
-
-    @XmlAttribute(name = "start", required = true)
-    protected int start;
-
-    @XmlAttribute(name = "end", required = true)
-    protected int end;
-
-    @XmlAttribute(name = "id", required = true)
-    protected String id;
-
-    @XmlAttribute(name = "hidden")
-    protected Boolean hidden;
-
-    @XmlAttribute(name = "viewreference")
-    protected Boolean viewreference;
-
-    /**
-     * Gets the value of the features property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the features property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getFeatures().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list {@link Feature }
-     * 
-     * 
-     */
-    public List<Feature> getFeatures()
-    {
-      if (features == null)
-      {
-        features = new ArrayList<Feature>();
-      }
-      return this.features;
-    }
-
-    /**
-     * Gets the value of the pdbids property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the pdbids property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getPdbids().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.JSeq.Pdbids }
-     * 
-     * 
-     */
-    public List<JalviewModel.JSeq.Pdbids> getPdbids()
-    {
-      if (pdbids == null)
-      {
-        pdbids = new ArrayList<JalviewModel.JSeq.Pdbids>();
-      }
-      return this.pdbids;
-    }
-
-    /**
-     * Gets the value of the hiddenSequences property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the hiddenSequences property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getHiddenSequences().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list {@link Integer }
-     * 
-     * 
-     */
-    public List<Integer> getHiddenSequences()
-    {
-      if (hiddenSequences == null)
-      {
-        hiddenSequences = new ArrayList<Integer>();
-      }
-      return this.hiddenSequences;
-    }
-
-    /**
-     * Gets the value of the rnaViewer property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the rnaViewer property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getRnaViewer().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.JSeq.RnaViewer }
-     * 
-     * 
-     */
-    public List<JalviewModel.JSeq.RnaViewer> getRnaViewer()
-    {
-      if (rnaViewer == null)
-      {
-        rnaViewer = new ArrayList<JalviewModel.JSeq.RnaViewer>();
-      }
-      return this.rnaViewer;
-    }
-
-    /**
-     * Gets the value of the colour property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getColour()
-    {
-      return colour;
-    }
-
-    /**
-     * Sets the value of the colour property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setColour(Integer value)
-    {
-      this.colour = value;
-    }
-
-    /**
-     * Gets the value of the start property.
-     * 
-     */
-    public int getStart()
-    {
-      return start;
-    }
-
-    /**
-     * Sets the value of the start property.
-     * 
-     */
-    public void setStart(int value)
-    {
-      this.start = value;
-    }
-
-    /**
-     * Gets the value of the end property.
-     * 
-     */
-    public int getEnd()
-    {
-      return end;
-    }
-
-    /**
-     * Sets the value of the end property.
-     * 
-     */
-    public void setEnd(int value)
-    {
-      this.end = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getId()
-    {
-      return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setId(String value)
-    {
-      this.id = value;
-    }
-
-    /**
-     * Gets the value of the hidden property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isHidden()
-    {
-      return hidden;
-    }
-
-    /**
-     * Sets the value of the hidden property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setHidden(Boolean value)
-    {
-      this.hidden = value;
-    }
-
-    /**
-     * Gets the value of the viewreference property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isViewreference()
-    {
-      return viewreference;
-    }
-
-    /**
-     * Sets the value of the viewreference property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setViewreference(Boolean value)
-    {
-      this.viewreference = value;
-    }
-
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;extension base="{www.jalview.org}pdbentry">
-     *       &lt;sequence>
-     *         &lt;element name="structureState" maxOccurs="unbounded" minOccurs="0">
-     *           &lt;complexType>
-     *             &lt;simpleContent>
-     *               &lt;extension base="&lt;http://www.w3.org/2001/XMLSchema>string">
-     *                 &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-     *                 &lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *                 &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *                 &lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-     *                 &lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-     *                 &lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-     *                 &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *               &lt;/extension>
-     *             &lt;/simpleContent>
-     *           &lt;/complexType>
-     *         &lt;/element>
-     *       &lt;/sequence>
-     *     &lt;/extension>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "", propOrder = { "structureState" })
-    public static class Pdbids extends Pdbentry
-    {
-
-      @XmlElement(namespace = "www.jalview.org")
-      protected List<JalviewModel.JSeq.Pdbids.StructureState> structureState;
-
-      /**
-       * Gets the value of the structureState property.
-       * 
-       * <p>
-       * This accessor method returns a reference to the live list, not a
-       * snapshot. Therefore any modification you make to the returned list will
-       * be present inside the JAXB object. This is why there is not a
-       * <CODE>set</CODE> method for the structureState property.
-       * 
-       * <p>
-       * For example, to add a new item, do as follows:
-       * 
-       * <pre>
-       * getStructureState().add(newItem);
-       * </pre>
-       * 
-       * 
-       * <p>
-       * Objects of the following type(s) are allowed in the list
-       * {@link JalviewModel.JSeq.Pdbids.StructureState }
-       * 
-       * 
-       */
-      public List<JalviewModel.JSeq.Pdbids.StructureState> getStructureState()
-      {
-        if (structureState == null)
-        {
-          structureState = new ArrayList<JalviewModel.JSeq.Pdbids.StructureState>();
-        }
-        return this.structureState;
-      }
-
-      /**
-       * <p>
-       * Java class for anonymous complex type.
-       * 
-       * <p>
-       * The following schema fragment specifies the expected content contained
-       * within this class.
-       * 
-       * <pre>
-       * &lt;complexType>
-       *   &lt;simpleContent>
-       *     &lt;extension base="&lt;http://www.w3.org/2001/XMLSchema>string">
-       *       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-       *       &lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-       *       &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
-       *       &lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-       *       &lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-       *       &lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-       *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
-       *     &lt;/extension>
-       *   &lt;/simpleContent>
-       * &lt;/complexType>
-       * </pre>
-       * 
-       * 
-       */
-      @XmlAccessorType(XmlAccessType.FIELD)
-      @XmlType(name = "", propOrder = { "value" })
-      public static class StructureState
-      {
-
-        @XmlValue
-        protected String value;
-
-        @XmlAttribute(name = "visible")
-        protected Boolean visible;
-
-        @XmlAttribute(name = "viewId")
-        protected String viewId;
-
-        @XmlAttribute(name = "alignwithAlignPanel")
-        protected Boolean alignwithAlignPanel;
-
-        @XmlAttribute(name = "colourwithAlignPanel")
-        protected Boolean colourwithAlignPanel;
-
-        @XmlAttribute(name = "colourByJmol")
-        protected Boolean colourByJmol;
-
-        @XmlAttribute(name = "type")
-        protected String type;
-
-        @XmlAttribute(name = "width")
-        protected Integer width;
-
-        @XmlAttribute(name = "height")
-        protected Integer height;
-
-        @XmlAttribute(name = "xpos")
-        protected Integer xpos;
-
-        @XmlAttribute(name = "ypos")
-        protected Integer ypos;
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "seq",
+        "annotationColours"
+    })
+    public static class JGroup {
+
+        @XmlElement(namespace = "www.jalview.org", required = true)
+        protected List<String> seq;
+        @XmlElement(namespace = "www.jalview.org")
+        protected AnnotationColourScheme annotationColours;
+        @XmlAttribute(name = "start")
+        protected Integer start;
+        @XmlAttribute(name = "end")
+        protected Integer end;
+        @XmlAttribute(name = "name")
+        protected String name;
+        @XmlAttribute(name = "colour")
+        protected String colour;
+        @XmlAttribute(name = "consThreshold")
+        protected Integer consThreshold;
+        @XmlAttribute(name = "pidThreshold")
+        protected Integer pidThreshold;
+        @XmlAttribute(name = "outlineColour")
+        protected Integer outlineColour;
+        @XmlAttribute(name = "displayBoxes")
+        protected Boolean displayBoxes;
+        @XmlAttribute(name = "displayText")
+        protected Boolean displayText;
+        @XmlAttribute(name = "colourText")
+        protected Boolean colourText;
+        @XmlAttribute(name = "textCol1")
+        protected Integer textCol1;
+        @XmlAttribute(name = "textCol2")
+        protected Integer textCol2;
+        @XmlAttribute(name = "textColThreshold")
+        protected Integer textColThreshold;
+        @XmlAttribute(name = "showUnconserved")
+        protected Boolean showUnconserved;
+        @XmlAttribute(name = "ignoreGapsinConsensus")
+        protected Boolean ignoreGapsinConsensus;
+        @XmlAttribute(name = "showConsensusHistogram")
+        protected Boolean showConsensusHistogram;
+        @XmlAttribute(name = "showSequenceLogo")
+        protected Boolean showSequenceLogo;
+        @XmlAttribute(name = "normaliseSequenceLogo")
+        protected Boolean normaliseSequenceLogo;
+        @XmlAttribute(name = "id")
+        protected String id;
 
         /**
-         * Gets the value of the value property.
+         * Gets the value of the seq property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the seq property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getSeq().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link String }
          * 
-         * @return possible object is {@link String }
          * 
          */
-        public String getValue()
-        {
-          return value;
+        public List<String> getSeq() {
+            if (seq == null) {
+                seq = new ArrayList<String>();
+            }
+            return this.seq;
         }
 
         /**
-         * Sets the value of the value property.
-         * 
-         * @param value
-         *          allowed object is {@link String }
+         * Gets the value of the annotationColours property.
          * 
+         * @return
+         *     possible object is
+         *     {@link AnnotationColourScheme }
+         *     
          */
-        public void setValue(String value)
-        {
-          this.value = value;
+        public AnnotationColourScheme getAnnotationColours() {
+            return annotationColours;
         }
 
         /**
-         * Gets the value of the visible property.
+         * Sets the value of the annotationColours property.
          * 
-         * @return possible object is {@link Boolean }
+         * @param value
+         *     allowed object is
+         *     {@link AnnotationColourScheme }
+         *     
+         */
+        public void setAnnotationColours(AnnotationColourScheme value) {
+            this.annotationColours = value;
+        }
+
+        /**
+         * Gets the value of the start property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public Boolean isVisible()
-        {
-          return visible;
+        public Integer getStart() {
+            return start;
         }
 
         /**
-         * Sets the value of the visible property.
+         * Sets the value of the start property.
          * 
          * @param value
-         *          allowed object is {@link Boolean }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setVisible(Boolean value)
-        {
-          this.visible = value;
+        public void setStart(Integer value) {
+            this.start = value;
         }
 
         /**
-         * Gets the value of the viewId property.
-         * 
-         * @return possible object is {@link String }
+         * Gets the value of the end property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public String getViewId()
-        {
-          return viewId;
+        public Integer getEnd() {
+            return end;
         }
 
         /**
-         * Sets the value of the viewId property.
+         * Sets the value of the end property.
          * 
          * @param value
-         *          allowed object is {@link String }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setViewId(String value)
-        {
-          this.viewId = value;
+        public void setEnd(Integer value) {
+            this.end = value;
         }
 
         /**
-         * Gets the value of the alignwithAlignPanel property.
-         * 
-         * @return possible object is {@link Boolean }
+         * Gets the value of the name property.
          * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
          */
-        public boolean isAlignwithAlignPanel()
-        {
-          if (alignwithAlignPanel == null)
-          {
-            return true;
-          }
-          else
-          {
-            return alignwithAlignPanel;
-          }
+        public String getName() {
+            return name;
         }
 
         /**
-         * Sets the value of the alignwithAlignPanel property.
+         * Sets the value of the name property.
          * 
          * @param value
-         *          allowed object is {@link Boolean }
-         * 
+         *     allowed object is
+         *     {@link String }
+         *     
          */
-        public void setAlignwithAlignPanel(Boolean value)
-        {
-          this.alignwithAlignPanel = value;
+        public void setName(String value) {
+            this.name = value;
         }
 
         /**
-         * Gets the value of the colourwithAlignPanel property.
-         * 
-         * @return possible object is {@link Boolean }
+         * Gets the value of the colour property.
          * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
          */
-        public boolean isColourwithAlignPanel()
-        {
-          if (colourwithAlignPanel == null)
-          {
-            return false;
-          }
-          else
-          {
-            return colourwithAlignPanel;
-          }
+        public String getColour() {
+            return colour;
         }
 
         /**
-         * Sets the value of the colourwithAlignPanel property.
+         * Sets the value of the colour property.
          * 
          * @param value
-         *          allowed object is {@link Boolean }
-         * 
+         *     allowed object is
+         *     {@link String }
+         *     
          */
-        public void setColourwithAlignPanel(Boolean value)
-        {
-          this.colourwithAlignPanel = value;
+        public void setColour(String value) {
+            this.colour = value;
         }
 
         /**
-         * Gets the value of the colourByJmol property.
-         * 
-         * @return possible object is {@link Boolean }
+         * Gets the value of the consThreshold property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public boolean isColourByJmol()
-        {
-          if (colourByJmol == null)
-          {
-            return true;
-          }
-          else
-          {
-            return colourByJmol;
-          }
+        public Integer getConsThreshold() {
+            return consThreshold;
         }
 
         /**
-         * Sets the value of the colourByJmol property.
+         * Sets the value of the consThreshold property.
          * 
          * @param value
-         *          allowed object is {@link Boolean }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setColourByJmol(Boolean value)
-        {
-          this.colourByJmol = value;
+        public void setConsThreshold(Integer value) {
+            this.consThreshold = value;
         }
 
         /**
-         * Gets the value of the type property.
-         * 
-         * @return possible object is {@link String }
+         * Gets the value of the pidThreshold property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public String getType()
-        {
-          return type;
+        public Integer getPidThreshold() {
+            return pidThreshold;
         }
 
         /**
-         * Sets the value of the type property.
+         * Sets the value of the pidThreshold property.
          * 
          * @param value
-         *          allowed object is {@link String }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setType(String value)
-        {
-          this.type = value;
+        public void setPidThreshold(Integer value) {
+            this.pidThreshold = value;
         }
 
         /**
-         * Gets the value of the width property.
-         * 
-         * @return possible object is {@link Integer }
+         * Gets the value of the outlineColour property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public Integer getWidth()
-        {
-          return width;
+        public Integer getOutlineColour() {
+            return outlineColour;
         }
 
         /**
-         * Sets the value of the width property.
+         * Sets the value of the outlineColour property.
          * 
          * @param value
-         *          allowed object is {@link Integer }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setWidth(Integer value)
-        {
-          this.width = value;
+        public void setOutlineColour(Integer value) {
+            this.outlineColour = value;
         }
 
         /**
-         * Gets the value of the height property.
-         * 
-         * @return possible object is {@link Integer }
+         * Gets the value of the displayBoxes property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
          */
-        public Integer getHeight()
-        {
-          return height;
+        public Boolean isDisplayBoxes() {
+            return displayBoxes;
         }
 
         /**
-         * Sets the value of the height property.
+         * Sets the value of the displayBoxes property.
          * 
          * @param value
-         *          allowed object is {@link Integer }
-         * 
+         *     allowed object is
+         *     {@link Boolean }
+         *     
          */
-        public void setHeight(Integer value)
-        {
-          this.height = value;
+        public void setDisplayBoxes(Boolean value) {
+            this.displayBoxes = value;
         }
 
         /**
-         * Gets the value of the xpos property.
-         * 
-         * @return possible object is {@link Integer }
+         * Gets the value of the displayText property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
          */
-        public Integer getXpos()
-        {
-          return xpos;
+        public Boolean isDisplayText() {
+            return displayText;
         }
 
         /**
-         * Sets the value of the xpos property.
+         * Sets the value of the displayText property.
          * 
          * @param value
-         *          allowed object is {@link Integer }
-         * 
+         *     allowed object is
+         *     {@link Boolean }
+         *     
          */
-        public void setXpos(Integer value)
-        {
-          this.xpos = value;
+        public void setDisplayText(Boolean value) {
+            this.displayText = value;
         }
 
         /**
-         * Gets the value of the ypos property.
-         * 
-         * @return possible object is {@link Integer }
+         * Gets the value of the colourText property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
          */
-        public Integer getYpos()
-        {
-          return ypos;
+        public Boolean isColourText() {
+            return colourText;
         }
 
         /**
-         * Sets the value of the ypos property.
+         * Sets the value of the colourText property.
          * 
          * @param value
-         *          allowed object is {@link Integer }
-         * 
+         *     allowed object is
+         *     {@link Boolean }
+         *     
          */
-        public void setYpos(Integer value)
-        {
-          this.ypos = value;
+        public void setColourText(Boolean value) {
+            this.colourText = value;
         }
 
-      }
-
-    }
-
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;sequence>
-     *         &lt;element name="secondaryStructure" maxOccurs="unbounded">
-     *           &lt;complexType>
-     *             &lt;complexContent>
-     *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *                 &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *                 &lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *                 &lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *                 &lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *               &lt;/restriction>
-     *             &lt;/complexContent>
-     *           &lt;/complexType>
-     *         &lt;/element>
-     *       &lt;/sequence>
-     *       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-     *       &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *       &lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *       &lt;attribute name="dividerLocation" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="selectedRna" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "", propOrder = { "secondaryStructure" })
-    public static class RnaViewer
-    {
-
-      @XmlElement(namespace = "www.jalview.org", required = true)
-      protected List<JalviewModel.JSeq.RnaViewer.SecondaryStructure> secondaryStructure;
-
-      @XmlAttribute(name = "title")
-      protected String title;
-
-      @XmlAttribute(name = "viewId")
-      protected String viewId;
-
-      @XmlAttribute(name = "dividerLocation")
-      protected Integer dividerLocation;
-
-      @XmlAttribute(name = "selectedRna")
-      protected Integer selectedRna;
-
-      @XmlAttribute(name = "width")
-      protected Integer width;
-
-      @XmlAttribute(name = "height")
-      protected Integer height;
-
-      @XmlAttribute(name = "xpos")
-      protected Integer xpos;
-
-      @XmlAttribute(name = "ypos")
-      protected Integer ypos;
-
-      /**
-       * Gets the value of the secondaryStructure property.
-       * 
-       * <p>
-       * This accessor method returns a reference to the live list, not a
-       * snapshot. Therefore any modification you make to the returned list will
-       * be present inside the JAXB object. This is why there is not a
-       * <CODE>set</CODE> method for the secondaryStructure property.
-       * 
-       * <p>
-       * For example, to add a new item, do as follows:
-       * 
-       * <pre>
-       * getSecondaryStructure().add(newItem);
-       * </pre>
-       * 
-       * 
-       * <p>
-       * Objects of the following type(s) are allowed in the list
-       * {@link JalviewModel.JSeq.RnaViewer.SecondaryStructure }
-       * 
-       * 
-       */
-      public List<JalviewModel.JSeq.RnaViewer.SecondaryStructure> getSecondaryStructure()
-      {
-        if (secondaryStructure == null)
-        {
-          secondaryStructure = new ArrayList<JalviewModel.JSeq.RnaViewer.SecondaryStructure>();
-        }
-        return this.secondaryStructure;
-      }
-
-      /**
-       * Gets the value of the title property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getTitle()
-      {
-        return title;
-      }
-
-      /**
-       * Sets the value of the title property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setTitle(String value)
-      {
-        this.title = value;
-      }
-
-      /**
-       * Gets the value of the viewId property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getViewId()
-      {
-        return viewId;
-      }
-
-      /**
-       * Sets the value of the viewId property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setViewId(String value)
-      {
-        this.viewId = value;
-      }
-
-      /**
-       * Gets the value of the dividerLocation property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getDividerLocation()
-      {
-        return dividerLocation;
-      }
-
-      /**
-       * Sets the value of the dividerLocation property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setDividerLocation(Integer value)
-      {
-        this.dividerLocation = value;
-      }
-
-      /**
-       * Gets the value of the selectedRna property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getSelectedRna()
-      {
-        return selectedRna;
-      }
-
-      /**
-       * Sets the value of the selectedRna property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setSelectedRna(Integer value)
-      {
-        this.selectedRna = value;
-      }
-
-      /**
-       * Gets the value of the width property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getWidth()
-      {
-        return width;
-      }
-
-      /**
-       * Sets the value of the width property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setWidth(Integer value)
-      {
-        this.width = value;
-      }
-
-      /**
-       * Gets the value of the height property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getHeight()
-      {
-        return height;
-      }
-
-      /**
-       * Sets the value of the height property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setHeight(Integer value)
-      {
-        this.height = value;
-      }
-
-      /**
-       * Gets the value of the xpos property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getXpos()
-      {
-        return xpos;
-      }
-
-      /**
-       * Sets the value of the xpos property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setXpos(Integer value)
-      {
-        this.xpos = value;
-      }
-
-      /**
-       * Gets the value of the ypos property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getYpos()
-      {
-        return ypos;
-      }
-
-      /**
-       * Sets the value of the ypos property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setYpos(Integer value)
-      {
-        this.ypos = value;
-      }
-
-      /**
-       * <p>
-       * Java class for anonymous complex type.
-       * 
-       * <p>
-       * The following schema fragment specifies the expected content contained
-       * within this class.
-       * 
-       * <pre>
-       * &lt;complexType>
-       *   &lt;complexContent>
-       *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-       *       &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-       *       &lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-       *       &lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-       *       &lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" />
-       *     &lt;/restriction>
-       *   &lt;/complexContent>
-       * &lt;/complexType>
-       * </pre>
-       * 
-       * 
-       */
-      @XmlAccessorType(XmlAccessType.FIELD)
-      @XmlType(name = "")
-      public static class SecondaryStructure
-      {
-
-        @XmlAttribute(name = "title")
-        protected String title;
-
-        @XmlAttribute(name = "annotationId", required = true)
-        protected String annotationId;
-
-        @XmlAttribute(name = "gapped")
-        protected Boolean gapped;
-
-        @XmlAttribute(name = "viewerState")
-        protected String viewerState;
-
         /**
-         * Gets the value of the title property.
-         * 
-         * @return possible object is {@link String }
+         * Gets the value of the textCol1 property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public String getTitle()
-        {
-          return title;
+        public Integer getTextCol1() {
+            return textCol1;
         }
 
         /**
-         * Sets the value of the title property.
+         * Sets the value of the textCol1 property.
          * 
          * @param value
-         *          allowed object is {@link String }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setTitle(String value)
-        {
-          this.title = value;
+        public void setTextCol1(Integer value) {
+            this.textCol1 = value;
         }
 
         /**
-         * Gets the value of the annotationId property.
-         * 
-         * @return possible object is {@link String }
+         * Gets the value of the textCol2 property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public String getAnnotationId()
-        {
-          return annotationId;
+        public Integer getTextCol2() {
+            return textCol2;
         }
 
         /**
-         * Sets the value of the annotationId property.
+         * Sets the value of the textCol2 property.
          * 
          * @param value
-         *          allowed object is {@link String }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setAnnotationId(String value)
-        {
-          this.annotationId = value;
+        public void setTextCol2(Integer value) {
+            this.textCol2 = value;
         }
 
         /**
-         * Gets the value of the gapped property.
-         * 
-         * @return possible object is {@link Boolean }
+         * Gets the value of the textColThreshold property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
          */
-        public Boolean isGapped()
-        {
-          return gapped;
+        public Integer getTextColThreshold() {
+            return textColThreshold;
         }
 
         /**
-         * Sets the value of the gapped property.
+         * Sets the value of the textColThreshold property.
          * 
          * @param value
-         *          allowed object is {@link Boolean }
-         * 
+         *     allowed object is
+         *     {@link Integer }
+         *     
          */
-        public void setGapped(Boolean value)
-        {
-          this.gapped = value;
+        public void setTextColThreshold(Integer value) {
+            this.textColThreshold = value;
         }
 
         /**
-         * Gets the value of the viewerState property.
-         * 
-         * @return possible object is {@link String }
+         * Gets the value of the showUnconserved property.
          * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
          */
-        public String getViewerState()
-        {
-          return viewerState;
+        public Boolean isShowUnconserved() {
+            return showUnconserved;
         }
 
         /**
-         * Sets the value of the viewerState property.
+         * Sets the value of the showUnconserved property.
          * 
          * @param value
-         *          allowed object is {@link String }
-         * 
+         *     allowed object is
+         *     {@link Boolean }
+         *     
          */
-        public void setViewerState(String value)
-        {
-          this.viewerState = value;
+        public void setShowUnconserved(Boolean value) {
+            this.showUnconserved = value;
         }
 
-      }
+        /**
+         * Gets the value of the ignoreGapsinConsensus property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isIgnoreGapsinConsensus() {
+            if (ignoreGapsinConsensus == null) {
+                return true;
+            } else {
+                return ignoreGapsinConsensus;
+            }
+        }
 
-    }
+        /**
+         * Sets the value of the ignoreGapsinConsensus property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setIgnoreGapsinConsensus(Boolean value) {
+            this.ignoreGapsinConsensus = value;
+        }
 
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="sequencePoint" maxOccurs="unbounded">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attGroup ref="{www.jalview.org}position"/>
-   *                 &lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="axis" maxOccurs="3" minOccurs="3">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attGroup ref="{www.jalview.org}position"/>
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="seqPointMin">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attGroup ref="{www.jalview.org}position"/>
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="seqPointMax">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attGroup ref="{www.jalview.org}position"/>
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="pcaData" type="{www.jalview.org}PcaDataType"/>
-   *       &lt;/sequence>
-   *       &lt;attGroup ref="{www.jalview.org}SimilarityParams"/>
-   *       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-   *       &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="scoreModelName" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="xDim" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="yDim" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="zDim" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="scaleFactor" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *       &lt;attribute name="showLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(
-    name = "",
-    propOrder =
-    { "sequencePoint", "axis", "seqPointMin", "seqPointMax", "pcaData" })
-  public static class PcaViewer
-  {
-
-    @XmlElement(namespace = "www.jalview.org", required = true)
-    protected List<JalviewModel.PcaViewer.SequencePoint> sequencePoint;
-
-    @XmlElement(namespace = "www.jalview.org", required = true)
-    protected List<JalviewModel.PcaViewer.Axis> axis;
-
-    @XmlElement(namespace = "www.jalview.org", required = true)
-    protected JalviewModel.PcaViewer.SeqPointMin seqPointMin;
-
-    @XmlElement(namespace = "www.jalview.org", required = true)
-    protected JalviewModel.PcaViewer.SeqPointMax seqPointMax;
-
-    @XmlElement(namespace = "www.jalview.org", required = true)
-    protected PcaDataType pcaData;
-
-    @XmlAttribute(name = "title")
-    protected String title;
-
-    @XmlAttribute(name = "scoreModelName")
-    protected String scoreModelName;
-
-    @XmlAttribute(name = "xDim")
-    protected Integer xDim;
-
-    @XmlAttribute(name = "yDim")
-    protected Integer yDim;
-
-    @XmlAttribute(name = "zDim")
-    protected Integer zDim;
-
-    @XmlAttribute(name = "bgColour")
-    protected Integer bgColour;
-
-    @XmlAttribute(name = "scaleFactor")
-    protected Float scaleFactor;
-
-    @XmlAttribute(name = "showLabels")
-    protected Boolean showLabels;
-
-    @XmlAttribute(name = "linkToAllViews")
-    protected Boolean linkToAllViews;
-
-    @XmlAttribute(name = "includeGaps")
-    protected Boolean includeGaps;
-
-    @XmlAttribute(name = "matchGaps")
-    protected Boolean matchGaps;
-
-    @XmlAttribute(name = "includeGappedColumns")
-    protected Boolean includeGappedColumns;
-
-    @XmlAttribute(name = "denominateByShortestLength")
-    protected Boolean denominateByShortestLength;
-
-    @XmlAttribute(name = "width")
-    protected Integer width;
-
-    @XmlAttribute(name = "height")
-    protected Integer height;
-
-    @XmlAttribute(name = "xpos")
-    protected Integer xpos;
-
-    @XmlAttribute(name = "ypos")
-    protected Integer ypos;
+        /**
+         * Gets the value of the showConsensusHistogram property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowConsensusHistogram() {
+            if (showConsensusHistogram == null) {
+                return true;
+            } else {
+                return showConsensusHistogram;
+            }
+        }
 
-    /**
-     * Gets the value of the sequencePoint property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the sequencePoint property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getSequencePoint().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.PcaViewer.SequencePoint }
-     * 
-     * 
-     */
-    public List<JalviewModel.PcaViewer.SequencePoint> getSequencePoint()
-    {
-      if (sequencePoint == null)
-      {
-        sequencePoint = new ArrayList<JalviewModel.PcaViewer.SequencePoint>();
-      }
-      return this.sequencePoint;
-    }
+        /**
+         * Sets the value of the showConsensusHistogram property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowConsensusHistogram(Boolean value) {
+            this.showConsensusHistogram = value;
+        }
 
-    /**
-     * Gets the value of the axis property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the axis property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getAxis().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.PcaViewer.Axis }
-     * 
-     * 
-     */
-    public List<JalviewModel.PcaViewer.Axis> getAxis()
-    {
-      if (axis == null)
-      {
-        axis = new ArrayList<JalviewModel.PcaViewer.Axis>();
-      }
-      return this.axis;
-    }
+        /**
+         * Gets the value of the showSequenceLogo property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowSequenceLogo() {
+            if (showSequenceLogo == null) {
+                return false;
+            } else {
+                return showSequenceLogo;
+            }
+        }
 
-    /**
-     * Gets the value of the seqPointMin property.
-     * 
-     * @return possible object is {@link JalviewModel.PcaViewer.SeqPointMin }
-     * 
-     */
-    public JalviewModel.PcaViewer.SeqPointMin getSeqPointMin()
-    {
-      return seqPointMin;
-    }
+        /**
+         * Sets the value of the showSequenceLogo property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowSequenceLogo(Boolean value) {
+            this.showSequenceLogo = value;
+        }
 
-    /**
-     * Sets the value of the seqPointMin property.
-     * 
-     * @param value
-     *          allowed object is {@link JalviewModel.PcaViewer.SeqPointMin }
-     * 
-     */
-    public void setSeqPointMin(JalviewModel.PcaViewer.SeqPointMin value)
-    {
-      this.seqPointMin = value;
-    }
+        /**
+         * Gets the value of the normaliseSequenceLogo property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isNormaliseSequenceLogo() {
+            if (normaliseSequenceLogo == null) {
+                return false;
+            } else {
+                return normaliseSequenceLogo;
+            }
+        }
 
-    /**
-     * Gets the value of the seqPointMax property.
-     * 
-     * @return possible object is {@link JalviewModel.PcaViewer.SeqPointMax }
-     * 
-     */
-    public JalviewModel.PcaViewer.SeqPointMax getSeqPointMax()
-    {
-      return seqPointMax;
-    }
+        /**
+         * Sets the value of the normaliseSequenceLogo property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setNormaliseSequenceLogo(Boolean value) {
+            this.normaliseSequenceLogo = value;
+        }
 
-    /**
-     * Sets the value of the seqPointMax property.
-     * 
-     * @param value
-     *          allowed object is {@link JalviewModel.PcaViewer.SeqPointMax }
-     * 
-     */
-    public void setSeqPointMax(JalviewModel.PcaViewer.SeqPointMax value)
-    {
-      this.seqPointMax = value;
-    }
+        /**
+         * Gets the value of the id property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getId() {
+            return id;
+        }
 
-    /**
-     * Gets the value of the pcaData property.
-     * 
-     * @return possible object is {@link PcaDataType }
-     * 
-     */
-    public PcaDataType getPcaData()
-    {
-      return pcaData;
-    }
+        /**
+         * Sets the value of the id property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setId(String value) {
+            this.id = value;
+        }
 
-    /**
-     * Sets the value of the pcaData property.
-     * 
-     * @param value
-     *          allowed object is {@link PcaDataType }
-     * 
-     */
-    public void setPcaData(PcaDataType value)
-    {
-      this.pcaData = value;
     }
 
-    /**
-     * Gets the value of the title property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getTitle()
-    {
-      return title;
-    }
 
     /**
-     * Sets the value of the title property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="features" type="{www.jalview.org}feature" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+     *         &amp;lt;element name="pdbids" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;extension base="{www.jalview.org}pdbentry"&amp;gt;
+     *                 &amp;lt;sequence&amp;gt;
+     *                   &amp;lt;element name="structureState" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *                     &amp;lt;complexType&amp;gt;
+     *                       &amp;lt;simpleContent&amp;gt;
+     *                         &amp;lt;extension base="&amp;lt;http://www.w3.org/2001/XMLSchema&amp;gt;string"&amp;gt;
+     *                           &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+     *                           &amp;lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *                           &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                           &amp;lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *                           &amp;lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *                           &amp;lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *                           &amp;lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                         &amp;lt;/extension&amp;gt;
+     *                       &amp;lt;/simpleContent&amp;gt;
+     *                     &amp;lt;/complexType&amp;gt;
+     *                   &amp;lt;/element&amp;gt;
+     *                 &amp;lt;/sequence&amp;gt;
+     *               &amp;lt;/extension&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="hiddenSequences" type="{http://www.w3.org/2001/XMLSchema}int" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+     *         &amp;lt;element name="rnaViewer" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;sequence&amp;gt;
+     *                   &amp;lt;element name="secondaryStructure" maxOccurs="unbounded"&amp;gt;
+     *                     &amp;lt;complexType&amp;gt;
+     *                       &amp;lt;complexContent&amp;gt;
+     *                         &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                           &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                           &amp;lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                           &amp;lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *                           &amp;lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                         &amp;lt;/restriction&amp;gt;
+     *                       &amp;lt;/complexContent&amp;gt;
+     *                     &amp;lt;/complexType&amp;gt;
+     *                   &amp;lt;/element&amp;gt;
+     *                 &amp;lt;/sequence&amp;gt;
+     *                 &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+     *                 &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                 &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                 &amp;lt;attribute name="dividerLocation" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="selectedRna" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="colour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="hidden" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="viewreference" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link String }
      * 
      */
-    public void setTitle(String value)
-    {
-      this.title = value;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "features",
+        "pdbids",
+        "hiddenSequences",
+        "rnaViewer"
+    })
+    public static class JSeq {
+
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<Feature> features;
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<JalviewModel.JSeq.Pdbids> pdbids;
+        @XmlElement(namespace = "www.jalview.org", type = Integer.class)
+        protected List<Integer> hiddenSequences;
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<JalviewModel.JSeq.RnaViewer> rnaViewer;
+        @XmlAttribute(name = "colour")
+        protected Integer colour;
+        @XmlAttribute(name = "start", required = true)
+        protected int start;
+        @XmlAttribute(name = "end", required = true)
+        protected int end;
+        @XmlAttribute(name = "id", required = true)
+        protected String id;
+        @XmlAttribute(name = "hidden")
+        protected Boolean hidden;
+        @XmlAttribute(name = "viewreference")
+        protected Boolean viewreference;
 
-    /**
-     * Gets the value of the scoreModelName property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getScoreModelName()
-    {
-      return scoreModelName;
-    }
+        /**
+         * Gets the value of the features property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the features property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getFeatures().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link Feature }
+         * 
+         * 
+         */
+        public List<Feature> getFeatures() {
+            if (features == null) {
+                features = new ArrayList<Feature>();
+            }
+            return this.features;
+        }
 
-    /**
-     * Sets the value of the scoreModelName property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setScoreModelName(String value)
-    {
-      this.scoreModelName = value;
-    }
+        /**
+         * Gets the value of the pdbids property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the pdbids property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getPdbids().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.JSeq.Pdbids }
+         * 
+         * 
+         */
+        public List<JalviewModel.JSeq.Pdbids> getPdbids() {
+            if (pdbids == null) {
+                pdbids = new ArrayList<JalviewModel.JSeq.Pdbids>();
+            }
+            return this.pdbids;
+        }
 
-    /**
-     * Gets the value of the xDim property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getXDim()
-    {
-      return xDim;
-    }
+        /**
+         * Gets the value of the hiddenSequences property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the hiddenSequences property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getHiddenSequences().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link Integer }
+         * 
+         * 
+         */
+        public List<Integer> getHiddenSequences() {
+            if (hiddenSequences == null) {
+                hiddenSequences = new ArrayList<Integer>();
+            }
+            return this.hiddenSequences;
+        }
 
-    /**
-     * Sets the value of the xDim property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setXDim(Integer value)
-    {
-      this.xDim = value;
-    }
+        /**
+         * Gets the value of the rnaViewer property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the rnaViewer property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getRnaViewer().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.JSeq.RnaViewer }
+         * 
+         * 
+         */
+        public List<JalviewModel.JSeq.RnaViewer> getRnaViewer() {
+            if (rnaViewer == null) {
+                rnaViewer = new ArrayList<JalviewModel.JSeq.RnaViewer>();
+            }
+            return this.rnaViewer;
+        }
 
-    /**
-     * Gets the value of the yDim property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getYDim()
-    {
-      return yDim;
-    }
+        /**
+         * Gets the value of the colour property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getColour() {
+            return colour;
+        }
 
-    /**
-     * Sets the value of the yDim property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setYDim(Integer value)
-    {
-      this.yDim = value;
-    }
+        /**
+         * Sets the value of the colour property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setColour(Integer value) {
+            this.colour = value;
+        }
 
-    /**
-     * Gets the value of the zDim property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getZDim()
-    {
-      return zDim;
-    }
+        /**
+         * Gets the value of the start property.
+         * 
+         */
+        public int getStart() {
+            return start;
+        }
 
-    /**
-     * Sets the value of the zDim property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setZDim(Integer value)
-    {
-      this.zDim = value;
-    }
+        /**
+         * Sets the value of the start property.
+         * 
+         */
+        public void setStart(int value) {
+            this.start = value;
+        }
 
-    /**
-     * Gets the value of the bgColour property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getBgColour()
-    {
-      return bgColour;
-    }
+        /**
+         * Gets the value of the end property.
+         * 
+         */
+        public int getEnd() {
+            return end;
+        }
 
-    /**
-     * Sets the value of the bgColour property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setBgColour(Integer value)
-    {
-      this.bgColour = value;
-    }
+        /**
+         * Sets the value of the end property.
+         * 
+         */
+        public void setEnd(int value) {
+            this.end = value;
+        }
 
-    /**
-     * Gets the value of the scaleFactor property.
-     * 
-     * @return possible object is {@link Float }
-     * 
-     */
-    public Float getScaleFactor()
-    {
-      return scaleFactor;
-    }
+        /**
+         * Gets the value of the id property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getId() {
+            return id;
+        }
 
-    /**
-     * Sets the value of the scaleFactor property.
-     * 
-     * @param value
-     *          allowed object is {@link Float }
-     * 
-     */
-    public void setScaleFactor(Float value)
-    {
-      this.scaleFactor = value;
-    }
+        /**
+         * Sets the value of the id property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setId(String value) {
+            this.id = value;
+        }
 
-    /**
-     * Gets the value of the showLabels property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowLabels()
-    {
-      return showLabels;
-    }
+        /**
+         * Gets the value of the hidden property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isHidden() {
+            return hidden;
+        }
 
-    /**
-     * Sets the value of the showLabels property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowLabels(Boolean value)
-    {
-      this.showLabels = value;
-    }
+        /**
+         * Sets the value of the hidden property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setHidden(Boolean value) {
+            this.hidden = value;
+        }
 
-    /**
-     * Gets the value of the linkToAllViews property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isLinkToAllViews()
-    {
-      return linkToAllViews;
-    }
+        /**
+         * Gets the value of the viewreference property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isViewreference() {
+            return viewreference;
+        }
 
-    /**
-     * Sets the value of the linkToAllViews property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setLinkToAllViews(Boolean value)
-    {
-      this.linkToAllViews = value;
-    }
+        /**
+         * Sets the value of the viewreference property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setViewreference(Boolean value) {
+            this.viewreference = value;
+        }
 
-    /**
-     * Gets the value of the includeGaps property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isIncludeGaps()
-    {
-      return includeGaps;
-    }
 
-    /**
-     * Sets the value of the includeGaps property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setIncludeGaps(Boolean value)
-    {
-      this.includeGaps = value;
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;extension base="{www.jalview.org}pdbentry"&amp;gt;
+         *       &amp;lt;sequence&amp;gt;
+         *         &amp;lt;element name="structureState" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+         *           &amp;lt;complexType&amp;gt;
+         *             &amp;lt;simpleContent&amp;gt;
+         *               &amp;lt;extension base="&amp;lt;http://www.w3.org/2001/XMLSchema&amp;gt;string"&amp;gt;
+         *                 &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+         *                 &amp;lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *                 &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *                 &amp;lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+         *                 &amp;lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+         *                 &amp;lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+         *                 &amp;lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *               &amp;lt;/extension&amp;gt;
+         *             &amp;lt;/simpleContent&amp;gt;
+         *           &amp;lt;/complexType&amp;gt;
+         *         &amp;lt;/element&amp;gt;
+         *       &amp;lt;/sequence&amp;gt;
+         *     &amp;lt;/extension&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "", propOrder = {
+            "structureState"
+        })
+        public static class Pdbids
+            extends Pdbentry
+        {
 
-    /**
-     * Gets the value of the matchGaps property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isMatchGaps()
-    {
-      return matchGaps;
-    }
+            @XmlElement(namespace = "www.jalview.org")
+            protected List<JalviewModel.JSeq.Pdbids.StructureState> structureState;
+
+            /**
+             * Gets the value of the structureState property.
+             * 
+             * &lt;p&gt;
+             * This accessor method returns a reference to the live list,
+             * not a snapshot. Therefore any modification you make to the
+             * returned list will be present inside the JAXB object.
+             * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the structureState property.
+             * 
+             * &lt;p&gt;
+             * For example, to add a new item, do as follows:
+             * &lt;pre&gt;
+             *    getStructureState().add(newItem);
+             * &lt;/pre&gt;
+             * 
+             * 
+             * &lt;p&gt;
+             * Objects of the following type(s) are allowed in the list
+             * {@link JalviewModel.JSeq.Pdbids.StructureState }
+             * 
+             * 
+             */
+            public List<JalviewModel.JSeq.Pdbids.StructureState> getStructureState() {
+                if (structureState == null) {
+                    structureState = new ArrayList<JalviewModel.JSeq.Pdbids.StructureState>();
+                }
+                return this.structureState;
+            }
+
+
+            /**
+             * &lt;p&gt;Java class for anonymous complex type.
+             * 
+             * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+             * 
+             * &lt;pre&gt;
+             * &amp;lt;complexType&amp;gt;
+             *   &amp;lt;simpleContent&amp;gt;
+             *     &amp;lt;extension base="&amp;lt;http://www.w3.org/2001/XMLSchema&amp;gt;string"&amp;gt;
+             *       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+             *       &amp;lt;attribute name="visible" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+             *       &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+             *       &amp;lt;attribute name="alignwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+             *       &amp;lt;attribute name="colourwithAlignPanel" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+             *       &amp;lt;attribute name="colourByJmol" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+             *       &amp;lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+             *     &amp;lt;/extension&amp;gt;
+             *   &amp;lt;/simpleContent&amp;gt;
+             * &amp;lt;/complexType&amp;gt;
+             * &lt;/pre&gt;
+             * 
+             * 
+             */
+            @XmlAccessorType(XmlAccessType.FIELD)
+            @XmlType(name = "", propOrder = {
+                "value"
+            })
+            public static class StructureState {
+
+                @XmlValue
+                protected String value;
+                @XmlAttribute(name = "visible")
+                protected Boolean visible;
+                @XmlAttribute(name = "viewId")
+                protected String viewId;
+                @XmlAttribute(name = "alignwithAlignPanel")
+                protected Boolean alignwithAlignPanel;
+                @XmlAttribute(name = "colourwithAlignPanel")
+                protected Boolean colourwithAlignPanel;
+                @XmlAttribute(name = "colourByJmol")
+                protected Boolean colourByJmol;
+                @XmlAttribute(name = "type")
+                protected String type;
+                @XmlAttribute(name = "width")
+                protected Integer width;
+                @XmlAttribute(name = "height")
+                protected Integer height;
+                @XmlAttribute(name = "xpos")
+                protected Integer xpos;
+                @XmlAttribute(name = "ypos")
+                protected Integer ypos;
+
+                /**
+                 * Gets the value of the value property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link String }
+                 *     
+                 */
+                public String getValue() {
+                    return value;
+                }
+
+                /**
+                 * Sets the value of the value property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link String }
+                 *     
+                 */
+                public void setValue(String value) {
+                    this.value = value;
+                }
+
+                /**
+                 * Gets the value of the visible property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public Boolean isVisible() {
+                    return visible;
+                }
+
+                /**
+                 * Sets the value of the visible property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public void setVisible(Boolean value) {
+                    this.visible = value;
+                }
+
+                /**
+                 * Gets the value of the viewId property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link String }
+                 *     
+                 */
+                public String getViewId() {
+                    return viewId;
+                }
+
+                /**
+                 * Sets the value of the viewId property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link String }
+                 *     
+                 */
+                public void setViewId(String value) {
+                    this.viewId = value;
+                }
+
+                /**
+                 * Gets the value of the alignwithAlignPanel property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public boolean isAlignwithAlignPanel() {
+                    if (alignwithAlignPanel == null) {
+                        return true;
+                    } else {
+                        return alignwithAlignPanel;
+                    }
+                }
+
+                /**
+                 * Sets the value of the alignwithAlignPanel property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public void setAlignwithAlignPanel(Boolean value) {
+                    this.alignwithAlignPanel = value;
+                }
+
+                /**
+                 * Gets the value of the colourwithAlignPanel property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public boolean isColourwithAlignPanel() {
+                    if (colourwithAlignPanel == null) {
+                        return false;
+                    } else {
+                        return colourwithAlignPanel;
+                    }
+                }
+
+                /**
+                 * Sets the value of the colourwithAlignPanel property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public void setColourwithAlignPanel(Boolean value) {
+                    this.colourwithAlignPanel = value;
+                }
+
+                /**
+                 * Gets the value of the colourByJmol property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public boolean isColourByJmol() {
+                    if (colourByJmol == null) {
+                        return true;
+                    } else {
+                        return colourByJmol;
+                    }
+                }
+
+                /**
+                 * Sets the value of the colourByJmol property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public void setColourByJmol(Boolean value) {
+                    this.colourByJmol = value;
+                }
+
+                /**
+                 * Gets the value of the type property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link String }
+                 *     
+                 */
+                public String getType() {
+                    return type;
+                }
+
+                /**
+                 * Sets the value of the type property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link String }
+                 *     
+                 */
+                public void setType(String value) {
+                    this.type = value;
+                }
+
+                /**
+                 * Gets the value of the width property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public Integer getWidth() {
+                    return width;
+                }
+
+                /**
+                 * Sets the value of the width property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public void setWidth(Integer value) {
+                    this.width = value;
+                }
+
+                /**
+                 * Gets the value of the height property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public Integer getHeight() {
+                    return height;
+                }
+
+                /**
+                 * Sets the value of the height property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public void setHeight(Integer value) {
+                    this.height = value;
+                }
+
+                /**
+                 * Gets the value of the xpos property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public Integer getXpos() {
+                    return xpos;
+                }
+
+                /**
+                 * Sets the value of the xpos property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public void setXpos(Integer value) {
+                    this.xpos = value;
+                }
+
+                /**
+                 * Gets the value of the ypos property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public Integer getYpos() {
+                    return ypos;
+                }
+
+                /**
+                 * Sets the value of the ypos property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Integer }
+                 *     
+                 */
+                public void setYpos(Integer value) {
+                    this.ypos = value;
+                }
+
+            }
 
-    /**
-     * Sets the value of the matchGaps property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setMatchGaps(Boolean value)
-    {
-      this.matchGaps = value;
-    }
+        }
 
-    /**
-     * Gets the value of the includeGappedColumns property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isIncludeGappedColumns()
-    {
-      return includeGappedColumns;
-    }
 
-    /**
-     * Sets the value of the includeGappedColumns property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setIncludeGappedColumns(Boolean value)
-    {
-      this.includeGappedColumns = value;
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;sequence&amp;gt;
+         *         &amp;lt;element name="secondaryStructure" maxOccurs="unbounded"&amp;gt;
+         *           &amp;lt;complexType&amp;gt;
+         *             &amp;lt;complexContent&amp;gt;
+         *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *                 &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *                 &amp;lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *                 &amp;lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *                 &amp;lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *               &amp;lt;/restriction&amp;gt;
+         *             &amp;lt;/complexContent&amp;gt;
+         *           &amp;lt;/complexType&amp;gt;
+         *         &amp;lt;/element&amp;gt;
+         *       &amp;lt;/sequence&amp;gt;
+         *       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+         *       &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *       &amp;lt;attribute name="viewId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *       &amp;lt;attribute name="dividerLocation" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="selectedRna" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "", propOrder = {
+            "secondaryStructure"
+        })
+        public static class RnaViewer {
+
+            @XmlElement(namespace = "www.jalview.org", required = true)
+            protected List<JalviewModel.JSeq.RnaViewer.SecondaryStructure> secondaryStructure;
+            @XmlAttribute(name = "title")
+            protected String title;
+            @XmlAttribute(name = "viewId")
+            protected String viewId;
+            @XmlAttribute(name = "dividerLocation")
+            protected Integer dividerLocation;
+            @XmlAttribute(name = "selectedRna")
+            protected Integer selectedRna;
+            @XmlAttribute(name = "width")
+            protected Integer width;
+            @XmlAttribute(name = "height")
+            protected Integer height;
+            @XmlAttribute(name = "xpos")
+            protected Integer xpos;
+            @XmlAttribute(name = "ypos")
+            protected Integer ypos;
+
+            /**
+             * Gets the value of the secondaryStructure property.
+             * 
+             * &lt;p&gt;
+             * This accessor method returns a reference to the live list,
+             * not a snapshot. Therefore any modification you make to the
+             * returned list will be present inside the JAXB object.
+             * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the secondaryStructure property.
+             * 
+             * &lt;p&gt;
+             * For example, to add a new item, do as follows:
+             * &lt;pre&gt;
+             *    getSecondaryStructure().add(newItem);
+             * &lt;/pre&gt;
+             * 
+             * 
+             * &lt;p&gt;
+             * Objects of the following type(s) are allowed in the list
+             * {@link JalviewModel.JSeq.RnaViewer.SecondaryStructure }
+             * 
+             * 
+             */
+            public List<JalviewModel.JSeq.RnaViewer.SecondaryStructure> getSecondaryStructure() {
+                if (secondaryStructure == null) {
+                    secondaryStructure = new ArrayList<JalviewModel.JSeq.RnaViewer.SecondaryStructure>();
+                }
+                return this.secondaryStructure;
+            }
+
+            /**
+             * Gets the value of the title property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getTitle() {
+                return title;
+            }
+
+            /**
+             * Sets the value of the title property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setTitle(String value) {
+                this.title = value;
+            }
+
+            /**
+             * Gets the value of the viewId property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getViewId() {
+                return viewId;
+            }
+
+            /**
+             * Sets the value of the viewId property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setViewId(String value) {
+                this.viewId = value;
+            }
+
+            /**
+             * Gets the value of the dividerLocation property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getDividerLocation() {
+                return dividerLocation;
+            }
+
+            /**
+             * Sets the value of the dividerLocation property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setDividerLocation(Integer value) {
+                this.dividerLocation = value;
+            }
+
+            /**
+             * Gets the value of the selectedRna property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getSelectedRna() {
+                return selectedRna;
+            }
+
+            /**
+             * Sets the value of the selectedRna property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setSelectedRna(Integer value) {
+                this.selectedRna = value;
+            }
+
+            /**
+             * Gets the value of the width property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getWidth() {
+                return width;
+            }
+
+            /**
+             * Sets the value of the width property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setWidth(Integer value) {
+                this.width = value;
+            }
+
+            /**
+             * Gets the value of the height property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getHeight() {
+                return height;
+            }
+
+            /**
+             * Sets the value of the height property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setHeight(Integer value) {
+                this.height = value;
+            }
+
+            /**
+             * Gets the value of the xpos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getXpos() {
+                return xpos;
+            }
+
+            /**
+             * Sets the value of the xpos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setXpos(Integer value) {
+                this.xpos = value;
+            }
+
+            /**
+             * Gets the value of the ypos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getYpos() {
+                return ypos;
+            }
+
+            /**
+             * Sets the value of the ypos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setYpos(Integer value) {
+                this.ypos = value;
+            }
+
+
+            /**
+             * &lt;p&gt;Java class for anonymous complex type.
+             * 
+             * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+             * 
+             * &lt;pre&gt;
+             * &amp;lt;complexType&amp;gt;
+             *   &amp;lt;complexContent&amp;gt;
+             *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+             *       &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+             *       &amp;lt;attribute name="annotationId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+             *       &amp;lt;attribute name="gapped" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+             *       &amp;lt;attribute name="viewerState" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+             *     &amp;lt;/restriction&amp;gt;
+             *   &amp;lt;/complexContent&amp;gt;
+             * &amp;lt;/complexType&amp;gt;
+             * &lt;/pre&gt;
+             * 
+             * 
+             */
+            @XmlAccessorType(XmlAccessType.FIELD)
+            @XmlType(name = "")
+            public static class SecondaryStructure {
+
+                @XmlAttribute(name = "title")
+                protected String title;
+                @XmlAttribute(name = "annotationId", required = true)
+                protected String annotationId;
+                @XmlAttribute(name = "gapped")
+                protected Boolean gapped;
+                @XmlAttribute(name = "viewerState")
+                protected String viewerState;
+
+                /**
+                 * Gets the value of the title property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link String }
+                 *     
+                 */
+                public String getTitle() {
+                    return title;
+                }
+
+                /**
+                 * Sets the value of the title property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link String }
+                 *     
+                 */
+                public void setTitle(String value) {
+                    this.title = value;
+                }
+
+                /**
+                 * Gets the value of the annotationId property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link String }
+                 *     
+                 */
+                public String getAnnotationId() {
+                    return annotationId;
+                }
+
+                /**
+                 * Sets the value of the annotationId property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link String }
+                 *     
+                 */
+                public void setAnnotationId(String value) {
+                    this.annotationId = value;
+                }
+
+                /**
+                 * Gets the value of the gapped property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public Boolean isGapped() {
+                    return gapped;
+                }
+
+                /**
+                 * Sets the value of the gapped property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link Boolean }
+                 *     
+                 */
+                public void setGapped(Boolean value) {
+                    this.gapped = value;
+                }
+
+                /**
+                 * Gets the value of the viewerState property.
+                 * 
+                 * @return
+                 *     possible object is
+                 *     {@link String }
+                 *     
+                 */
+                public String getViewerState() {
+                    return viewerState;
+                }
+
+                /**
+                 * Sets the value of the viewerState property.
+                 * 
+                 * @param value
+                 *     allowed object is
+                 *     {@link String }
+                 *     
+                 */
+                public void setViewerState(String value) {
+                    this.viewerState = value;
+                }
+
+            }
 
-    /**
-     * Gets the value of the denominateByShortestLength property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isDenominateByShortestLength()
-    {
-      return denominateByShortestLength;
-    }
+        }
 
-    /**
-     * Sets the value of the denominateByShortestLength property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setDenominateByShortestLength(Boolean value)
-    {
-      this.denominateByShortestLength = value;
     }
 
-    /**
-     * Gets the value of the width property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getWidth()
-    {
-      return width;
-    }
 
     /**
-     * Sets the value of the width property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="sequencePoint" maxOccurs="unbounded"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+     *                 &amp;lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="axis" maxOccurs="3" minOccurs="3"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="seqPointMin"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="seqPointMax"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="pcaData" type="{www.jalview.org}PcaDataType"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attGroup ref="{www.jalview.org}SimilarityParams"/&amp;gt;
+     *       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+     *       &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="scoreModelName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="xDim" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="yDim" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="zDim" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="scaleFactor" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *       &amp;lt;attribute name="showLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link Integer }
      * 
      */
-    public void setWidth(Integer value)
-    {
-      this.width = value;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "sequencePoint",
+        "axis",
+        "seqPointMin",
+        "seqPointMax",
+        "pcaData"
+    })
+    public static class PcaViewer {
+
+        @XmlElement(namespace = "www.jalview.org", required = true)
+        protected List<JalviewModel.PcaViewer.SequencePoint> sequencePoint;
+        @XmlElement(namespace = "www.jalview.org", required = true)
+        protected List<JalviewModel.PcaViewer.Axis> axis;
+        @XmlElement(namespace = "www.jalview.org", required = true)
+        protected JalviewModel.PcaViewer.SeqPointMin seqPointMin;
+        @XmlElement(namespace = "www.jalview.org", required = true)
+        protected JalviewModel.PcaViewer.SeqPointMax seqPointMax;
+        @XmlElement(namespace = "www.jalview.org", required = true)
+        protected PcaDataType pcaData;
+        @XmlAttribute(name = "title")
+        protected String title;
+        @XmlAttribute(name = "scoreModelName")
+        protected String scoreModelName;
+        @XmlAttribute(name = "xDim")
+        protected Integer xDim;
+        @XmlAttribute(name = "yDim")
+        protected Integer yDim;
+        @XmlAttribute(name = "zDim")
+        protected Integer zDim;
+        @XmlAttribute(name = "bgColour")
+        protected Integer bgColour;
+        @XmlAttribute(name = "scaleFactor")
+        protected Float scaleFactor;
+        @XmlAttribute(name = "showLabels")
+        protected Boolean showLabels;
+        @XmlAttribute(name = "linkToAllViews")
+        protected Boolean linkToAllViews;
+        @XmlAttribute(name = "includeGaps")
+        protected Boolean includeGaps;
+        @XmlAttribute(name = "matchGaps")
+        protected Boolean matchGaps;
+        @XmlAttribute(name = "includeGappedColumns")
+        protected Boolean includeGappedColumns;
+        @XmlAttribute(name = "denominateByShortestLength")
+        protected Boolean denominateByShortestLength;
+        @XmlAttribute(name = "width")
+        protected Integer width;
+        @XmlAttribute(name = "height")
+        protected Integer height;
+        @XmlAttribute(name = "xpos")
+        protected Integer xpos;
+        @XmlAttribute(name = "ypos")
+        protected Integer ypos;
 
-    /**
-     * Gets the value of the height property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getHeight()
-    {
-      return height;
-    }
+        /**
+         * Gets the value of the sequencePoint property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the sequencePoint property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getSequencePoint().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.PcaViewer.SequencePoint }
+         * 
+         * 
+         */
+        public List<JalviewModel.PcaViewer.SequencePoint> getSequencePoint() {
+            if (sequencePoint == null) {
+                sequencePoint = new ArrayList<JalviewModel.PcaViewer.SequencePoint>();
+            }
+            return this.sequencePoint;
+        }
 
-    /**
-     * Sets the value of the height property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setHeight(Integer value)
-    {
-      this.height = value;
-    }
+        /**
+         * Gets the value of the axis property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the axis property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getAxis().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.PcaViewer.Axis }
+         * 
+         * 
+         */
+        public List<JalviewModel.PcaViewer.Axis> getAxis() {
+            if (axis == null) {
+                axis = new ArrayList<JalviewModel.PcaViewer.Axis>();
+            }
+            return this.axis;
+        }
 
-    /**
-     * Gets the value of the xpos property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getXpos()
-    {
-      return xpos;
-    }
+        /**
+         * Gets the value of the seqPointMin property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link JalviewModel.PcaViewer.SeqPointMin }
+         *     
+         */
+        public JalviewModel.PcaViewer.SeqPointMin getSeqPointMin() {
+            return seqPointMin;
+        }
 
-    /**
-     * Sets the value of the xpos property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setXpos(Integer value)
-    {
-      this.xpos = value;
-    }
+        /**
+         * Sets the value of the seqPointMin property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link JalviewModel.PcaViewer.SeqPointMin }
+         *     
+         */
+        public void setSeqPointMin(JalviewModel.PcaViewer.SeqPointMin value) {
+            this.seqPointMin = value;
+        }
 
-    /**
-     * Gets the value of the ypos property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getYpos()
-    {
-      return ypos;
-    }
+        /**
+         * Gets the value of the seqPointMax property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link JalviewModel.PcaViewer.SeqPointMax }
+         *     
+         */
+        public JalviewModel.PcaViewer.SeqPointMax getSeqPointMax() {
+            return seqPointMax;
+        }
 
-    /**
-     * Sets the value of the ypos property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setYpos(Integer value)
-    {
-      this.ypos = value;
-    }
+        /**
+         * Sets the value of the seqPointMax property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link JalviewModel.PcaViewer.SeqPointMax }
+         *     
+         */
+        public void setSeqPointMax(JalviewModel.PcaViewer.SeqPointMax value) {
+            this.seqPointMax = value;
+        }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attGroup ref="{www.jalview.org}position"/>
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class Axis
-    {
-
-      @XmlAttribute(name = "xPos")
-      protected Float xPos;
-
-      @XmlAttribute(name = "yPos")
-      protected Float yPos;
-
-      @XmlAttribute(name = "zPos")
-      protected Float zPos;
-
-      /**
-       * Gets the value of the xPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getXPos()
-      {
-        return xPos;
-      }
-
-      /**
-       * Sets the value of the xPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setXPos(Float value)
-      {
-        this.xPos = value;
-      }
-
-      /**
-       * Gets the value of the yPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getYPos()
-      {
-        return yPos;
-      }
-
-      /**
-       * Sets the value of the yPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setYPos(Float value)
-      {
-        this.yPos = value;
-      }
-
-      /**
-       * Gets the value of the zPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getZPos()
-      {
-        return zPos;
-      }
-
-      /**
-       * Sets the value of the zPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setZPos(Float value)
-      {
-        this.zPos = value;
-      }
+        /**
+         * Gets the value of the pcaData property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link PcaDataType }
+         *     
+         */
+        public PcaDataType getPcaData() {
+            return pcaData;
+        }
 
-    }
+        /**
+         * Sets the value of the pcaData property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link PcaDataType }
+         *     
+         */
+        public void setPcaData(PcaDataType value) {
+            this.pcaData = value;
+        }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attGroup ref="{www.jalview.org}position"/>
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class SeqPointMax
-    {
-
-      @XmlAttribute(name = "xPos")
-      protected Float xPos;
-
-      @XmlAttribute(name = "yPos")
-      protected Float yPos;
-
-      @XmlAttribute(name = "zPos")
-      protected Float zPos;
-
-      /**
-       * Gets the value of the xPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getXPos()
-      {
-        return xPos;
-      }
-
-      /**
-       * Sets the value of the xPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setXPos(Float value)
-      {
-        this.xPos = value;
-      }
-
-      /**
-       * Gets the value of the yPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getYPos()
-      {
-        return yPos;
-      }
-
-      /**
-       * Sets the value of the yPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setYPos(Float value)
-      {
-        this.yPos = value;
-      }
-
-      /**
-       * Gets the value of the zPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getZPos()
-      {
-        return zPos;
-      }
-
-      /**
-       * Sets the value of the zPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setZPos(Float value)
-      {
-        this.zPos = value;
-      }
+        /**
+         * Gets the value of the title property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getTitle() {
+            return title;
+        }
 
-    }
+        /**
+         * Sets the value of the title property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setTitle(String value) {
+            this.title = value;
+        }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attGroup ref="{www.jalview.org}position"/>
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class SeqPointMin
-    {
-
-      @XmlAttribute(name = "xPos")
-      protected Float xPos;
-
-      @XmlAttribute(name = "yPos")
-      protected Float yPos;
-
-      @XmlAttribute(name = "zPos")
-      protected Float zPos;
-
-      /**
-       * Gets the value of the xPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getXPos()
-      {
-        return xPos;
-      }
-
-      /**
-       * Sets the value of the xPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setXPos(Float value)
-      {
-        this.xPos = value;
-      }
-
-      /**
-       * Gets the value of the yPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getYPos()
-      {
-        return yPos;
-      }
-
-      /**
-       * Sets the value of the yPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setYPos(Float value)
-      {
-        this.yPos = value;
-      }
-
-      /**
-       * Gets the value of the zPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getZPos()
-      {
-        return zPos;
-      }
-
-      /**
-       * Sets the value of the zPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setZPos(Float value)
-      {
-        this.zPos = value;
-      }
+        /**
+         * Gets the value of the scoreModelName property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getScoreModelName() {
+            return scoreModelName;
+        }
 
-    }
+        /**
+         * Sets the value of the scoreModelName property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setScoreModelName(String value) {
+            this.scoreModelName = value;
+        }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attGroup ref="{www.jalview.org}position"/>
-     *       &lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class SequencePoint
-    {
-
-      @XmlAttribute(name = "sequenceRef")
-      protected String sequenceRef;
-
-      @XmlAttribute(name = "xPos")
-      protected Float xPos;
-
-      @XmlAttribute(name = "yPos")
-      protected Float yPos;
-
-      @XmlAttribute(name = "zPos")
-      protected Float zPos;
-
-      /**
-       * Gets the value of the sequenceRef property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getSequenceRef()
-      {
-        return sequenceRef;
-      }
-
-      /**
-       * Sets the value of the sequenceRef property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setSequenceRef(String value)
-      {
-        this.sequenceRef = value;
-      }
-
-      /**
-       * Gets the value of the xPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getXPos()
-      {
-        return xPos;
-      }
-
-      /**
-       * Sets the value of the xPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setXPos(Float value)
-      {
-        this.xPos = value;
-      }
-
-      /**
-       * Gets the value of the yPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getYPos()
-      {
-        return yPos;
-      }
-
-      /**
-       * Sets the value of the yPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setYPos(Float value)
-      {
-        this.yPos = value;
-      }
-
-      /**
-       * Gets the value of the zPos property.
-       * 
-       * @return possible object is {@link Float }
-       * 
-       */
-      public Float getZPos()
-      {
-        return zPos;
-      }
-
-      /**
-       * Sets the value of the zPos property.
-       * 
-       * @param value
-       *          allowed object is {@link Float }
-       * 
-       */
-      public void setZPos(Float value)
-      {
-        this.zPos = value;
-      }
+        /**
+         * Gets the value of the xDim property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getXDim() {
+            return xDim;
+        }
 
-    }
+        /**
+         * Sets the value of the xDim property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setXDim(Integer value) {
+            this.xDim = value;
+        }
 
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence minOccurs="0">
-   *         &lt;element name="title" type="{http://www.w3.org/2001/XMLSchema}string"/>
-   *         &lt;element name="newick" type="{http://www.w3.org/2001/XMLSchema}string"/>
-   *       &lt;/sequence>
-   *       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-   *       &lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *       &lt;attribute name="showBootstrap" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showDistances" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="markUnlinked" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="fitToWindow" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="currentTree" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="columnWise" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="columnReference" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
-   *       &lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "title", "newick" })
-  public static class Tree
-  {
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected String title;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected String newick;
-
-    @XmlAttribute(name = "fontName")
-    protected String fontName;
-
-    @XmlAttribute(name = "fontSize")
-    protected Integer fontSize;
-
-    @XmlAttribute(name = "fontStyle")
-    protected Integer fontStyle;
-
-    @XmlAttribute(name = "threshold")
-    protected Float threshold;
-
-    @XmlAttribute(name = "showBootstrap")
-    protected Boolean showBootstrap;
-
-    @XmlAttribute(name = "showDistances")
-    protected Boolean showDistances;
-
-    @XmlAttribute(name = "markUnlinked")
-    protected Boolean markUnlinked;
-
-    @XmlAttribute(name = "fitToWindow")
-    protected Boolean fitToWindow;
-
-    @XmlAttribute(name = "currentTree")
-    protected Boolean currentTree;
-
-    @XmlAttribute(name = "columnWise")
-    protected Boolean columnWise;
-
-    @XmlAttribute(name = "columnReference")
-    protected String columnReference;
-
-    @XmlAttribute(name = "id")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    @XmlSchemaType(name = "ID")
-    protected String id;
-
-    @XmlAttribute(name = "linkToAllViews")
-    protected Boolean linkToAllViews;
-
-    @XmlAttribute(name = "width")
-    protected Integer width;
-
-    @XmlAttribute(name = "height")
-    protected Integer height;
-
-    @XmlAttribute(name = "xpos")
-    protected Integer xpos;
-
-    @XmlAttribute(name = "ypos")
-    protected Integer ypos;
+        /**
+         * Gets the value of the yDim property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getYDim() {
+            return yDim;
+        }
 
-    /**
-     * Gets the value of the title property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getTitle()
-    {
-      return title;
-    }
+        /**
+         * Sets the value of the yDim property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setYDim(Integer value) {
+            this.yDim = value;
+        }
 
-    /**
-     * Sets the value of the title property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setTitle(String value)
-    {
-      this.title = value;
-    }
+        /**
+         * Gets the value of the zDim property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getZDim() {
+            return zDim;
+        }
 
-    /**
-     * Gets the value of the newick property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getNewick()
-    {
-      return newick;
-    }
+        /**
+         * Sets the value of the zDim property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setZDim(Integer value) {
+            this.zDim = value;
+        }
 
-    /**
-     * Sets the value of the newick property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setNewick(String value)
-    {
-      this.newick = value;
-    }
+        /**
+         * Gets the value of the bgColour property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getBgColour() {
+            return bgColour;
+        }
 
-    /**
-     * Gets the value of the fontName property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getFontName()
-    {
-      return fontName;
-    }
+        /**
+         * Sets the value of the bgColour property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setBgColour(Integer value) {
+            this.bgColour = value;
+        }
 
-    /**
-     * Sets the value of the fontName property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setFontName(String value)
-    {
-      this.fontName = value;
-    }
+        /**
+         * Gets the value of the scaleFactor property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Float }
+         *     
+         */
+        public Float getScaleFactor() {
+            return scaleFactor;
+        }
 
-    /**
-     * Gets the value of the fontSize property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getFontSize()
-    {
-      return fontSize;
-    }
+        /**
+         * Sets the value of the scaleFactor property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Float }
+         *     
+         */
+        public void setScaleFactor(Float value) {
+            this.scaleFactor = value;
+        }
 
-    /**
-     * Sets the value of the fontSize property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setFontSize(Integer value)
-    {
-      this.fontSize = value;
-    }
+        /**
+         * Gets the value of the showLabels property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowLabels() {
+            return showLabels;
+        }
 
-    /**
-     * Gets the value of the fontStyle property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getFontStyle()
-    {
-      return fontStyle;
-    }
+        /**
+         * Sets the value of the showLabels property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowLabels(Boolean value) {
+            this.showLabels = value;
+        }
 
-    /**
-     * Sets the value of the fontStyle property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setFontStyle(Integer value)
-    {
-      this.fontStyle = value;
-    }
+        /**
+         * Gets the value of the linkToAllViews property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isLinkToAllViews() {
+            return linkToAllViews;
+        }
 
-    /**
-     * Gets the value of the threshold property.
-     * 
-     * @return possible object is {@link Float }
-     * 
-     */
-    public Float getThreshold()
-    {
-      return threshold;
-    }
+        /**
+         * Sets the value of the linkToAllViews property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setLinkToAllViews(Boolean value) {
+            this.linkToAllViews = value;
+        }
 
-    /**
-     * Sets the value of the threshold property.
-     * 
-     * @param value
-     *          allowed object is {@link Float }
-     * 
-     */
-    public void setThreshold(Float value)
-    {
-      this.threshold = value;
-    }
+        /**
+         * Gets the value of the includeGaps property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isIncludeGaps() {
+            return includeGaps;
+        }
 
-    /**
-     * Gets the value of the showBootstrap property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowBootstrap()
-    {
-      return showBootstrap;
-    }
+        /**
+         * Sets the value of the includeGaps property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setIncludeGaps(Boolean value) {
+            this.includeGaps = value;
+        }
 
-    /**
-     * Sets the value of the showBootstrap property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowBootstrap(Boolean value)
-    {
-      this.showBootstrap = value;
-    }
+        /**
+         * Gets the value of the matchGaps property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isMatchGaps() {
+            return matchGaps;
+        }
 
-    /**
-     * Gets the value of the showDistances property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowDistances()
-    {
-      return showDistances;
-    }
+        /**
+         * Sets the value of the matchGaps property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setMatchGaps(Boolean value) {
+            this.matchGaps = value;
+        }
 
-    /**
-     * Sets the value of the showDistances property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowDistances(Boolean value)
-    {
-      this.showDistances = value;
-    }
+        /**
+         * Gets the value of the includeGappedColumns property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isIncludeGappedColumns() {
+            return includeGappedColumns;
+        }
 
-    /**
-     * Gets the value of the markUnlinked property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isMarkUnlinked()
-    {
-      return markUnlinked;
-    }
+        /**
+         * Sets the value of the includeGappedColumns property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setIncludeGappedColumns(Boolean value) {
+            this.includeGappedColumns = value;
+        }
 
-    /**
-     * Sets the value of the markUnlinked property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setMarkUnlinked(Boolean value)
-    {
-      this.markUnlinked = value;
-    }
+        /**
+         * Gets the value of the denominateByShortestLength property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isDenominateByShortestLength() {
+            return denominateByShortestLength;
+        }
 
-    /**
-     * Gets the value of the fitToWindow property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isFitToWindow()
-    {
-      return fitToWindow;
-    }
+        /**
+         * Sets the value of the denominateByShortestLength property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setDenominateByShortestLength(Boolean value) {
+            this.denominateByShortestLength = value;
+        }
 
-    /**
-     * Sets the value of the fitToWindow property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setFitToWindow(Boolean value)
-    {
-      this.fitToWindow = value;
-    }
+        /**
+         * Gets the value of the width property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getWidth() {
+            return width;
+        }
 
-    /**
-     * Gets the value of the currentTree property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isCurrentTree()
-    {
-      return currentTree;
-    }
+        /**
+         * Sets the value of the width property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setWidth(Integer value) {
+            this.width = value;
+        }
 
-    /**
-     * Sets the value of the currentTree property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setCurrentTree(Boolean value)
-    {
-      this.currentTree = value;
-    }
+        /**
+         * Gets the value of the height property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getHeight() {
+            return height;
+        }
 
-    /**
-     * Gets the value of the columnWise property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isColumnWise()
-    {
-      if (columnWise == null)
-      {
-        return false;
-      }
-      else
-      {
-        return columnWise;
-      }
-    }
+        /**
+         * Sets the value of the height property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setHeight(Integer value) {
+            this.height = value;
+        }
 
-    /**
-     * Sets the value of the columnWise property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setColumnWise(Boolean value)
-    {
-      this.columnWise = value;
-    }
+        /**
+         * Gets the value of the xpos property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getXpos() {
+            return xpos;
+        }
 
-    /**
-     * Gets the value of the columnReference property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getColumnReference()
-    {
-      return columnReference;
-    }
+        /**
+         * Sets the value of the xpos property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setXpos(Integer value) {
+            this.xpos = value;
+        }
 
-    /**
-     * Sets the value of the columnReference property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setColumnReference(String value)
-    {
-      this.columnReference = value;
-    }
+        /**
+         * Gets the value of the ypos property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getYpos() {
+            return ypos;
+        }
 
-    /**
-     * Gets the value of the id property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getId()
-    {
-      return id;
-    }
+        /**
+         * Sets the value of the ypos property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setYpos(Integer value) {
+            this.ypos = value;
+        }
 
-    /**
-     * Sets the value of the id property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setId(String value)
-    {
-      this.id = value;
-    }
 
-    /**
-     * Gets the value of the linkToAllViews property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isLinkToAllViews()
-    {
-      if (linkToAllViews == null)
-      {
-        return false;
-      }
-      else
-      {
-        return linkToAllViews;
-      }
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class Axis {
+
+            @XmlAttribute(name = "xPos")
+            protected Float xPos;
+            @XmlAttribute(name = "yPos")
+            protected Float yPos;
+            @XmlAttribute(name = "zPos")
+            protected Float zPos;
+
+            /**
+             * Gets the value of the xPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getXPos() {
+                return xPos;
+            }
+
+            /**
+             * Sets the value of the xPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setXPos(Float value) {
+                this.xPos = value;
+            }
+
+            /**
+             * Gets the value of the yPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getYPos() {
+                return yPos;
+            }
+
+            /**
+             * Sets the value of the yPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setYPos(Float value) {
+                this.yPos = value;
+            }
+
+            /**
+             * Gets the value of the zPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getZPos() {
+                return zPos;
+            }
+
+            /**
+             * Sets the value of the zPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setZPos(Float value) {
+                this.zPos = value;
+            }
 
-    /**
-     * Sets the value of the linkToAllViews property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setLinkToAllViews(Boolean value)
-    {
-      this.linkToAllViews = value;
-    }
+        }
 
-    /**
-     * Gets the value of the width property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getWidth()
-    {
-      return width;
-    }
 
-    /**
-     * Sets the value of the width property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setWidth(Integer value)
-    {
-      this.width = value;
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class SeqPointMax {
+
+            @XmlAttribute(name = "xPos")
+            protected Float xPos;
+            @XmlAttribute(name = "yPos")
+            protected Float yPos;
+            @XmlAttribute(name = "zPos")
+            protected Float zPos;
+
+            /**
+             * Gets the value of the xPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getXPos() {
+                return xPos;
+            }
+
+            /**
+             * Sets the value of the xPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setXPos(Float value) {
+                this.xPos = value;
+            }
+
+            /**
+             * Gets the value of the yPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getYPos() {
+                return yPos;
+            }
+
+            /**
+             * Sets the value of the yPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setYPos(Float value) {
+                this.yPos = value;
+            }
+
+            /**
+             * Gets the value of the zPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getZPos() {
+                return zPos;
+            }
+
+            /**
+             * Sets the value of the zPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setZPos(Float value) {
+                this.zPos = value;
+            }
 
-    /**
-     * Gets the value of the height property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getHeight()
-    {
-      return height;
-    }
+        }
 
-    /**
-     * Sets the value of the height property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setHeight(Integer value)
-    {
-      this.height = value;
-    }
 
-    /**
-     * Gets the value of the xpos property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getXpos()
-    {
-      return xpos;
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class SeqPointMin {
+
+            @XmlAttribute(name = "xPos")
+            protected Float xPos;
+            @XmlAttribute(name = "yPos")
+            protected Float yPos;
+            @XmlAttribute(name = "zPos")
+            protected Float zPos;
+
+            /**
+             * Gets the value of the xPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getXPos() {
+                return xPos;
+            }
+
+            /**
+             * Sets the value of the xPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setXPos(Float value) {
+                this.xPos = value;
+            }
+
+            /**
+             * Gets the value of the yPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getYPos() {
+                return yPos;
+            }
+
+            /**
+             * Sets the value of the yPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setYPos(Float value) {
+                this.yPos = value;
+            }
+
+            /**
+             * Gets the value of the zPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getZPos() {
+                return zPos;
+            }
+
+            /**
+             * Sets the value of the zPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setZPos(Float value) {
+                this.zPos = value;
+            }
 
-    /**
-     * Sets the value of the xpos property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setXpos(Integer value)
-    {
-      this.xpos = value;
-    }
+        }
 
-    /**
-     * Gets the value of the ypos property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getYpos()
-    {
-      return ypos;
-    }
 
-    /**
-     * Sets the value of the ypos property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setYpos(Integer value)
-    {
-      this.ypos = value;
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attGroup ref="{www.jalview.org}position"/&amp;gt;
+         *       &amp;lt;attribute name="sequenceRef" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class SequencePoint {
+
+            @XmlAttribute(name = "sequenceRef")
+            protected String sequenceRef;
+            @XmlAttribute(name = "xPos")
+            protected Float xPos;
+            @XmlAttribute(name = "yPos")
+            protected Float yPos;
+            @XmlAttribute(name = "zPos")
+            protected Float zPos;
+
+            /**
+             * Gets the value of the sequenceRef property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getSequenceRef() {
+                return sequenceRef;
+            }
+
+            /**
+             * Sets the value of the sequenceRef property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setSequenceRef(String value) {
+                this.sequenceRef = value;
+            }
+
+            /**
+             * Gets the value of the xPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getXPos() {
+                return xPos;
+            }
+
+            /**
+             * Sets the value of the xPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setXPos(Float value) {
+                this.xPos = value;
+            }
+
+            /**
+             * Gets the value of the yPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getYPos() {
+                return yPos;
+            }
+
+            /**
+             * Sets the value of the yPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setYPos(Float value) {
+                this.yPos = value;
+            }
+
+            /**
+             * Gets the value of the zPos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Float }
+             *     
+             */
+            public Float getZPos() {
+                return zPos;
+            }
+
+            /**
+             * Sets the value of the zPos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Float }
+             *     
+             */
+            public void setZPos(Float value) {
+                this.zPos = value;
+            }
 
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="UserColourScheme" type="{www.jalview.org/colours}JalviewUserColours"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "userColourScheme" })
-  public static class UserColours
-  {
-
-    @XmlElement(
-      name = "UserColourScheme",
-      namespace = "www.jalview.org",
-      required = true)
-    protected JalviewUserColours userColourScheme;
-
-    @XmlAttribute(name = "id")
-    protected String id;
+        }
 
-    /**
-     * Gets the value of the userColourScheme property.
-     * 
-     * @return possible object is {@link JalviewUserColours }
-     * 
-     */
-    public JalviewUserColours getUserColourScheme()
-    {
-      return userColourScheme;
     }
 
-    /**
-     * Sets the value of the userColourScheme property.
-     * 
-     * @param value
-     *          allowed object is {@link JalviewUserColours }
-     * 
-     */
-    public void setUserColourScheme(JalviewUserColours value)
-    {
-      this.userColourScheme = value;
-    }
 
     /**
-     * Gets the value of the id property.
+     * &lt;p&gt;Java class for anonymous complex type.
      * 
-     * @return possible object is {@link String }
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
      * 
-     */
-    public String getId()
-    {
-      return id;
-    }
-
-    /**
-     * Sets the value of the id property.
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence minOccurs="0"&amp;gt;
+     *         &amp;lt;element name="title" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+     *         &amp;lt;element name="newick" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+     *       &amp;lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *       &amp;lt;attribute name="showBootstrap" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showDistances" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="markUnlinked" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="fitToWindow" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="currentTree" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="columnWise" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="columnReference" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" /&amp;gt;
+     *       &amp;lt;attribute name="linkToAllViews" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link String }
      * 
      */
-    public void setId(String value)
-    {
-      this.id = value;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "title",
+        "newick"
+    })
+    public static class Tree {
 
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="AnnotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/>
-   *         &lt;element name="hiddenColumns" maxOccurs="unbounded" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="calcIdParam" maxOccurs="unbounded" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;extension base="{www.jalview.org/xml/wsparamset}WebServiceParameterSet">
-   *                 &lt;attribute name="calcId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *                 &lt;attribute name="needsUpdate" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *                 &lt;attribute name="autoUpdate" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *               &lt;/extension>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *         &lt;element name="overview" minOccurs="0">
-   *           &lt;complexType>
-   *             &lt;complexContent>
-   *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *                 &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-   *                 &lt;attribute name="showHidden" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *                 &lt;attribute name="residueColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="gapColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="hiddenColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *                 &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *               &lt;/restriction>
-   *             &lt;/complexContent>
-   *           &lt;/complexType>
-   *         &lt;/element>
-   *       &lt;/sequence>
-   *       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-   *       &lt;attribute name="conservationSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="pidSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="showFullId" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="rightAlignIds" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showColourText" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="showBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="wrapAlignment" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="renderGaps" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showSequenceFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showNPfeatureTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="showDbRefTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="followHighlight" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="followSelection" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="showAnnotation" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="centreColumnLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="showGroupConservation" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="showGroupConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="startRes" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="startSeq" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="charWidth" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="charHeight" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="scaleProteinAsCdna" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
-   *       &lt;attribute name="viewName" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="sequenceSetId" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="gatheredViews" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
-   *       &lt;attribute name="complementId" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="showComplementFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="showComplementFeaturesOnTop" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(
-    name = "",
-    propOrder =
-    { "annotationColours", "hiddenColumns", "calcIdParam", "overview" })
-  public static class Viewport
-  {
-
-    @XmlElement(name = "AnnotationColours", namespace = "www.jalview.org")
-    protected AnnotationColourScheme annotationColours;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<JalviewModel.Viewport.HiddenColumns> hiddenColumns;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected List<JalviewModel.Viewport.CalcIdParam> calcIdParam;
-
-    @XmlElement(namespace = "www.jalview.org")
-    protected JalviewModel.Viewport.Overview overview;
-
-    @XmlAttribute(name = "conservationSelected")
-    protected Boolean conservationSelected;
-
-    @XmlAttribute(name = "pidSelected")
-    protected Boolean pidSelected;
-
-    @XmlAttribute(name = "bgColour")
-    protected String bgColour;
-
-    @XmlAttribute(name = "consThreshold")
-    protected Integer consThreshold;
-
-    @XmlAttribute(name = "pidThreshold")
-    protected Integer pidThreshold;
-
-    @XmlAttribute(name = "title")
-    protected String title;
-
-    @XmlAttribute(name = "showFullId")
-    protected Boolean showFullId;
-
-    @XmlAttribute(name = "rightAlignIds")
-    protected Boolean rightAlignIds;
-
-    @XmlAttribute(name = "showText")
-    protected Boolean showText;
-
-    @XmlAttribute(name = "showColourText")
-    protected Boolean showColourText;
-
-    @XmlAttribute(name = "showUnconserved")
-    protected Boolean showUnconserved;
-
-    @XmlAttribute(name = "showBoxes")
-    protected Boolean showBoxes;
-
-    @XmlAttribute(name = "wrapAlignment")
-    protected Boolean wrapAlignment;
+        @XmlElement(namespace = "www.jalview.org")
+        protected String title;
+        @XmlElement(namespace = "www.jalview.org")
+        protected String newick;
+        @XmlAttribute(name = "fontName")
+        protected String fontName;
+        @XmlAttribute(name = "fontSize")
+        protected Integer fontSize;
+        @XmlAttribute(name = "fontStyle")
+        protected Integer fontStyle;
+        @XmlAttribute(name = "threshold")
+        protected Float threshold;
+        @XmlAttribute(name = "showBootstrap")
+        protected Boolean showBootstrap;
+        @XmlAttribute(name = "showDistances")
+        protected Boolean showDistances;
+        @XmlAttribute(name = "markUnlinked")
+        protected Boolean markUnlinked;
+        @XmlAttribute(name = "fitToWindow")
+        protected Boolean fitToWindow;
+        @XmlAttribute(name = "currentTree")
+        protected Boolean currentTree;
+        @XmlAttribute(name = "columnWise")
+        protected Boolean columnWise;
+        @XmlAttribute(name = "columnReference")
+        protected String columnReference;
+        @XmlAttribute(name = "id")
+        @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+        @XmlID
+        @XmlSchemaType(name = "ID")
+        protected String id;
+        @XmlAttribute(name = "linkToAllViews")
+        protected Boolean linkToAllViews;
+        @XmlAttribute(name = "width")
+        protected Integer width;
+        @XmlAttribute(name = "height")
+        protected Integer height;
+        @XmlAttribute(name = "xpos")
+        protected Integer xpos;
+        @XmlAttribute(name = "ypos")
+        protected Integer ypos;
+
+        /**
+         * Gets the value of the title property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getTitle() {
+            return title;
+        }
+
+        /**
+         * Sets the value of the title property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setTitle(String value) {
+            this.title = value;
+        }
 
-    @XmlAttribute(name = "renderGaps")
-    protected Boolean renderGaps;
+        /**
+         * Gets the value of the newick property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getNewick() {
+            return newick;
+        }
 
-    @XmlAttribute(name = "showSequenceFeatures")
-    protected Boolean showSequenceFeatures;
+        /**
+         * Sets the value of the newick property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setNewick(String value) {
+            this.newick = value;
+        }
 
-    @XmlAttribute(name = "showNPfeatureTooltip")
-    protected Boolean showNPfeatureTooltip;
+        /**
+         * Gets the value of the fontName property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getFontName() {
+            return fontName;
+        }
 
-    @XmlAttribute(name = "showDbRefTooltip")
-    protected Boolean showDbRefTooltip;
+        /**
+         * Sets the value of the fontName property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setFontName(String value) {
+            this.fontName = value;
+        }
 
-    @XmlAttribute(name = "followHighlight")
-    protected Boolean followHighlight;
+        /**
+         * Gets the value of the fontSize property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getFontSize() {
+            return fontSize;
+        }
 
-    @XmlAttribute(name = "followSelection")
-    protected Boolean followSelection;
+        /**
+         * Sets the value of the fontSize property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setFontSize(Integer value) {
+            this.fontSize = value;
+        }
 
-    @XmlAttribute(name = "showAnnotation")
-    protected Boolean showAnnotation;
+        /**
+         * Gets the value of the fontStyle property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getFontStyle() {
+            return fontStyle;
+        }
 
-    @XmlAttribute(name = "centreColumnLabels")
-    protected Boolean centreColumnLabels;
+        /**
+         * Sets the value of the fontStyle property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setFontStyle(Integer value) {
+            this.fontStyle = value;
+        }
 
-    @XmlAttribute(name = "showGroupConservation")
-    protected Boolean showGroupConservation;
+        /**
+         * Gets the value of the threshold property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Float }
+         *     
+         */
+        public Float getThreshold() {
+            return threshold;
+        }
 
-    @XmlAttribute(name = "showGroupConsensus")
-    protected Boolean showGroupConsensus;
+        /**
+         * Sets the value of the threshold property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Float }
+         *     
+         */
+        public void setThreshold(Float value) {
+            this.threshold = value;
+        }
 
-    @XmlAttribute(name = "showConsensusHistogram")
-    protected Boolean showConsensusHistogram;
+        /**
+         * Gets the value of the showBootstrap property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowBootstrap() {
+            return showBootstrap;
+        }
 
-    @XmlAttribute(name = "showSequenceLogo")
-    protected Boolean showSequenceLogo;
+        /**
+         * Sets the value of the showBootstrap property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowBootstrap(Boolean value) {
+            this.showBootstrap = value;
+        }
 
-    @XmlAttribute(name = "normaliseSequenceLogo")
-    protected Boolean normaliseSequenceLogo;
+        /**
+         * Gets the value of the showDistances property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowDistances() {
+            return showDistances;
+        }
 
-    @XmlAttribute(name = "ignoreGapsinConsensus")
-    protected Boolean ignoreGapsinConsensus;
+        /**
+         * Sets the value of the showDistances property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowDistances(Boolean value) {
+            this.showDistances = value;
+        }
 
-    @XmlAttribute(name = "startRes")
-    protected Integer startRes;
+        /**
+         * Gets the value of the markUnlinked property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isMarkUnlinked() {
+            return markUnlinked;
+        }
 
-    @XmlAttribute(name = "startSeq")
-    protected Integer startSeq;
+        /**
+         * Sets the value of the markUnlinked property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setMarkUnlinked(Boolean value) {
+            this.markUnlinked = value;
+        }
 
-    @XmlAttribute(name = "charWidth")
-    protected Integer charWidth;
+        /**
+         * Gets the value of the fitToWindow property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isFitToWindow() {
+            return fitToWindow;
+        }
 
-    @XmlAttribute(name = "charHeight")
-    protected Integer charHeight;
+        /**
+         * Sets the value of the fitToWindow property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setFitToWindow(Boolean value) {
+            this.fitToWindow = value;
+        }
 
-    @XmlAttribute(name = "fontName")
-    protected String fontName;
+        /**
+         * Gets the value of the currentTree property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isCurrentTree() {
+            return currentTree;
+        }
 
-    @XmlAttribute(name = "fontSize")
-    protected Integer fontSize;
+        /**
+         * Sets the value of the currentTree property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setCurrentTree(Boolean value) {
+            this.currentTree = value;
+        }
 
-    @XmlAttribute(name = "fontStyle")
-    protected Integer fontStyle;
+        /**
+         * Gets the value of the columnWise property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isColumnWise() {
+            if (columnWise == null) {
+                return false;
+            } else {
+                return columnWise;
+            }
+        }
 
-    @XmlAttribute(name = "scaleProteinAsCdna")
-    protected Boolean scaleProteinAsCdna;
+        /**
+         * Sets the value of the columnWise property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setColumnWise(Boolean value) {
+            this.columnWise = value;
+        }
 
-    @XmlAttribute(name = "viewName")
-    protected String viewName;
+        /**
+         * Gets the value of the columnReference property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getColumnReference() {
+            return columnReference;
+        }
 
-    @XmlAttribute(name = "sequenceSetId")
-    protected String sequenceSetId;
+        /**
+         * Sets the value of the columnReference property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setColumnReference(String value) {
+            this.columnReference = value;
+        }
 
-    @XmlAttribute(name = "gatheredViews")
-    protected Boolean gatheredViews;
+        /**
+         * Gets the value of the id property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getId() {
+            return id;
+        }
 
-    @XmlAttribute(name = "textCol1")
-    protected Integer textCol1;
+        /**
+         * Sets the value of the id property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setId(String value) {
+            this.id = value;
+        }
 
-    @XmlAttribute(name = "textCol2")
-    protected Integer textCol2;
+        /**
+         * Gets the value of the linkToAllViews property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isLinkToAllViews() {
+            if (linkToAllViews == null) {
+                return false;
+            } else {
+                return linkToAllViews;
+            }
+        }
 
-    @XmlAttribute(name = "textColThreshold")
-    protected Integer textColThreshold;
+        /**
+         * Sets the value of the linkToAllViews property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setLinkToAllViews(Boolean value) {
+            this.linkToAllViews = value;
+        }
 
-    @XmlAttribute(name = "id")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    @XmlSchemaType(name = "ID")
-    protected String id;
+        /**
+         * Gets the value of the width property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getWidth() {
+            return width;
+        }
 
-    @XmlAttribute(name = "complementId")
-    protected String complementId;
+        /**
+         * Sets the value of the width property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setWidth(Integer value) {
+            this.width = value;
+        }
 
-    @XmlAttribute(name = "showComplementFeatures")
-    protected Boolean showComplementFeatures;
+        /**
+         * Gets the value of the height property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getHeight() {
+            return height;
+        }
 
-    @XmlAttribute(name = "showComplementFeaturesOnTop")
-    protected Boolean showComplementFeaturesOnTop;
+        /**
+         * Sets the value of the height property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setHeight(Integer value) {
+            this.height = value;
+        }
 
-    @XmlAttribute(name = "width")
-    protected Integer width;
+        /**
+         * Gets the value of the xpos property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getXpos() {
+            return xpos;
+        }
 
-    @XmlAttribute(name = "height")
-    protected Integer height;
+        /**
+         * Sets the value of the xpos property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setXpos(Integer value) {
+            this.xpos = value;
+        }
 
-    @XmlAttribute(name = "xpos")
-    protected Integer xpos;
+        /**
+         * Gets the value of the ypos property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getYpos() {
+            return ypos;
+        }
 
-    @XmlAttribute(name = "ypos")
-    protected Integer ypos;
+        /**
+         * Sets the value of the ypos property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setYpos(Integer value) {
+            this.ypos = value;
+        }
 
-    /**
-     * Gets the value of the annotationColours property.
-     * 
-     * @return possible object is {@link AnnotationColourScheme }
-     * 
-     */
-    public AnnotationColourScheme getAnnotationColours()
-    {
-      return annotationColours;
     }
 
-    /**
-     * Sets the value of the annotationColours property.
-     * 
-     * @param value
-     *          allowed object is {@link AnnotationColourScheme }
-     * 
-     */
-    public void setAnnotationColours(AnnotationColourScheme value)
-    {
-      this.annotationColours = value;
-    }
 
     /**
-     * Gets the value of the hiddenColumns property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the hiddenColumns property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
+     * &lt;p&gt;Java class for anonymous complex type.
      * 
-     * <pre>
-     * getHiddenColumns().add(newItem);
-     * </pre>
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
      * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.Viewport.HiddenColumns }
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="UserColourScheme" type="{www.jalview.org/colours}JalviewUserColours"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
      * 
      */
-    public List<JalviewModel.Viewport.HiddenColumns> getHiddenColumns()
-    {
-      if (hiddenColumns == null)
-      {
-        hiddenColumns = new ArrayList<JalviewModel.Viewport.HiddenColumns>();
-      }
-      return this.hiddenColumns;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "userColourScheme"
+    })
+    public static class UserColours {
 
-    /**
-     * Gets the value of the calcIdParam property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the calcIdParam property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getCalcIdParam().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JalviewModel.Viewport.CalcIdParam }
-     * 
-     * 
-     */
-    public List<JalviewModel.Viewport.CalcIdParam> getCalcIdParam()
-    {
-      if (calcIdParam == null)
-      {
-        calcIdParam = new ArrayList<JalviewModel.Viewport.CalcIdParam>();
-      }
-      return this.calcIdParam;
-    }
+        @XmlElement(name = "UserColourScheme", namespace = "www.jalview.org", required = true)
+        protected JalviewUserColours userColourScheme;
+        @XmlAttribute(name = "id")
+        protected String id;
 
-    /**
-     * Gets the value of the overview property.
-     * 
-     * @return possible object is {@link JalviewModel.Viewport.Overview }
-     * 
-     */
-    public JalviewModel.Viewport.Overview getOverview()
-    {
-      return overview;
-    }
+        /**
+         * Gets the value of the userColourScheme property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link JalviewUserColours }
+         *     
+         */
+        public JalviewUserColours getUserColourScheme() {
+            return userColourScheme;
+        }
 
-    /**
-     * Sets the value of the overview property.
-     * 
-     * @param value
-     *          allowed object is {@link JalviewModel.Viewport.Overview }
-     * 
-     */
-    public void setOverview(JalviewModel.Viewport.Overview value)
-    {
-      this.overview = value;
-    }
+        /**
+         * Sets the value of the userColourScheme property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link JalviewUserColours }
+         *     
+         */
+        public void setUserColourScheme(JalviewUserColours value) {
+            this.userColourScheme = value;
+        }
 
-    /**
-     * Gets the value of the conservationSelected property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isConservationSelected()
-    {
-      return conservationSelected;
-    }
+        /**
+         * Gets the value of the id property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getId() {
+            return id;
+        }
+
+        /**
+         * Sets the value of the id property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setId(String value) {
+            this.id = value;
+        }
 
-    /**
-     * Sets the value of the conservationSelected property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setConservationSelected(Boolean value)
-    {
-      this.conservationSelected = value;
     }
 
+
     /**
-     * Gets the value of the pidSelected property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="AnnotationColours" type="{www.jalview.org}AnnotationColourScheme" minOccurs="0"/&amp;gt;
+     *         &amp;lt;element name="hiddenColumns" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="calcIdParam" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;extension base="{www.jalview.org/xml/wsparamset}WebServiceParameterSet"&amp;gt;
+     *                 &amp;lt;attribute name="calcId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *                 &amp;lt;attribute name="needsUpdate" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *                 &amp;lt;attribute name="autoUpdate" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *               &amp;lt;/extension&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *         &amp;lt;element name="overview" minOccurs="0"&amp;gt;
+     *           &amp;lt;complexType&amp;gt;
+     *             &amp;lt;complexContent&amp;gt;
+     *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *                 &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+     *                 &amp;lt;attribute name="showHidden" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *                 &amp;lt;attribute name="residueColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="gapColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="hiddenColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *                 &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *               &amp;lt;/restriction&amp;gt;
+     *             &amp;lt;/complexContent&amp;gt;
+     *           &amp;lt;/complexType&amp;gt;
+     *         &amp;lt;/element&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+     *       &amp;lt;attribute name="conservationSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="pidSelected" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="bgColour" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="consThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="pidThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="showFullId" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="rightAlignIds" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showColourText" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showUnconserved" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="showBoxes" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="wrapAlignment" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="renderGaps" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showSequenceFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showNPfeatureTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="showDbRefTooltip" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="followHighlight" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="followSelection" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="showAnnotation" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="centreColumnLabels" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="showGroupConservation" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="showGroupConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="showConsensusHistogram" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="showSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="normaliseSequenceLogo" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="ignoreGapsinConsensus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="startRes" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="startSeq" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="charWidth" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="charHeight" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="fontName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="fontSize" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="fontStyle" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="idWidth" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="idWidthManuallyAdjusted" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="scaleProteinAsCdna" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" /&amp;gt;
+     *       &amp;lt;attribute name="viewName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="sequenceSetId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="gatheredViews" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="textCol1" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="textCol2" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="textColThreshold" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" /&amp;gt;
+     *       &amp;lt;attribute name="complementId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="showComplementFeatures" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="showComplementFeaturesOnTop" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Boolean }
      * 
      */
-    public Boolean isPidSelected()
-    {
-      return pidSelected;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "annotationColours",
+        "hiddenColumns",
+        "calcIdParam",
+        "overview"
+    })
+    public static class Viewport {
+
+        @XmlElement(name = "AnnotationColours", namespace = "www.jalview.org")
+        protected AnnotationColourScheme annotationColours;
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<JalviewModel.Viewport.HiddenColumns> hiddenColumns;
+        @XmlElement(namespace = "www.jalview.org")
+        protected List<JalviewModel.Viewport.CalcIdParam> calcIdParam;
+        @XmlElement(namespace = "www.jalview.org")
+        protected JalviewModel.Viewport.Overview overview;
+        @XmlAttribute(name = "conservationSelected")
+        protected Boolean conservationSelected;
+        @XmlAttribute(name = "pidSelected")
+        protected Boolean pidSelected;
+        @XmlAttribute(name = "bgColour")
+        protected String bgColour;
+        @XmlAttribute(name = "consThreshold")
+        protected Integer consThreshold;
+        @XmlAttribute(name = "pidThreshold")
+        protected Integer pidThreshold;
+        @XmlAttribute(name = "title")
+        protected String title;
+        @XmlAttribute(name = "showFullId")
+        protected Boolean showFullId;
+        @XmlAttribute(name = "rightAlignIds")
+        protected Boolean rightAlignIds;
+        @XmlAttribute(name = "showText")
+        protected Boolean showText;
+        @XmlAttribute(name = "showColourText")
+        protected Boolean showColourText;
+        @XmlAttribute(name = "showUnconserved")
+        protected Boolean showUnconserved;
+        @XmlAttribute(name = "showBoxes")
+        protected Boolean showBoxes;
+        @XmlAttribute(name = "wrapAlignment")
+        protected Boolean wrapAlignment;
+        @XmlAttribute(name = "renderGaps")
+        protected Boolean renderGaps;
+        @XmlAttribute(name = "showSequenceFeatures")
+        protected Boolean showSequenceFeatures;
+        @XmlAttribute(name = "showNPfeatureTooltip")
+        protected Boolean showNPfeatureTooltip;
+        @XmlAttribute(name = "showDbRefTooltip")
+        protected Boolean showDbRefTooltip;
+        @XmlAttribute(name = "followHighlight")
+        protected Boolean followHighlight;
+        @XmlAttribute(name = "followSelection")
+        protected Boolean followSelection;
+        @XmlAttribute(name = "showAnnotation")
+        protected Boolean showAnnotation;
+        @XmlAttribute(name = "centreColumnLabels")
+        protected Boolean centreColumnLabels;
+        @XmlAttribute(name = "showGroupConservation")
+        protected Boolean showGroupConservation;
+        @XmlAttribute(name = "showGroupConsensus")
+        protected Boolean showGroupConsensus;
+        @XmlAttribute(name = "showConsensusHistogram")
+        protected Boolean showConsensusHistogram;
+        @XmlAttribute(name = "showSequenceLogo")
+        protected Boolean showSequenceLogo;
+        @XmlAttribute(name = "normaliseSequenceLogo")
+        protected Boolean normaliseSequenceLogo;
+        @XmlAttribute(name = "ignoreGapsinConsensus")
+        protected Boolean ignoreGapsinConsensus;
+        @XmlAttribute(name = "startRes")
+        protected Integer startRes;
+        @XmlAttribute(name = "startSeq")
+        protected Integer startSeq;
+        @XmlAttribute(name = "charWidth")
+        protected Integer charWidth;
+        @XmlAttribute(name = "charHeight")
+        protected Integer charHeight;
+        @XmlAttribute(name = "fontName")
+        protected String fontName;
+        @XmlAttribute(name = "fontSize")
+        protected Integer fontSize;
+        @XmlAttribute(name = "fontStyle")
+        protected Integer fontStyle;
+        @XmlAttribute(name = "idWidth")
+        protected Integer idWidth;
+        @XmlAttribute(name = "idWidthManuallyAdjusted")
+        protected Boolean idWidthManuallyAdjusted;
+        @XmlAttribute(name = "scaleProteinAsCdna")
+        protected Boolean scaleProteinAsCdna;
+        @XmlAttribute(name = "viewName")
+        protected String viewName;
+        @XmlAttribute(name = "sequenceSetId")
+        protected String sequenceSetId;
+        @XmlAttribute(name = "gatheredViews")
+        protected Boolean gatheredViews;
+        @XmlAttribute(name = "textCol1")
+        protected Integer textCol1;
+        @XmlAttribute(name = "textCol2")
+        protected Integer textCol2;
+        @XmlAttribute(name = "textColThreshold")
+        protected Integer textColThreshold;
+        @XmlAttribute(name = "id")
+        @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+        @XmlID
+        @XmlSchemaType(name = "ID")
+        protected String id;
+        @XmlAttribute(name = "complementId")
+        protected String complementId;
+        @XmlAttribute(name = "showComplementFeatures")
+        protected Boolean showComplementFeatures;
+        @XmlAttribute(name = "showComplementFeaturesOnTop")
+        protected Boolean showComplementFeaturesOnTop;
+        @XmlAttribute(name = "width")
+        protected Integer width;
+        @XmlAttribute(name = "height")
+        protected Integer height;
+        @XmlAttribute(name = "xpos")
+        protected Integer xpos;
+        @XmlAttribute(name = "ypos")
+        protected Integer ypos;
+
+        /**
+         * Gets the value of the annotationColours property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link AnnotationColourScheme }
+         *     
+         */
+        public AnnotationColourScheme getAnnotationColours() {
+            return annotationColours;
+        }
+
+        /**
+         * Sets the value of the annotationColours property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link AnnotationColourScheme }
+         *     
+         */
+        public void setAnnotationColours(AnnotationColourScheme value) {
+            this.annotationColours = value;
+        }
+
+        /**
+         * Gets the value of the hiddenColumns property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the hiddenColumns property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getHiddenColumns().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.Viewport.HiddenColumns }
+         * 
+         * 
+         */
+        public List<JalviewModel.Viewport.HiddenColumns> getHiddenColumns() {
+            if (hiddenColumns == null) {
+                hiddenColumns = new ArrayList<JalviewModel.Viewport.HiddenColumns>();
+            }
+            return this.hiddenColumns;
+        }
+
+        /**
+         * Gets the value of the calcIdParam property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the calcIdParam property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getCalcIdParam().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link JalviewModel.Viewport.CalcIdParam }
+         * 
+         * 
+         */
+        public List<JalviewModel.Viewport.CalcIdParam> getCalcIdParam() {
+            if (calcIdParam == null) {
+                calcIdParam = new ArrayList<JalviewModel.Viewport.CalcIdParam>();
+            }
+            return this.calcIdParam;
+        }
+
+        /**
+         * Gets the value of the overview property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link JalviewModel.Viewport.Overview }
+         *     
+         */
+        public JalviewModel.Viewport.Overview getOverview() {
+            return overview;
+        }
+
+        /**
+         * Sets the value of the overview property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link JalviewModel.Viewport.Overview }
+         *     
+         */
+        public void setOverview(JalviewModel.Viewport.Overview value) {
+            this.overview = value;
+        }
+
+        /**
+         * Gets the value of the conservationSelected property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isConservationSelected() {
+            return conservationSelected;
+        }
+
+        /**
+         * Sets the value of the conservationSelected property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setConservationSelected(Boolean value) {
+            this.conservationSelected = value;
+        }
+
+        /**
+         * Gets the value of the pidSelected property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isPidSelected() {
+            return pidSelected;
+        }
+
+        /**
+         * Sets the value of the pidSelected property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setPidSelected(Boolean value) {
+            this.pidSelected = value;
+        }
+
+        /**
+         * Gets the value of the bgColour property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getBgColour() {
+            return bgColour;
+        }
 
-    /**
-     * Sets the value of the pidSelected property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setPidSelected(Boolean value)
-    {
-      this.pidSelected = value;
-    }
+        /**
+         * Sets the value of the bgColour property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setBgColour(String value) {
+            this.bgColour = value;
+        }
 
-    /**
-     * Gets the value of the bgColour property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getBgColour()
-    {
-      return bgColour;
-    }
+        /**
+         * Gets the value of the consThreshold property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getConsThreshold() {
+            return consThreshold;
+        }
 
-    /**
-     * Sets the value of the bgColour property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setBgColour(String value)
-    {
-      this.bgColour = value;
-    }
+        /**
+         * Sets the value of the consThreshold property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setConsThreshold(Integer value) {
+            this.consThreshold = value;
+        }
 
-    /**
-     * Gets the value of the consThreshold property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getConsThreshold()
-    {
-      return consThreshold;
-    }
+        /**
+         * Gets the value of the pidThreshold property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getPidThreshold() {
+            return pidThreshold;
+        }
 
-    /**
-     * Sets the value of the consThreshold property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setConsThreshold(Integer value)
-    {
-      this.consThreshold = value;
-    }
+        /**
+         * Sets the value of the pidThreshold property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setPidThreshold(Integer value) {
+            this.pidThreshold = value;
+        }
 
-    /**
-     * Gets the value of the pidThreshold property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getPidThreshold()
-    {
-      return pidThreshold;
-    }
+        /**
+         * Gets the value of the title property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getTitle() {
+            return title;
+        }
 
-    /**
-     * Sets the value of the pidThreshold property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setPidThreshold(Integer value)
-    {
-      this.pidThreshold = value;
-    }
+        /**
+         * Sets the value of the title property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setTitle(String value) {
+            this.title = value;
+        }
 
-    /**
-     * Gets the value of the title property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getTitle()
-    {
-      return title;
-    }
+        /**
+         * Gets the value of the showFullId property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowFullId() {
+            return showFullId;
+        }
 
-    /**
-     * Sets the value of the title property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setTitle(String value)
-    {
-      this.title = value;
-    }
+        /**
+         * Sets the value of the showFullId property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowFullId(Boolean value) {
+            this.showFullId = value;
+        }
 
-    /**
-     * Gets the value of the showFullId property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowFullId()
-    {
-      return showFullId;
-    }
+        /**
+         * Gets the value of the rightAlignIds property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isRightAlignIds() {
+            return rightAlignIds;
+        }
 
-    /**
-     * Sets the value of the showFullId property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowFullId(Boolean value)
-    {
-      this.showFullId = value;
-    }
+        /**
+         * Sets the value of the rightAlignIds property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setRightAlignIds(Boolean value) {
+            this.rightAlignIds = value;
+        }
 
-    /**
-     * Gets the value of the rightAlignIds property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isRightAlignIds()
-    {
-      return rightAlignIds;
-    }
+        /**
+         * Gets the value of the showText property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowText() {
+            return showText;
+        }
 
-    /**
-     * Sets the value of the rightAlignIds property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setRightAlignIds(Boolean value)
-    {
-      this.rightAlignIds = value;
-    }
+        /**
+         * Sets the value of the showText property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowText(Boolean value) {
+            this.showText = value;
+        }
 
-    /**
-     * Gets the value of the showText property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowText()
-    {
-      return showText;
-    }
+        /**
+         * Gets the value of the showColourText property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowColourText() {
+            return showColourText;
+        }
 
-    /**
-     * Sets the value of the showText property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowText(Boolean value)
-    {
-      this.showText = value;
-    }
+        /**
+         * Sets the value of the showColourText property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowColourText(Boolean value) {
+            this.showColourText = value;
+        }
 
-    /**
-     * Gets the value of the showColourText property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowColourText()
-    {
-      return showColourText;
-    }
+        /**
+         * Gets the value of the showUnconserved property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowUnconserved() {
+            if (showUnconserved == null) {
+                return false;
+            } else {
+                return showUnconserved;
+            }
+        }
 
-    /**
-     * Sets the value of the showColourText property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowColourText(Boolean value)
-    {
-      this.showColourText = value;
-    }
+        /**
+         * Sets the value of the showUnconserved property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowUnconserved(Boolean value) {
+            this.showUnconserved = value;
+        }
 
-    /**
-     * Gets the value of the showUnconserved property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowUnconserved()
-    {
-      if (showUnconserved == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showUnconserved;
-      }
-    }
+        /**
+         * Gets the value of the showBoxes property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowBoxes() {
+            return showBoxes;
+        }
 
-    /**
-     * Sets the value of the showUnconserved property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowUnconserved(Boolean value)
-    {
-      this.showUnconserved = value;
-    }
+        /**
+         * Sets the value of the showBoxes property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowBoxes(Boolean value) {
+            this.showBoxes = value;
+        }
 
-    /**
-     * Gets the value of the showBoxes property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowBoxes()
-    {
-      return showBoxes;
-    }
+        /**
+         * Gets the value of the wrapAlignment property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isWrapAlignment() {
+            return wrapAlignment;
+        }
 
-    /**
-     * Sets the value of the showBoxes property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowBoxes(Boolean value)
-    {
-      this.showBoxes = value;
-    }
+        /**
+         * Sets the value of the wrapAlignment property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setWrapAlignment(Boolean value) {
+            this.wrapAlignment = value;
+        }
 
-    /**
-     * Gets the value of the wrapAlignment property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isWrapAlignment()
-    {
-      return wrapAlignment;
-    }
+        /**
+         * Gets the value of the renderGaps property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isRenderGaps() {
+            return renderGaps;
+        }
 
-    /**
-     * Sets the value of the wrapAlignment property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setWrapAlignment(Boolean value)
-    {
-      this.wrapAlignment = value;
-    }
+        /**
+         * Sets the value of the renderGaps property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setRenderGaps(Boolean value) {
+            this.renderGaps = value;
+        }
 
-    /**
-     * Gets the value of the renderGaps property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isRenderGaps()
-    {
-      return renderGaps;
-    }
+        /**
+         * Gets the value of the showSequenceFeatures property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowSequenceFeatures() {
+            return showSequenceFeatures;
+        }
 
-    /**
-     * Sets the value of the renderGaps property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setRenderGaps(Boolean value)
-    {
-      this.renderGaps = value;
-    }
+        /**
+         * Sets the value of the showSequenceFeatures property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowSequenceFeatures(Boolean value) {
+            this.showSequenceFeatures = value;
+        }
+
+        /**
+         * Gets the value of the showNPfeatureTooltip property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowNPfeatureTooltip() {
+            return showNPfeatureTooltip;
+        }
 
-    /**
-     * Gets the value of the showSequenceFeatures property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowSequenceFeatures()
-    {
-      return showSequenceFeatures;
-    }
+        /**
+         * Sets the value of the showNPfeatureTooltip property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowNPfeatureTooltip(Boolean value) {
+            this.showNPfeatureTooltip = value;
+        }
 
-    /**
-     * Sets the value of the showSequenceFeatures property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowSequenceFeatures(Boolean value)
-    {
-      this.showSequenceFeatures = value;
-    }
+        /**
+         * Gets the value of the showDbRefTooltip property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowDbRefTooltip() {
+            return showDbRefTooltip;
+        }
 
-    /**
-     * Gets the value of the showNPfeatureTooltip property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowNPfeatureTooltip()
-    {
-      return showNPfeatureTooltip;
-    }
+        /**
+         * Sets the value of the showDbRefTooltip property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowDbRefTooltip(Boolean value) {
+            this.showDbRefTooltip = value;
+        }
 
-    /**
-     * Sets the value of the showNPfeatureTooltip property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowNPfeatureTooltip(Boolean value)
-    {
-      this.showNPfeatureTooltip = value;
-    }
+        /**
+         * Gets the value of the followHighlight property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isFollowHighlight() {
+            if (followHighlight == null) {
+                return true;
+            } else {
+                return followHighlight;
+            }
+        }
 
-    /**
-     * Gets the value of the showDbRefTooltip property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowDbRefTooltip()
-    {
-      return showDbRefTooltip;
-    }
+        /**
+         * Sets the value of the followHighlight property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setFollowHighlight(Boolean value) {
+            this.followHighlight = value;
+        }
 
-    /**
-     * Sets the value of the showDbRefTooltip property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowDbRefTooltip(Boolean value)
-    {
-      this.showDbRefTooltip = value;
-    }
+        /**
+         * Gets the value of the followSelection property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isFollowSelection() {
+            if (followSelection == null) {
+                return true;
+            } else {
+                return followSelection;
+            }
+        }
 
-    /**
-     * Gets the value of the followHighlight property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isFollowHighlight()
-    {
-      if (followHighlight == null)
-      {
-        return true;
-      }
-      else
-      {
-        return followHighlight;
-      }
-    }
+        /**
+         * Sets the value of the followSelection property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setFollowSelection(Boolean value) {
+            this.followSelection = value;
+        }
 
-    /**
-     * Sets the value of the followHighlight property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setFollowHighlight(Boolean value)
-    {
-      this.followHighlight = value;
-    }
+        /**
+         * Gets the value of the showAnnotation property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isShowAnnotation() {
+            return showAnnotation;
+        }
 
-    /**
-     * Gets the value of the followSelection property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isFollowSelection()
-    {
-      if (followSelection == null)
-      {
-        return true;
-      }
-      else
-      {
-        return followSelection;
-      }
-    }
+        /**
+         * Sets the value of the showAnnotation property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowAnnotation(Boolean value) {
+            this.showAnnotation = value;
+        }
 
-    /**
-     * Sets the value of the followSelection property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setFollowSelection(Boolean value)
-    {
-      this.followSelection = value;
-    }
+        /**
+         * Gets the value of the centreColumnLabels property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isCentreColumnLabels() {
+            if (centreColumnLabels == null) {
+                return false;
+            } else {
+                return centreColumnLabels;
+            }
+        }
 
-    /**
-     * Gets the value of the showAnnotation property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isShowAnnotation()
-    {
-      return showAnnotation;
-    }
+        /**
+         * Sets the value of the centreColumnLabels property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setCentreColumnLabels(Boolean value) {
+            this.centreColumnLabels = value;
+        }
 
-    /**
-     * Sets the value of the showAnnotation property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowAnnotation(Boolean value)
-    {
-      this.showAnnotation = value;
-    }
+        /**
+         * Gets the value of the showGroupConservation property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowGroupConservation() {
+            if (showGroupConservation == null) {
+                return false;
+            } else {
+                return showGroupConservation;
+            }
+        }
 
-    /**
-     * Gets the value of the centreColumnLabels property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isCentreColumnLabels()
-    {
-      if (centreColumnLabels == null)
-      {
-        return false;
-      }
-      else
-      {
-        return centreColumnLabels;
-      }
-    }
+        /**
+         * Sets the value of the showGroupConservation property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowGroupConservation(Boolean value) {
+            this.showGroupConservation = value;
+        }
 
-    /**
-     * Sets the value of the centreColumnLabels property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setCentreColumnLabels(Boolean value)
-    {
-      this.centreColumnLabels = value;
-    }
+        /**
+         * Gets the value of the showGroupConsensus property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowGroupConsensus() {
+            if (showGroupConsensus == null) {
+                return false;
+            } else {
+                return showGroupConsensus;
+            }
+        }
 
-    /**
-     * Gets the value of the showGroupConservation property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowGroupConservation()
-    {
-      if (showGroupConservation == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showGroupConservation;
-      }
-    }
+        /**
+         * Sets the value of the showGroupConsensus property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowGroupConsensus(Boolean value) {
+            this.showGroupConsensus = value;
+        }
 
-    /**
-     * Sets the value of the showGroupConservation property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowGroupConservation(Boolean value)
-    {
-      this.showGroupConservation = value;
-    }
+        /**
+         * Gets the value of the showConsensusHistogram property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowConsensusHistogram() {
+            if (showConsensusHistogram == null) {
+                return true;
+            } else {
+                return showConsensusHistogram;
+            }
+        }
 
-    /**
-     * Gets the value of the showGroupConsensus property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowGroupConsensus()
-    {
-      if (showGroupConsensus == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showGroupConsensus;
-      }
-    }
+        /**
+         * Sets the value of the showConsensusHistogram property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowConsensusHistogram(Boolean value) {
+            this.showConsensusHistogram = value;
+        }
 
-    /**
-     * Sets the value of the showGroupConsensus property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowGroupConsensus(Boolean value)
-    {
-      this.showGroupConsensus = value;
-    }
+        /**
+         * Gets the value of the showSequenceLogo property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowSequenceLogo() {
+            if (showSequenceLogo == null) {
+                return false;
+            } else {
+                return showSequenceLogo;
+            }
+        }
 
-    /**
-     * Gets the value of the showConsensusHistogram property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowConsensusHistogram()
-    {
-      if (showConsensusHistogram == null)
-      {
-        return true;
-      }
-      else
-      {
-        return showConsensusHistogram;
-      }
-    }
+        /**
+         * Sets the value of the showSequenceLogo property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowSequenceLogo(Boolean value) {
+            this.showSequenceLogo = value;
+        }
 
-    /**
-     * Sets the value of the showConsensusHistogram property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowConsensusHistogram(Boolean value)
-    {
-      this.showConsensusHistogram = value;
-    }
+        /**
+         * Gets the value of the normaliseSequenceLogo property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isNormaliseSequenceLogo() {
+            if (normaliseSequenceLogo == null) {
+                return false;
+            } else {
+                return normaliseSequenceLogo;
+            }
+        }
 
-    /**
-     * Gets the value of the showSequenceLogo property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowSequenceLogo()
-    {
-      if (showSequenceLogo == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showSequenceLogo;
-      }
-    }
+        /**
+         * Sets the value of the normaliseSequenceLogo property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setNormaliseSequenceLogo(Boolean value) {
+            this.normaliseSequenceLogo = value;
+        }
 
-    /**
-     * Sets the value of the showSequenceLogo property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowSequenceLogo(Boolean value)
-    {
-      this.showSequenceLogo = value;
-    }
+        /**
+         * Gets the value of the ignoreGapsinConsensus property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isIgnoreGapsinConsensus() {
+            if (ignoreGapsinConsensus == null) {
+                return true;
+            } else {
+                return ignoreGapsinConsensus;
+            }
+        }
 
-    /**
-     * Gets the value of the normaliseSequenceLogo property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isNormaliseSequenceLogo()
-    {
-      if (normaliseSequenceLogo == null)
-      {
-        return false;
-      }
-      else
-      {
-        return normaliseSequenceLogo;
-      }
-    }
+        /**
+         * Sets the value of the ignoreGapsinConsensus property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setIgnoreGapsinConsensus(Boolean value) {
+            this.ignoreGapsinConsensus = value;
+        }
 
-    /**
-     * Sets the value of the normaliseSequenceLogo property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setNormaliseSequenceLogo(Boolean value)
-    {
-      this.normaliseSequenceLogo = value;
-    }
+        /**
+         * Gets the value of the startRes property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getStartRes() {
+            return startRes;
+        }
 
-    /**
-     * Gets the value of the ignoreGapsinConsensus property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isIgnoreGapsinConsensus()
-    {
-      if (ignoreGapsinConsensus == null)
-      {
-        return true;
-      }
-      else
-      {
-        return ignoreGapsinConsensus;
-      }
-    }
+        /**
+         * Sets the value of the startRes property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setStartRes(Integer value) {
+            this.startRes = value;
+        }
+
+        /**
+         * Gets the value of the startSeq property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getStartSeq() {
+            return startSeq;
+        }
 
-    /**
-     * Sets the value of the ignoreGapsinConsensus property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setIgnoreGapsinConsensus(Boolean value)
-    {
-      this.ignoreGapsinConsensus = value;
-    }
+        /**
+         * Sets the value of the startSeq property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setStartSeq(Integer value) {
+            this.startSeq = value;
+        }
 
-    /**
-     * Gets the value of the startRes property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getStartRes()
-    {
-      return startRes;
-    }
+        /**
+         * Gets the value of the charWidth property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getCharWidth() {
+            return charWidth;
+        }
 
-    /**
-     * Sets the value of the startRes property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setStartRes(Integer value)
-    {
-      this.startRes = value;
-    }
+        /**
+         * Sets the value of the charWidth property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setCharWidth(Integer value) {
+            this.charWidth = value;
+        }
 
-    /**
-     * Gets the value of the startSeq property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getStartSeq()
-    {
-      return startSeq;
-    }
+        /**
+         * Gets the value of the charHeight property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getCharHeight() {
+            return charHeight;
+        }
 
-    /**
-     * Sets the value of the startSeq property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setStartSeq(Integer value)
-    {
-      this.startSeq = value;
-    }
+        /**
+         * Sets the value of the charHeight property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setCharHeight(Integer value) {
+            this.charHeight = value;
+        }
 
-    /**
-     * Gets the value of the charWidth property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getCharWidth()
-    {
-      return charWidth;
-    }
+        /**
+         * Gets the value of the fontName property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getFontName() {
+            return fontName;
+        }
 
-    /**
-     * Sets the value of the charWidth property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setCharWidth(Integer value)
-    {
-      this.charWidth = value;
-    }
+        /**
+         * Sets the value of the fontName property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setFontName(String value) {
+            this.fontName = value;
+        }
 
-    /**
-     * Gets the value of the charHeight property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getCharHeight()
-    {
-      return charHeight;
-    }
+        /**
+         * Gets the value of the fontSize property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getFontSize() {
+            return fontSize;
+        }
 
-    /**
-     * Sets the value of the charHeight property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setCharHeight(Integer value)
-    {
-      this.charHeight = value;
-    }
+        /**
+         * Sets the value of the fontSize property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setFontSize(Integer value) {
+            this.fontSize = value;
+        }
 
-    /**
-     * Gets the value of the fontName property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getFontName()
-    {
-      return fontName;
-    }
+        /**
+         * Gets the value of the fontStyle property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getFontStyle() {
+            return fontStyle;
+        }
 
-    /**
-     * Sets the value of the fontName property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setFontName(String value)
-    {
-      this.fontName = value;
-    }
+        /**
+         * Sets the value of the fontStyle property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setFontStyle(Integer value) {
+            this.fontStyle = value;
+        }
 
-    /**
-     * Gets the value of the fontSize property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getFontSize()
-    {
-      return fontSize;
-    }
+        /**
+         * Gets the value of the idWidth property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getIdWidth() {
+            return idWidth;
+        }
 
-    /**
-     * Sets the value of the fontSize property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setFontSize(Integer value)
-    {
-      this.fontSize = value;
-    }
+        /**
+         * Sets the value of the idWidth property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setIdWidth(Integer value) {
+            this.idWidth = value;
+        }
 
-    /**
-     * Gets the value of the fontStyle property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getFontStyle()
-    {
-      return fontStyle;
-    }
+        /**
+         * Gets the value of the idWidthManuallyAdjusted property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isIdWidthManuallyAdjusted() {
+            return idWidthManuallyAdjusted;
+        }
 
-    /**
-     * Sets the value of the fontStyle property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setFontStyle(Integer value)
-    {
-      this.fontStyle = value;
-    }
+        /**
+         * Sets the value of the idWidthManuallyAdjusted property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setIdWidthManuallyAdjusted(Boolean value) {
+            this.idWidthManuallyAdjusted = value;
+        }
 
-    /**
-     * Gets the value of the scaleProteinAsCdna property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isScaleProteinAsCdna()
-    {
-      if (scaleProteinAsCdna == null)
-      {
-        return true;
-      }
-      else
-      {
-        return scaleProteinAsCdna;
-      }
-    }
+        /**
+         * Gets the value of the scaleProteinAsCdna property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isScaleProteinAsCdna() {
+            if (scaleProteinAsCdna == null) {
+                return true;
+            } else {
+                return scaleProteinAsCdna;
+            }
+        }
 
-    /**
-     * Sets the value of the scaleProteinAsCdna property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setScaleProteinAsCdna(Boolean value)
-    {
-      this.scaleProteinAsCdna = value;
-    }
+        /**
+         * Sets the value of the scaleProteinAsCdna property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setScaleProteinAsCdna(Boolean value) {
+            this.scaleProteinAsCdna = value;
+        }
 
-    /**
-     * Gets the value of the viewName property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getViewName()
-    {
-      return viewName;
-    }
+        /**
+         * Gets the value of the viewName property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getViewName() {
+            return viewName;
+        }
 
-    /**
-     * Sets the value of the viewName property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setViewName(String value)
-    {
-      this.viewName = value;
-    }
+        /**
+         * Sets the value of the viewName property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setViewName(String value) {
+            this.viewName = value;
+        }
 
-    /**
-     * Gets the value of the sequenceSetId property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getSequenceSetId()
-    {
-      return sequenceSetId;
-    }
+        /**
+         * Gets the value of the sequenceSetId property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getSequenceSetId() {
+            return sequenceSetId;
+        }
 
-    /**
-     * Sets the value of the sequenceSetId property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setSequenceSetId(String value)
-    {
-      this.sequenceSetId = value;
-    }
+        /**
+         * Sets the value of the sequenceSetId property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setSequenceSetId(String value) {
+            this.sequenceSetId = value;
+        }
 
-    /**
-     * Gets the value of the gatheredViews property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public Boolean isGatheredViews()
-    {
-      return gatheredViews;
-    }
+        /**
+         * Gets the value of the gatheredViews property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isGatheredViews() {
+            return gatheredViews;
+        }
 
-    /**
-     * Sets the value of the gatheredViews property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setGatheredViews(Boolean value)
-    {
-      this.gatheredViews = value;
-    }
+        /**
+         * Sets the value of the gatheredViews property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setGatheredViews(Boolean value) {
+            this.gatheredViews = value;
+        }
 
-    /**
-     * Gets the value of the textCol1 property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getTextCol1()
-    {
-      return textCol1;
-    }
+        /**
+         * Gets the value of the textCol1 property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getTextCol1() {
+            return textCol1;
+        }
 
-    /**
-     * Sets the value of the textCol1 property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setTextCol1(Integer value)
-    {
-      this.textCol1 = value;
-    }
+        /**
+         * Sets the value of the textCol1 property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setTextCol1(Integer value) {
+            this.textCol1 = value;
+        }
+
+        /**
+         * Gets the value of the textCol2 property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getTextCol2() {
+            return textCol2;
+        }
 
-    /**
-     * Gets the value of the textCol2 property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getTextCol2()
-    {
-      return textCol2;
-    }
+        /**
+         * Sets the value of the textCol2 property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setTextCol2(Integer value) {
+            this.textCol2 = value;
+        }
 
-    /**
-     * Sets the value of the textCol2 property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setTextCol2(Integer value)
-    {
-      this.textCol2 = value;
-    }
+        /**
+         * Gets the value of the textColThreshold property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getTextColThreshold() {
+            return textColThreshold;
+        }
 
-    /**
-     * Gets the value of the textColThreshold property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getTextColThreshold()
-    {
-      return textColThreshold;
-    }
+        /**
+         * Sets the value of the textColThreshold property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setTextColThreshold(Integer value) {
+            this.textColThreshold = value;
+        }
 
-    /**
-     * Sets the value of the textColThreshold property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setTextColThreshold(Integer value)
-    {
-      this.textColThreshold = value;
-    }
+        /**
+         * Gets the value of the id property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getId() {
+            return id;
+        }
 
-    /**
-     * Gets the value of the id property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getId()
-    {
-      return id;
-    }
+        /**
+         * Sets the value of the id property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setId(String value) {
+            this.id = value;
+        }
 
-    /**
-     * Sets the value of the id property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setId(String value)
-    {
-      this.id = value;
-    }
+        /**
+         * Gets the value of the complementId property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getComplementId() {
+            return complementId;
+        }
 
-    /**
-     * Gets the value of the complementId property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getComplementId()
-    {
-      return complementId;
-    }
+        /**
+         * Sets the value of the complementId property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setComplementId(String value) {
+            this.complementId = value;
+        }
 
-    /**
-     * Sets the value of the complementId property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setComplementId(String value)
-    {
-      this.complementId = value;
-    }
+        /**
+         * Gets the value of the showComplementFeatures property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowComplementFeatures() {
+            if (showComplementFeatures == null) {
+                return false;
+            } else {
+                return showComplementFeatures;
+            }
+        }
 
-    /**
-     * Gets the value of the showComplementFeatures property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowComplementFeatures()
-    {
-      if (showComplementFeatures == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showComplementFeatures;
-      }
-    }
+        /**
+         * Sets the value of the showComplementFeatures property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowComplementFeatures(Boolean value) {
+            this.showComplementFeatures = value;
+        }
 
-    /**
-     * Sets the value of the showComplementFeatures property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowComplementFeatures(Boolean value)
-    {
-      this.showComplementFeatures = value;
-    }
+        /**
+         * Gets the value of the showComplementFeaturesOnTop property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isShowComplementFeaturesOnTop() {
+            if (showComplementFeaturesOnTop == null) {
+                return false;
+            } else {
+                return showComplementFeaturesOnTop;
+            }
+        }
 
-    /**
-     * Gets the value of the showComplementFeaturesOnTop property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isShowComplementFeaturesOnTop()
-    {
-      if (showComplementFeaturesOnTop == null)
-      {
-        return false;
-      }
-      else
-      {
-        return showComplementFeaturesOnTop;
-      }
-    }
+        /**
+         * Sets the value of the showComplementFeaturesOnTop property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setShowComplementFeaturesOnTop(Boolean value) {
+            this.showComplementFeaturesOnTop = value;
+        }
 
-    /**
-     * Sets the value of the showComplementFeaturesOnTop property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setShowComplementFeaturesOnTop(Boolean value)
-    {
-      this.showComplementFeaturesOnTop = value;
-    }
+        /**
+         * Gets the value of the width property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getWidth() {
+            return width;
+        }
 
-    /**
-     * Gets the value of the width property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getWidth()
-    {
-      return width;
-    }
+        /**
+         * Sets the value of the width property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setWidth(Integer value) {
+            this.width = value;
+        }
 
-    /**
-     * Sets the value of the width property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setWidth(Integer value)
-    {
-      this.width = value;
-    }
+        /**
+         * Gets the value of the height property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getHeight() {
+            return height;
+        }
 
-    /**
-     * Gets the value of the height property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getHeight()
-    {
-      return height;
-    }
+        /**
+         * Sets the value of the height property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setHeight(Integer value) {
+            this.height = value;
+        }
 
-    /**
-     * Sets the value of the height property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setHeight(Integer value)
-    {
-      this.height = value;
-    }
+        /**
+         * Gets the value of the xpos property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getXpos() {
+            return xpos;
+        }
 
-    /**
-     * Gets the value of the xpos property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getXpos()
-    {
-      return xpos;
-    }
+        /**
+         * Sets the value of the xpos property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setXpos(Integer value) {
+            this.xpos = value;
+        }
 
-    /**
-     * Sets the value of the xpos property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setXpos(Integer value)
-    {
-      this.xpos = value;
-    }
+        /**
+         * Gets the value of the ypos property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Integer }
+         *     
+         */
+        public Integer getYpos() {
+            return ypos;
+        }
 
-    /**
-     * Gets the value of the ypos property.
-     * 
-     * @return possible object is {@link Integer }
-     * 
-     */
-    public Integer getYpos()
-    {
-      return ypos;
-    }
+        /**
+         * Sets the value of the ypos property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Integer }
+         *     
+         */
+        public void setYpos(Integer value) {
+            this.ypos = value;
+        }
 
-    /**
-     * Sets the value of the ypos property.
-     * 
-     * @param value
-     *          allowed object is {@link Integer }
-     * 
-     */
-    public void setYpos(Integer value)
-    {
-      this.ypos = value;
-    }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;extension base="{www.jalview.org/xml/wsparamset}WebServiceParameterSet">
-     *       &lt;attribute name="calcId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *       &lt;attribute name="needsUpdate" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-     *       &lt;attribute name="autoUpdate" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *     &lt;/extension>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class CalcIdParam extends WebServiceParameterSet
-    {
-
-      @XmlAttribute(name = "calcId", required = true)
-      protected String calcId;
-
-      @XmlAttribute(name = "needsUpdate")
-      protected Boolean needsUpdate;
-
-      @XmlAttribute(name = "autoUpdate", required = true)
-      protected boolean autoUpdate;
-
-      /**
-       * Gets the value of the calcId property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getCalcId()
-      {
-        return calcId;
-      }
-
-      /**
-       * Sets the value of the calcId property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setCalcId(String value)
-      {
-        this.calcId = value;
-      }
-
-      /**
-       * Gets the value of the needsUpdate property.
-       * 
-       * @return possible object is {@link Boolean }
-       * 
-       */
-      public boolean isNeedsUpdate()
-      {
-        if (needsUpdate == null)
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;extension base="{www.jalview.org/xml/wsparamset}WebServiceParameterSet"&amp;gt;
+         *       &amp;lt;attribute name="calcId" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *       &amp;lt;attribute name="needsUpdate" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+         *       &amp;lt;attribute name="autoUpdate" use="required" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *     &amp;lt;/extension&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class CalcIdParam
+            extends WebServiceParameterSet
         {
-          return false;
+
+            @XmlAttribute(name = "calcId", required = true)
+            protected String calcId;
+            @XmlAttribute(name = "needsUpdate")
+            protected Boolean needsUpdate;
+            @XmlAttribute(name = "autoUpdate", required = true)
+            protected boolean autoUpdate;
+
+            /**
+             * Gets the value of the calcId property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getCalcId() {
+                return calcId;
+            }
+
+            /**
+             * Sets the value of the calcId property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setCalcId(String value) {
+                this.calcId = value;
+            }
+
+            /**
+             * Gets the value of the needsUpdate property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Boolean }
+             *     
+             */
+            public boolean isNeedsUpdate() {
+                if (needsUpdate == null) {
+                    return false;
+                } else {
+                    return needsUpdate;
+                }
+            }
+
+            /**
+             * Sets the value of the needsUpdate property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Boolean }
+             *     
+             */
+            public void setNeedsUpdate(Boolean value) {
+                this.needsUpdate = value;
+            }
+
+            /**
+             * Gets the value of the autoUpdate property.
+             * 
+             */
+            public boolean isAutoUpdate() {
+                return autoUpdate;
+            }
+
+            /**
+             * Sets the value of the autoUpdate property.
+             * 
+             */
+            public void setAutoUpdate(boolean value) {
+                this.autoUpdate = value;
+            }
+
         }
-        else
-        {
-          return needsUpdate;
-        }
-      }
-
-      /**
-       * Sets the value of the needsUpdate property.
-       * 
-       * @param value
-       *          allowed object is {@link Boolean }
-       * 
-       */
-      public void setNeedsUpdate(Boolean value)
-      {
-        this.needsUpdate = value;
-      }
-
-      /**
-       * Gets the value of the autoUpdate property.
-       * 
-       */
-      public boolean isAutoUpdate()
-      {
-        return autoUpdate;
-      }
-
-      /**
-       * Sets the value of the autoUpdate property.
-       * 
-       */
-      public void setAutoUpdate(boolean value)
-      {
-        this.autoUpdate = value;
-      }
 
-    }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class HiddenColumns
-    {
-
-      @XmlAttribute(name = "start")
-      protected Integer start;
-
-      @XmlAttribute(name = "end")
-      protected Integer end;
-
-      /**
-       * Gets the value of the start property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getStart()
-      {
-        return start;
-      }
-
-      /**
-       * Sets the value of the start property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setStart(Integer value)
-      {
-        this.start = value;
-      }
-
-      /**
-       * Gets the value of the end property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getEnd()
-      {
-        return end;
-      }
-
-      /**
-       * Sets the value of the end property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setEnd(Integer value)
-      {
-        this.end = value;
-      }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attribute name="start" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="end" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class HiddenColumns {
+
+            @XmlAttribute(name = "start")
+            protected Integer start;
+            @XmlAttribute(name = "end")
+            protected Integer end;
+
+            /**
+             * Gets the value of the start property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getStart() {
+                return start;
+            }
+
+            /**
+             * Sets the value of the start property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setStart(Integer value) {
+                this.start = value;
+            }
+
+            /**
+             * Gets the value of the end property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getEnd() {
+                return end;
+            }
+
+            /**
+             * Sets the value of the end property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setEnd(Integer value) {
+                this.end = value;
+            }
 
-    }
+        }
 
-    /**
-     * <p>
-     * Java class for anonymous complex type.
-     * 
-     * <p>
-     * The following schema fragment specifies the expected content contained
-     * within this class.
-     * 
-     * <pre>
-     * &lt;complexType>
-     *   &lt;complexContent>
-     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-     *       &lt;attGroup ref="{www.jalview.org}swingwindow"/>
-     *       &lt;attribute name="showHidden" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-     *       &lt;attribute name="residueColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="gapColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="hiddenColour" type="{http://www.w3.org/2001/XMLSchema}int" />
-     *       &lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" />
-     *     &lt;/restriction>
-     *   &lt;/complexContent>
-     * &lt;/complexType>
-     * </pre>
-     * 
-     * 
-     */
-    @XmlAccessorType(XmlAccessType.FIELD)
-    @XmlType(name = "")
-    public static class Overview
-    {
-
-      @XmlAttribute(name = "showHidden")
-      protected Boolean showHidden;
-
-      @XmlAttribute(name = "residueColour")
-      protected Integer residueColour;
-
-      @XmlAttribute(name = "gapColour")
-      protected Integer gapColour;
-
-      @XmlAttribute(name = "hiddenColour")
-      protected Integer hiddenColour;
-
-      @XmlAttribute(name = "title")
-      protected String title;
-
-      @XmlAttribute(name = "width")
-      protected Integer width;
-
-      @XmlAttribute(name = "height")
-      protected Integer height;
-
-      @XmlAttribute(name = "xpos")
-      protected Integer xpos;
-
-      @XmlAttribute(name = "ypos")
-      protected Integer ypos;
-
-      /**
-       * Gets the value of the showHidden property.
-       * 
-       * @return possible object is {@link Boolean }
-       * 
-       */
-      public Boolean isShowHidden()
-      {
-        return showHidden;
-      }
-
-      /**
-       * Sets the value of the showHidden property.
-       * 
-       * @param value
-       *          allowed object is {@link Boolean }
-       * 
-       */
-      public void setShowHidden(Boolean value)
-      {
-        this.showHidden = value;
-      }
-
-      /**
-       * Gets the value of the residueColour property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getResidueColour()
-      {
-        return residueColour;
-      }
-
-      /**
-       * Sets the value of the residueColour property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setResidueColour(Integer value)
-      {
-        this.residueColour = value;
-      }
-
-      /**
-       * Gets the value of the gapColour property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getGapColour()
-      {
-        return gapColour;
-      }
-
-      /**
-       * Sets the value of the gapColour property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setGapColour(Integer value)
-      {
-        this.gapColour = value;
-      }
-
-      /**
-       * Gets the value of the hiddenColour property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getHiddenColour()
-      {
-        return hiddenColour;
-      }
-
-      /**
-       * Sets the value of the hiddenColour property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setHiddenColour(Integer value)
-      {
-        this.hiddenColour = value;
-      }
-
-      /**
-       * Gets the value of the title property.
-       * 
-       * @return possible object is {@link String }
-       * 
-       */
-      public String getTitle()
-      {
-        return title;
-      }
-
-      /**
-       * Sets the value of the title property.
-       * 
-       * @param value
-       *          allowed object is {@link String }
-       * 
-       */
-      public void setTitle(String value)
-      {
-        this.title = value;
-      }
-
-      /**
-       * Gets the value of the width property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getWidth()
-      {
-        return width;
-      }
-
-      /**
-       * Sets the value of the width property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setWidth(Integer value)
-      {
-        this.width = value;
-      }
-
-      /**
-       * Gets the value of the height property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getHeight()
-      {
-        return height;
-      }
-
-      /**
-       * Sets the value of the height property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setHeight(Integer value)
-      {
-        this.height = value;
-      }
-
-      /**
-       * Gets the value of the xpos property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getXpos()
-      {
-        return xpos;
-      }
-
-      /**
-       * Sets the value of the xpos property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setXpos(Integer value)
-      {
-        this.xpos = value;
-      }
-
-      /**
-       * Gets the value of the ypos property.
-       * 
-       * @return possible object is {@link Integer }
-       * 
-       */
-      public Integer getYpos()
-      {
-        return ypos;
-      }
-
-      /**
-       * Sets the value of the ypos property.
-       * 
-       * @param value
-       *          allowed object is {@link Integer }
-       * 
-       */
-      public void setYpos(Integer value)
-      {
-        this.ypos = value;
-      }
 
-    }
+        /**
+         * &lt;p&gt;Java class for anonymous complex type.
+         * 
+         * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+         * 
+         * &lt;pre&gt;
+         * &amp;lt;complexType&amp;gt;
+         *   &amp;lt;complexContent&amp;gt;
+         *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+         *       &amp;lt;attGroup ref="{www.jalview.org}swingwindow"/&amp;gt;
+         *       &amp;lt;attribute name="showHidden" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+         *       &amp;lt;attribute name="residueColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="gapColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="hiddenColour" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+         *       &amp;lt;attribute name="title" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+         *     &amp;lt;/restriction&amp;gt;
+         *   &amp;lt;/complexContent&amp;gt;
+         * &amp;lt;/complexType&amp;gt;
+         * &lt;/pre&gt;
+         * 
+         * 
+         */
+        @XmlAccessorType(XmlAccessType.FIELD)
+        @XmlType(name = "")
+        public static class Overview {
+
+            @XmlAttribute(name = "showHidden")
+            protected Boolean showHidden;
+            @XmlAttribute(name = "residueColour")
+            protected Integer residueColour;
+            @XmlAttribute(name = "gapColour")
+            protected Integer gapColour;
+            @XmlAttribute(name = "hiddenColour")
+            protected Integer hiddenColour;
+            @XmlAttribute(name = "title")
+            protected String title;
+            @XmlAttribute(name = "width")
+            protected Integer width;
+            @XmlAttribute(name = "height")
+            protected Integer height;
+            @XmlAttribute(name = "xpos")
+            protected Integer xpos;
+            @XmlAttribute(name = "ypos")
+            protected Integer ypos;
+
+            /**
+             * Gets the value of the showHidden property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Boolean }
+             *     
+             */
+            public Boolean isShowHidden() {
+                return showHidden;
+            }
+
+            /**
+             * Sets the value of the showHidden property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Boolean }
+             *     
+             */
+            public void setShowHidden(Boolean value) {
+                this.showHidden = value;
+            }
+
+            /**
+             * Gets the value of the residueColour property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getResidueColour() {
+                return residueColour;
+            }
+
+            /**
+             * Sets the value of the residueColour property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setResidueColour(Integer value) {
+                this.residueColour = value;
+            }
+
+            /**
+             * Gets the value of the gapColour property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getGapColour() {
+                return gapColour;
+            }
+
+            /**
+             * Sets the value of the gapColour property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setGapColour(Integer value) {
+                this.gapColour = value;
+            }
+
+            /**
+             * Gets the value of the hiddenColour property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getHiddenColour() {
+                return hiddenColour;
+            }
+
+            /**
+             * Sets the value of the hiddenColour property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setHiddenColour(Integer value) {
+                this.hiddenColour = value;
+            }
+
+            /**
+             * Gets the value of the title property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link String }
+             *     
+             */
+            public String getTitle() {
+                return title;
+            }
+
+            /**
+             * Sets the value of the title property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link String }
+             *     
+             */
+            public void setTitle(String value) {
+                this.title = value;
+            }
+
+            /**
+             * Gets the value of the width property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getWidth() {
+                return width;
+            }
+
+            /**
+             * Sets the value of the width property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setWidth(Integer value) {
+                this.width = value;
+            }
+
+            /**
+             * Gets the value of the height property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getHeight() {
+                return height;
+            }
+
+            /**
+             * Sets the value of the height property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setHeight(Integer value) {
+                this.height = value;
+            }
+
+            /**
+             * Gets the value of the xpos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getXpos() {
+                return xpos;
+            }
+
+            /**
+             * Sets the value of the xpos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setXpos(Integer value) {
+                this.xpos = value;
+            }
+
+            /**
+             * Gets the value of the ypos property.
+             * 
+             * @return
+             *     possible object is
+             *     {@link Integer }
+             *     
+             */
+            public Integer getYpos() {
+                return ypos;
+            }
+
+            /**
+             * Sets the value of the ypos property.
+             * 
+             * @param value
+             *     allowed object is
+             *     {@link Integer }
+             *     
+             */
+            public void setYpos(Integer value) {
+                this.ypos = value;
+            }
+
+        }
 
-  }
+    }
 
 }
index e4b160f..592ef1b 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -15,613 +16,597 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for JalviewUserColours complex type.
+ * &lt;p&gt;Java class for JalviewUserColours complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="JalviewUserColours">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="Version" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="colour" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;sequence>
- *                   &lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/>
- *                 &lt;/sequence>
- *                 &lt;attribute name="Name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="RGB" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="minRGB" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" />
- *                 &lt;attribute name="threshType" type="{www.jalview.org/colours}ThresholdType" />
- *                 &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                 &lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                 &lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" />
- *                 &lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *                 &lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *         &lt;element name="filter" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;sequence>
- *                   &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet"/>
- *                 &lt;/sequence>
- *                 &lt;attribute name="featureType" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/sequence>
- *       &lt;attribute name="schemeName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="JalviewUserColours"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="Version" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="colour" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;sequence&amp;gt;
+ *                   &amp;lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/&amp;gt;
+ *                 &amp;lt;/sequence&amp;gt;
+ *                 &amp;lt;attribute name="Name" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="RGB" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="minRGB" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" /&amp;gt;
+ *                 &amp;lt;attribute name="threshType" type="{www.jalview.org/colours}ThresholdType" /&amp;gt;
+ *                 &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                 &amp;lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                 &amp;lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+ *                 &amp;lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *                 &amp;lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *         &amp;lt;element name="filter" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;sequence&amp;gt;
+ *                   &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet"/&amp;gt;
+ *                 &amp;lt;/sequence&amp;gt;
+ *                 &amp;lt;attribute name="featureType" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="schemeName" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "JalviewUserColours",
-  namespace = "www.jalview.org/colours",
-  propOrder =
-  { "version", "colour", "filter" })
-public class JalviewUserColours
-{
-
-  @XmlElement(name = "Version", namespace = "")
-  protected String version;
-
-  @XmlElement(namespace = "")
-  protected List<JalviewUserColours.Colour> colour;
-
-  @XmlElement(namespace = "")
-  protected List<JalviewUserColours.Filter> filter;
-
-  @XmlAttribute(name = "schemeName")
-  protected String schemeName;
-
-  /**
-   * Gets the value of the version property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getVersion()
-  {
-    return version;
-  }
-
-  /**
-   * Sets the value of the version property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setVersion(String value)
-  {
-    this.version = value;
-  }
-
-  /**
-   * Gets the value of the colour property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the colour property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getColour().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewUserColours.Colour }
-   * 
-   * 
-   */
-  public List<JalviewUserColours.Colour> getColour()
-  {
-    if (colour == null)
-    {
-      colour = new ArrayList<JalviewUserColours.Colour>();
-    }
-    return this.colour;
-  }
-
-  /**
-   * Gets the value of the filter property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the filter property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getFilter().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link JalviewUserColours.Filter }
-   * 
-   * 
-   */
-  public List<JalviewUserColours.Filter> getFilter()
-  {
-    if (filter == null)
-    {
-      filter = new ArrayList<JalviewUserColours.Filter>();
-    }
-    return this.filter;
-  }
-
-  /**
-   * Gets the value of the schemeName property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getSchemeName()
-  {
-    return schemeName;
-  }
-
-  /**
-   * Sets the value of the schemeName property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setSchemeName(String value)
-  {
-    this.schemeName = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="Name" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="RGB" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="minRGB" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" />
-   *       &lt;attribute name="threshType" type="{www.jalview.org/colours}ThresholdType" />
-   *       &lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *       &lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *       &lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" />
-   *       &lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *       &lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "attributeName" })
-  public static class Colour
-  {
-
+@XmlType(name = "JalviewUserColours", namespace = "www.jalview.org/colours", propOrder = {
+    "version",
+    "colour",
+    "filter"
+})
+public class JalviewUserColours {
+
+    @XmlElement(name = "Version", namespace = "")
+    protected String version;
     @XmlElement(namespace = "")
-    protected List<String> attributeName;
-
-    @XmlAttribute(name = "Name")
-    protected String name;
-
-    @XmlAttribute(name = "RGB", required = true)
-    protected String rgb;
-
-    @XmlAttribute(name = "minRGB")
-    protected String minRGB;
-
-    @XmlAttribute(name = "noValueColour")
-    protected NoValueColour noValueColour;
-
-    @XmlAttribute(name = "threshType")
-    protected ThresholdType threshType;
-
-    @XmlAttribute(name = "threshold")
-    protected Float threshold;
-
-    @XmlAttribute(name = "max")
-    protected Float max;
-
-    @XmlAttribute(name = "min")
-    protected Float min;
-
-    @XmlAttribute(name = "colourByLabel")
-    protected Boolean colourByLabel;
-
-    @XmlAttribute(name = "autoScale")
-    protected Boolean autoScale;
-
-    /**
-     * Gets the value of the attributeName property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the attributeName property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * 
-     * <pre>
-     * getAttributeName().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list {@link String }
-     * 
-     * 
-     */
-    public List<String> getAttributeName()
-    {
-      if (attributeName == null)
-      {
-        attributeName = new ArrayList<String>();
-      }
-      return this.attributeName;
-    }
-
-    /**
-     * Gets the value of the name property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getName()
-    {
-      return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setName(String value)
-    {
-      this.name = value;
-    }
-
-    /**
-     * Gets the value of the rgb property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getRGB()
-    {
-      return rgb;
-    }
-
-    /**
-     * Sets the value of the rgb property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setRGB(String value)
-    {
-      this.rgb = value;
-    }
-
-    /**
-     * Gets the value of the minRGB property.
-     * 
-     * @return possible object is {@link String }
-     * 
-     */
-    public String getMinRGB()
-    {
-      return minRGB;
-    }
-
-    /**
-     * Sets the value of the minRGB property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setMinRGB(String value)
-    {
-      this.minRGB = value;
-    }
+    protected List<JalviewUserColours.Colour> colour;
+    @XmlElement(namespace = "")
+    protected List<JalviewUserColours.Filter> filter;
+    @XmlAttribute(name = "schemeName")
+    protected String schemeName;
 
     /**
-     * Gets the value of the noValueColour property.
-     * 
-     * @return possible object is {@link NoValueColour }
+     * Gets the value of the version property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public NoValueColour getNoValueColour()
-    {
-      if (noValueColour == null)
-      {
-        return NoValueColour.MIN;
-      }
-      else
-      {
-        return noValueColour;
-      }
+    public String getVersion() {
+        return version;
     }
 
     /**
-     * Sets the value of the noValueColour property.
+     * Sets the value of the version property.
      * 
      * @param value
-     *          allowed object is {@link NoValueColour }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public void setNoValueColour(NoValueColour value)
-    {
-      this.noValueColour = value;
+    public void setVersion(String value) {
+        this.version = value;
     }
 
     /**
-     * Gets the value of the threshType property.
+     * Gets the value of the colour property.
      * 
-     * @return possible object is {@link ThresholdType }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the colour property.
      * 
-     */
-    public ThresholdType getThreshType()
-    {
-      return threshType;
-    }
-
-    /**
-     * Sets the value of the threshType property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getColour().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @param value
-     *          allowed object is {@link ThresholdType }
      * 
-     */
-    public void setThreshType(ThresholdType value)
-    {
-      this.threshType = value;
-    }
-
-    /**
-     * Gets the value of the threshold property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewUserColours.Colour }
      * 
-     * @return possible object is {@link Float }
      * 
      */
-    public Float getThreshold()
-    {
-      return threshold;
+    public List<JalviewUserColours.Colour> getColour() {
+        if (colour == null) {
+            colour = new ArrayList<JalviewUserColours.Colour>();
+        }
+        return this.colour;
     }
 
     /**
-     * Sets the value of the threshold property.
+     * Gets the value of the filter property.
      * 
-     * @param value
-     *          allowed object is {@link Float }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the filter property.
      * 
-     */
-    public void setThreshold(Float value)
-    {
-      this.threshold = value;
-    }
-
-    /**
-     * Gets the value of the max property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getFilter().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Float }
      * 
-     */
-    public Float getMax()
-    {
-      return max;
-    }
-
-    /**
-     * Sets the value of the max property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link JalviewUserColours.Filter }
      * 
-     * @param value
-     *          allowed object is {@link Float }
      * 
      */
-    public void setMax(Float value)
-    {
-      this.max = value;
+    public List<JalviewUserColours.Filter> getFilter() {
+        if (filter == null) {
+            filter = new ArrayList<JalviewUserColours.Filter>();
+        }
+        return this.filter;
     }
 
     /**
-     * Gets the value of the min property.
-     * 
-     * @return possible object is {@link Float }
+     * Gets the value of the schemeName property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public Float getMin()
-    {
-      return min;
+    public String getSchemeName() {
+        return schemeName;
     }
 
     /**
-     * Sets the value of the min property.
+     * Sets the value of the schemeName property.
      * 
      * @param value
-     *          allowed object is {@link Float }
-     * 
-     */
-    public void setMin(Float value)
-    {
-      this.min = value;
-    }
-
-    /**
-     * Gets the value of the colourByLabel property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public Boolean isColourByLabel()
-    {
-      return colourByLabel;
+    public void setSchemeName(String value) {
+        this.schemeName = value;
     }
 
-    /**
-     * Sets the value of the colourByLabel property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setColourByLabel(Boolean value)
-    {
-      this.colourByLabel = value;
-    }
 
     /**
-     * Gets the value of the autoScale property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="attributeName" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="2" minOccurs="0"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="Name" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="RGB" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="minRGB" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="noValueColour" type="{www.jalview.org/colours}NoValueColour" default="Min" /&amp;gt;
+     *       &amp;lt;attribute name="threshType" type="{www.jalview.org/colours}ThresholdType" /&amp;gt;
+     *       &amp;lt;attribute name="threshold" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *       &amp;lt;attribute name="max" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *       &amp;lt;attribute name="min" type="{http://www.w3.org/2001/XMLSchema}float" /&amp;gt;
+     *       &amp;lt;attribute name="colourByLabel" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *       &amp;lt;attribute name="autoScale" type="{http://www.w3.org/2001/XMLSchema}boolean" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Boolean }
      * 
      */
-    public Boolean isAutoScale()
-    {
-      return autoScale;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "attributeName"
+    })
+    public static class Colour {
+
+        @XmlElement(namespace = "")
+        protected List<String> attributeName;
+        @XmlAttribute(name = "Name")
+        protected String name;
+        @XmlAttribute(name = "RGB", required = true)
+        protected String rgb;
+        @XmlAttribute(name = "minRGB")
+        protected String minRGB;
+        @XmlAttribute(name = "noValueColour")
+        protected NoValueColour noValueColour;
+        @XmlAttribute(name = "threshType")
+        protected ThresholdType threshType;
+        @XmlAttribute(name = "threshold")
+        protected Float threshold;
+        @XmlAttribute(name = "max")
+        protected Float max;
+        @XmlAttribute(name = "min")
+        protected Float min;
+        @XmlAttribute(name = "colourByLabel")
+        protected Boolean colourByLabel;
+        @XmlAttribute(name = "autoScale")
+        protected Boolean autoScale;
+
+        /**
+         * Gets the value of the attributeName property.
+         * 
+         * &lt;p&gt;
+         * This accessor method returns a reference to the live list,
+         * not a snapshot. Therefore any modification you make to the
+         * returned list will be present inside the JAXB object.
+         * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the attributeName property.
+         * 
+         * &lt;p&gt;
+         * For example, to add a new item, do as follows:
+         * &lt;pre&gt;
+         *    getAttributeName().add(newItem);
+         * &lt;/pre&gt;
+         * 
+         * 
+         * &lt;p&gt;
+         * Objects of the following type(s) are allowed in the list
+         * {@link String }
+         * 
+         * 
+         */
+        public List<String> getAttributeName() {
+            if (attributeName == null) {
+                attributeName = new ArrayList<String>();
+            }
+            return this.attributeName;
+        }
+
+        /**
+         * Gets the value of the name property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getName() {
+            return name;
+        }
+
+        /**
+         * Sets the value of the name property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setName(String value) {
+            this.name = value;
+        }
+
+        /**
+         * Gets the value of the rgb property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getRGB() {
+            return rgb;
+        }
+
+        /**
+         * Sets the value of the rgb property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setRGB(String value) {
+            this.rgb = value;
+        }
+
+        /**
+         * Gets the value of the minRGB property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getMinRGB() {
+            return minRGB;
+        }
+
+        /**
+         * Sets the value of the minRGB property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setMinRGB(String value) {
+            this.minRGB = value;
+        }
+
+        /**
+         * Gets the value of the noValueColour property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link NoValueColour }
+         *     
+         */
+        public NoValueColour getNoValueColour() {
+            if (noValueColour == null) {
+                return NoValueColour.MIN;
+            } else {
+                return noValueColour;
+            }
+        }
+
+        /**
+         * Sets the value of the noValueColour property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link NoValueColour }
+         *     
+         */
+        public void setNoValueColour(NoValueColour value) {
+            this.noValueColour = value;
+        }
+
+        /**
+         * Gets the value of the threshType property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link ThresholdType }
+         *     
+         */
+        public ThresholdType getThreshType() {
+            return threshType;
+        }
+
+        /**
+         * Sets the value of the threshType property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link ThresholdType }
+         *     
+         */
+        public void setThreshType(ThresholdType value) {
+            this.threshType = value;
+        }
+
+        /**
+         * Gets the value of the threshold property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Float }
+         *     
+         */
+        public Float getThreshold() {
+            return threshold;
+        }
+
+        /**
+         * Sets the value of the threshold property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Float }
+         *     
+         */
+        public void setThreshold(Float value) {
+            this.threshold = value;
+        }
+
+        /**
+         * Gets the value of the max property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Float }
+         *     
+         */
+        public Float getMax() {
+            return max;
+        }
+
+        /**
+         * Sets the value of the max property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Float }
+         *     
+         */
+        public void setMax(Float value) {
+            this.max = value;
+        }
+
+        /**
+         * Gets the value of the min property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Float }
+         *     
+         */
+        public Float getMin() {
+            return min;
+        }
+
+        /**
+         * Sets the value of the min property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Float }
+         *     
+         */
+        public void setMin(Float value) {
+            this.min = value;
+        }
+
+        /**
+         * Gets the value of the colourByLabel property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isColourByLabel() {
+            return colourByLabel;
+        }
+
+        /**
+         * Sets the value of the colourByLabel property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setColourByLabel(Boolean value) {
+            this.colourByLabel = value;
+        }
+
+        /**
+         * Gets the value of the autoScale property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public Boolean isAutoScale() {
+            return autoScale;
+        }
+
+        /**
+         * Sets the value of the autoScale property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setAutoScale(Boolean value) {
+            this.autoScale = value;
+        }
 
-    /**
-     * Sets the value of the autoScale property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setAutoScale(Boolean value)
-    {
-      this.autoScale = value;
     }
 
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="featureType" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "matcherSet" })
-  public static class Filter
-  {
-
-    @XmlElement(namespace = "", required = true)
-    protected FeatureMatcherSet matcherSet;
-
-    @XmlAttribute(name = "featureType", required = true)
-    protected String featureType;
-
-    /**
-     * Gets the value of the matcherSet property.
-     * 
-     * @return possible object is {@link FeatureMatcherSet }
-     * 
-     */
-    public FeatureMatcherSet getMatcherSet()
-    {
-      return matcherSet;
-    }
 
     /**
-     * Sets the value of the matcherSet property.
+     * &lt;p&gt;Java class for anonymous complex type.
      * 
-     * @param value
-     *          allowed object is {@link FeatureMatcherSet }
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
      * 
-     */
-    public void setMatcherSet(FeatureMatcherSet value)
-    {
-      this.matcherSet = value;
-    }
-
-    /**
-     * Gets the value of the featureType property.
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element name="matcherSet" type="{www.jalview.org/colours}FeatureMatcherSet"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="featureType" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link String }
      * 
      */
-    public String getFeatureType()
-    {
-      return featureType;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "matcherSet"
+    })
+    public static class Filter {
+
+        @XmlElement(namespace = "", required = true)
+        protected FeatureMatcherSet matcherSet;
+        @XmlAttribute(name = "featureType", required = true)
+        protected String featureType;
+
+        /**
+         * Gets the value of the matcherSet property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link FeatureMatcherSet }
+         *     
+         */
+        public FeatureMatcherSet getMatcherSet() {
+            return matcherSet;
+        }
+
+        /**
+         * Sets the value of the matcherSet property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link FeatureMatcherSet }
+         *     
+         */
+        public void setMatcherSet(FeatureMatcherSet value) {
+            this.matcherSet = value;
+        }
+
+        /**
+         * Gets the value of the featureType property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getFeatureType() {
+            return featureType;
+        }
+
+        /**
+         * Sets the value of the featureType property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setFeatureType(String value) {
+            this.featureType = value;
+        }
 
-    /**
-     * Sets the value of the featureType property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
-     * 
-     */
-    public void setFeatureType(String value)
-    {
-      this.featureType = value;
     }
 
-  }
-
 }
index 1f16680..d5cd7a8 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.math.BigInteger;
@@ -17,319 +18,299 @@ import javax.xml.bind.annotation.XmlSchemaType;
 import javax.xml.bind.annotation.XmlSeeAlso;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
  * 
- * This effectively represents a java.util.MapList object
+ *                             This effectively represents a java.util.MapList
+ *                             object
+ *                     
  * 
+ * &lt;p&gt;Java class for mapListType complex type.
  * 
- * <p>
- * Java class for mapListType complex type.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * 
- * <pre>
- * &lt;complexType name="mapListType">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="mapListFrom" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                 &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *         &lt;element name="mapListTo" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *                 &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/sequence>
- *       &lt;attribute name="mapFromUnit" use="required" type="{http://www.w3.org/2001/XMLSchema}positiveInteger" />
- *       &lt;attribute name="mapToUnit" use="required" type="{http://www.w3.org/2001/XMLSchema}positiveInteger" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="mapListType"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="mapListFrom" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                 &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *         &amp;lt;element name="mapListTo" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *                 &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="mapFromUnit" use="required" type="{http://www.w3.org/2001/XMLSchema}positiveInteger" /&amp;gt;
+ *       &amp;lt;attribute name="mapToUnit" use="required" type="{http://www.w3.org/2001/XMLSchema}positiveInteger" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "mapListType", propOrder = { "mapListFrom", "mapListTo" })
-@XmlSeeAlso({ Mapping.class })
-public class MapListType
-{
-
-  protected List<MapListType.MapListFrom> mapListFrom;
-
-  protected List<MapListType.MapListTo> mapListTo;
-
-  @XmlAttribute(name = "mapFromUnit", required = true)
-  @XmlSchemaType(name = "positiveInteger")
-  protected BigInteger mapFromUnit;
-
-  @XmlAttribute(name = "mapToUnit", required = true)
-  @XmlSchemaType(name = "positiveInteger")
-  protected BigInteger mapToUnit;
-
-  /**
-   * Gets the value of the mapListFrom property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the mapListFrom property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getMapListFrom().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link MapListType.MapListFrom }
-   * 
-   * 
-   */
-  public List<MapListType.MapListFrom> getMapListFrom()
-  {
-    if (mapListFrom == null)
-    {
-      mapListFrom = new ArrayList<MapListType.MapListFrom>();
-    }
-    return this.mapListFrom;
-  }
-
-  /**
-   * Gets the value of the mapListTo property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the mapListTo property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getMapListTo().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link MapListType.MapListTo }
-   * 
-   * 
-   */
-  public List<MapListType.MapListTo> getMapListTo()
-  {
-    if (mapListTo == null)
-    {
-      mapListTo = new ArrayList<MapListType.MapListTo>();
-    }
-    return this.mapListTo;
-  }
-
-  /**
-   * Gets the value of the mapFromUnit property.
-   * 
-   * @return possible object is {@link BigInteger }
-   * 
-   */
-  public BigInteger getMapFromUnit()
-  {
-    return mapFromUnit;
-  }
-
-  /**
-   * Sets the value of the mapFromUnit property.
-   * 
-   * @param value
-   *          allowed object is {@link BigInteger }
-   * 
-   */
-  public void setMapFromUnit(BigInteger value)
-  {
-    this.mapFromUnit = value;
-  }
+@XmlType(name = "mapListType", propOrder = {
+    "mapListFrom",
+    "mapListTo"
+})
+@XmlSeeAlso({
+    Mapping.class
+})
+public class MapListType {
 
-  /**
-   * Gets the value of the mapToUnit property.
-   * 
-   * @return possible object is {@link BigInteger }
-   * 
-   */
-  public BigInteger getMapToUnit()
-  {
-    return mapToUnit;
-  }
-
-  /**
-   * Sets the value of the mapToUnit property.
-   * 
-   * @param value
-   *          allowed object is {@link BigInteger }
-   * 
-   */
-  public void setMapToUnit(BigInteger value)
-  {
-    this.mapToUnit = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class MapListFrom
-  {
-
-    @XmlAttribute(name = "start", required = true)
-    protected int start;
-
-    @XmlAttribute(name = "end", required = true)
-    protected int end;
+    protected List<MapListType.MapListFrom> mapListFrom;
+    protected List<MapListType.MapListTo> mapListTo;
+    @XmlAttribute(name = "mapFromUnit", required = true)
+    @XmlSchemaType(name = "positiveInteger")
+    protected BigInteger mapFromUnit;
+    @XmlAttribute(name = "mapToUnit", required = true)
+    @XmlSchemaType(name = "positiveInteger")
+    protected BigInteger mapToUnit;
 
     /**
-     * Gets the value of the start property.
+     * Gets the value of the mapListFrom property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the mapListFrom property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getMapListFrom().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link MapListType.MapListFrom }
+     * 
      * 
      */
-    public int getStart()
-    {
-      return start;
+    public List<MapListType.MapListFrom> getMapListFrom() {
+        if (mapListFrom == null) {
+            mapListFrom = new ArrayList<MapListType.MapListFrom>();
+        }
+        return this.mapListFrom;
     }
 
     /**
-     * Sets the value of the start property.
+     * Gets the value of the mapListTo property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the mapListTo property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getMapListTo().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link MapListType.MapListTo }
+     * 
      * 
      */
-    public void setStart(int value)
-    {
-      this.start = value;
+    public List<MapListType.MapListTo> getMapListTo() {
+        if (mapListTo == null) {
+            mapListTo = new ArrayList<MapListType.MapListTo>();
+        }
+        return this.mapListTo;
     }
 
     /**
-     * Gets the value of the end property.
+     * Gets the value of the mapFromUnit property.
      * 
+     * @return
+     *     possible object is
+     *     {@link BigInteger }
+     *     
      */
-    public int getEnd()
-    {
-      return end;
+    public BigInteger getMapFromUnit() {
+        return mapFromUnit;
     }
 
     /**
-     * Sets the value of the end property.
+     * Sets the value of the mapFromUnit property.
      * 
+     * @param value
+     *     allowed object is
+     *     {@link BigInteger }
+     *     
      */
-    public void setEnd(int value)
-    {
-      this.end = value;
+    public void setMapFromUnit(BigInteger value) {
+        this.mapFromUnit = value;
     }
 
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *       &lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class MapListTo
-  {
-
-    @XmlAttribute(name = "start", required = true)
-    protected int start;
-
-    @XmlAttribute(name = "end", required = true)
-    protected int end;
-
     /**
-     * Gets the value of the start property.
+     * Gets the value of the mapToUnit property.
      * 
+     * @return
+     *     possible object is
+     *     {@link BigInteger }
+     *     
      */
-    public int getStart()
-    {
-      return start;
+    public BigInteger getMapToUnit() {
+        return mapToUnit;
     }
 
     /**
-     * Sets the value of the start property.
+     * Sets the value of the mapToUnit property.
      * 
+     * @param value
+     *     allowed object is
+     *     {@link BigInteger }
+     *     
      */
-    public void setStart(int value)
-    {
-      this.start = value;
+    public void setMapToUnit(BigInteger value) {
+        this.mapToUnit = value;
     }
 
+
     /**
-     * Gets the value of the end property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
      * 
      */
-    public int getEnd()
-    {
-      return end;
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class MapListFrom {
+
+        @XmlAttribute(name = "start", required = true)
+        protected int start;
+        @XmlAttribute(name = "end", required = true)
+        protected int end;
+
+        /**
+         * Gets the value of the start property.
+         * 
+         */
+        public int getStart() {
+            return start;
+        }
+
+        /**
+         * Sets the value of the start property.
+         * 
+         */
+        public void setStart(int value) {
+            this.start = value;
+        }
+
+        /**
+         * Gets the value of the end property.
+         * 
+         */
+        public int getEnd() {
+            return end;
+        }
+
+        /**
+         * Sets the value of the end property.
+         * 
+         */
+        public void setEnd(int value) {
+            this.end = value;
+        }
+
     }
 
+
     /**
-     * Sets the value of the end property.
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="start" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *       &amp;lt;attribute name="end" use="required" type="{http://www.w3.org/2001/XMLSchema}int" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
      * 
      */
-    public void setEnd(int value)
-    {
-      this.end = value;
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class MapListTo {
 
-  }
+        @XmlAttribute(name = "start", required = true)
+        protected int start;
+        @XmlAttribute(name = "end", required = true)
+        protected int end;
+
+        /**
+         * Gets the value of the start property.
+         * 
+         */
+        public int getStart() {
+            return start;
+        }
+
+        /**
+         * Sets the value of the start property.
+         * 
+         */
+        public void setStart(int value) {
+            this.start = value;
+        }
+
+        /**
+         * Gets the value of the end property.
+         * 
+         */
+        public int getEnd() {
+            return end;
+        }
+
+        /**
+         * Sets the value of the end property.
+         * 
+         */
+        public void setEnd(int value) {
+            this.end = value;
+        }
+
+    }
 
 }
diff --git a/src/jalview/xml/binding/jalview/MapOnAMatrixType.java b/src/jalview/xml/binding/jalview/MapOnAMatrixType.java
new file mode 100644 (file)
index 0000000..d48a315
--- /dev/null
@@ -0,0 +1,160 @@
+//
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
+// Any modifications to this file will be lost upon recompilation of the source schema. 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
+//
+
+
+package jalview.xml.binding.jalview;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * Defines a mapping from the local frame to a matrix
+ *                             and its associated data specified by MatrixType
+ *                     
+ * 
+ * &lt;p&gt;Java class for MapOnAMatrixType complex type.
+ * 
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+ * 
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="MapOnAMatrixType"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="property" type="{www.vamsas.ac.uk/jalview/version2}property" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="mapping" type="{www.vamsas.ac.uk/jalview/version2}mapListType" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="matrix" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
+ * 
+ * 
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "MapOnAMatrixType", propOrder = {
+    "property",
+    "mapping"
+})
+public class MapOnAMatrixType {
+
+    protected List<Property> property;
+    protected MapListType mapping;
+    @XmlAttribute(name = "matrix", required = true)
+    protected String matrix;
+    @XmlAttribute(name = "id")
+    protected String id;
+
+    /**
+     * Gets the value of the property property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the property property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getProperty().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Property }
+     * 
+     * 
+     */
+    public List<Property> getProperty() {
+        if (property == null) {
+            property = new ArrayList<Property>();
+        }
+        return this.property;
+    }
+
+    /**
+     * Gets the value of the mapping property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link MapListType }
+     *     
+     */
+    public MapListType getMapping() {
+        return mapping;
+    }
+
+    /**
+     * Sets the value of the mapping property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link MapListType }
+     *     
+     */
+    public void setMapping(MapListType value) {
+        this.mapping = value;
+    }
+
+    /**
+     * Gets the value of the matrix property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getMatrix() {
+        return matrix;
+    }
+
+    /**
+     * Sets the value of the matrix property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setMatrix(String value) {
+        this.matrix = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setId(String value) {
+        this.id = value;
+    }
+
+}
index 69bf01d..9c98af8 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlAccessType;
@@ -14,124 +15,130 @@ import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
  * 
- * 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).
+ *                             
  * 
- * <p>
- * Java class for anonymous complex type.
+ * &lt;p&gt;Java class for anonymous complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType>
- *   &lt;complexContent>
- *     &lt;extension base="{www.vamsas.ac.uk/jalview/version2}mapListType">
- *       &lt;sequence>
- *         &lt;choice minOccurs="0">
- *           &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Sequence"/>
- *           &lt;element name="dseqFor">
- *             &lt;simpleType>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
- *               &lt;/restriction>
- *             &lt;/simpleType>
- *           &lt;/element>
- *         &lt;/choice>
- *       &lt;/sequence>
- *       &lt;attribute name="mappingType" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;extension base="{www.vamsas.ac.uk/jalview/version2}mapListType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;choice minOccurs="0"&amp;gt;
+ *           &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Sequence"/&amp;gt;
+ *           &amp;lt;element name="dseqFor"&amp;gt;
+ *             &amp;lt;simpleType&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}string"&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/simpleType&amp;gt;
+ *           &amp;lt;/element&amp;gt;
+ *         &amp;lt;/choice&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="mappingType" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/extension&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "", propOrder = { "sequence", "dseqFor" })
+@XmlType(name = "", propOrder = {
+    "sequence",
+    "dseqFor"
+})
 @XmlRootElement(name = "Mapping")
-public class Mapping extends MapListType
+public class Mapping
+    extends MapListType
 {
 
-  @XmlElement(name = "Sequence")
-  protected Sequence sequence;
-
-  protected String dseqFor;
-
-  @XmlAttribute(name = "mappingType")
-  protected String mappingType;
+    @XmlElement(name = "Sequence")
+    protected Sequence sequence;
+    protected String dseqFor;
+    @XmlAttribute(name = "mappingType")
+    protected String mappingType;
 
-  /**
-   * Gets the value of the sequence property.
-   * 
-   * @return possible object is {@link Sequence }
-   * 
-   */
-  public Sequence getSequence()
-  {
-    return sequence;
-  }
+    /**
+     * Gets the value of the sequence property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Sequence }
+     *     
+     */
+    public Sequence getSequence() {
+        return sequence;
+    }
 
-  /**
-   * Sets the value of the sequence property.
-   * 
-   * @param value
-   *          allowed object is {@link Sequence }
-   * 
-   */
-  public void setSequence(Sequence value)
-  {
-    this.sequence = value;
-  }
+    /**
+     * Sets the value of the sequence property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Sequence }
+     *     
+     */
+    public void setSequence(Sequence value) {
+        this.sequence = value;
+    }
 
-  /**
-   * Gets the value of the dseqFor property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDseqFor()
-  {
-    return dseqFor;
-  }
+    /**
+     * Gets the value of the dseqFor property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getDseqFor() {
+        return dseqFor;
+    }
 
-  /**
-   * Sets the value of the dseqFor property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDseqFor(String value)
-  {
-    this.dseqFor = value;
-  }
+    /**
+     * Sets the value of the dseqFor property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDseqFor(String value) {
+        this.dseqFor = value;
+    }
 
-  /**
-   * Gets the value of the mappingType property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getMappingType()
-  {
-    return mappingType;
-  }
+    /**
+     * Gets the value of the mappingType property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getMappingType() {
+        return mappingType;
+    }
 
-  /**
-   * Sets the value of the mappingType property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setMappingType(String value)
-  {
-    this.mappingType = value;
-  }
+    /**
+     * Sets the value of the mappingType property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setMappingType(String value) {
+        this.mappingType = value;
+    }
 
 }
index c405597..34d1158 100644 (file)
@@ -1,8 +1,8 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
 
@@ -19,349 +19,319 @@ import javax.xml.bind.annotation.XmlType;
 
 
 /**
- * <p>
- * Java class for MatrixType complex type.
+ * Represents matrix data imported to Jalview, and the
+ *                             results of any derived calculations (independent of a particular
+ *                             view
+ *                             on the matrix).
+ *                     
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;Java class for MatrixType complex type.
  * 
- * <pre>
- * &lt;complexType name="MatrixType">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="elements" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *         &lt;element name="groups" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="newick" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="property" type="{www.vamsas.ac.uk/jalview/version2}property" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="mapping" type="{www.vamsas.ac.uk/jalview/version2}mapListType" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="rows" use="required" type="{http://www.w3.org/2001/XMLSchema}integer" />
- *       &lt;attribute name="cols" use="required" type="{http://www.w3.org/2001/XMLSchema}integer" />
- *       &lt;attribute name="treeMethod" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="cutHeight" type="{http://www.w3.org/2001/XMLSchema}double" />
- *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+ * 
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="MatrixType"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="elements" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *         &amp;lt;element name="groups" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="newick" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="property" type="{www.vamsas.ac.uk/jalview/version2}property" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="type" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="rows" use="required" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+ *       &amp;lt;attribute name="cols" use="required" type="{http://www.w3.org/2001/XMLSchema}integer" /&amp;gt;
+ *       &amp;lt;attribute name="treeMethod" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="cutHeight" type="{http://www.w3.org/2001/XMLSchema}double" /&amp;gt;
+ *       &amp;lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "MatrixType",
-  propOrder =
-  { "elements", "groups", "newick", "property", "mapping" })
-public class MatrixType
-{
-
-  @XmlElement(required = true)
-  protected String elements;
-
-  protected List<String> groups;
-
-  protected List<String> newick;
-
-  protected List<Property> property;
-
-  protected MapListType mapping;
-
-  @XmlAttribute(name = "type", required = true)
-  protected String type;
-
-  @XmlAttribute(name = "rows", required = true)
-  protected BigInteger rows;
-
-  @XmlAttribute(name = "cols", required = true)
-  protected BigInteger cols;
-
-  @XmlAttribute(name = "treeMethod")
-  protected String treeMethod;
-
-  @XmlAttribute(name = "cutHeight")
-  protected Double cutHeight;
-
-  @XmlAttribute(name = "id")
-  protected String id;
-
-  /**
-   * Gets the value of the elements property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getElements()
-  {
-    return elements;
-  }
-
-  /**
-   * Sets the value of the elements property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setElements(String value)
-  {
-    this.elements = value;
-  }
-
-  /**
-   * Gets the value of the groups property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the groups property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getGroups().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link String }
-   * 
-   * 
-   */
-  public List<String> getGroups()
-  {
-    if (groups == null)
-    {
-      groups = new ArrayList<String>();
+@XmlType(name = "MatrixType", propOrder = {
+    "elements",
+    "groups",
+    "newick",
+    "property"
+})
+public class MatrixType {
+
+    @XmlElement(required = true)
+    protected String elements;
+    protected List<String> groups;
+    protected List<String> newick;
+    protected List<Property> property;
+    @XmlAttribute(name = "type", required = true)
+    protected String type;
+    @XmlAttribute(name = "rows", required = true)
+    protected BigInteger rows;
+    @XmlAttribute(name = "cols", required = true)
+    protected BigInteger cols;
+    @XmlAttribute(name = "treeMethod")
+    protected String treeMethod;
+    @XmlAttribute(name = "cutHeight")
+    protected Double cutHeight;
+    @XmlAttribute(name = "id", required = true)
+    protected String id;
+
+    /**
+     * Gets the value of the elements property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getElements() {
+        return elements;
     }
-    return this.groups;
-  }
 
-  /**
-   * Gets the value of the newick property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the newick property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getNewick().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link String }
-   * 
-   * 
-   */
-  public List<String> getNewick()
-  {
-    if (newick == null)
-    {
-      newick = new ArrayList<String>();
+    /**
+     * Sets the value of the elements property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setElements(String value) {
+        this.elements = value;
     }
-    return this.newick;
-  }
 
-  /**
-   * Gets the value of the property property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the property property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getProperty().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link Property }
-   * 
-   * 
-   */
-  public List<Property> getProperty()
-  {
-    if (property == null)
-    {
-      property = new ArrayList<Property>();
+    /**
+     * Gets the value of the groups property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the groups property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getGroups().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link String }
+     * 
+     * 
+     */
+    public List<String> getGroups() {
+        if (groups == null) {
+            groups = new ArrayList<String>();
+        }
+        return this.groups;
     }
-    return this.property;
-  }
 
-  /**
-   * Gets the value of the mapping property.
-   * 
-   * @return possible object is {@link MapListType }
-   * 
-   */
-  public MapListType getMapping()
-  {
-    return mapping;
-  }
+    /**
+     * Gets the value of the newick property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the newick property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getNewick().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link String }
+     * 
+     * 
+     */
+    public List<String> getNewick() {
+        if (newick == null) {
+            newick = new ArrayList<String>();
+        }
+        return this.newick;
+    }
 
-  /**
-   * Sets the value of the mapping property.
-   * 
-   * @param value
-   *          allowed object is {@link MapListType }
-   * 
-   */
-  public void setMapping(MapListType value)
-  {
-    this.mapping = value;
-  }
+    /**
+     * Gets the value of the property property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the property property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getProperty().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Property }
+     * 
+     * 
+     */
+    public List<Property> getProperty() {
+        if (property == null) {
+            property = new ArrayList<Property>();
+        }
+        return this.property;
+    }
 
-  /**
-   * Gets the value of the type property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getType()
-  {
-    return type;
-  }
+    /**
+     * Gets the value of the type property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getType() {
+        return type;
+    }
 
-  /**
-   * Sets the value of the type property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setType(String value)
-  {
-    this.type = value;
-  }
+    /**
+     * Sets the value of the type property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setType(String value) {
+        this.type = value;
+    }
 
-  /**
-   * Gets the value of the rows property.
-   * 
-   * @return possible object is {@link BigInteger }
-   * 
-   */
-  public BigInteger getRows()
-  {
-    return rows;
-  }
+    /**
+     * Gets the value of the rows property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link BigInteger }
+     *     
+     */
+    public BigInteger getRows() {
+        return rows;
+    }
 
-  /**
-   * Sets the value of the rows property.
-   * 
-   * @param value
-   *          allowed object is {@link BigInteger }
-   * 
-   */
-  public void setRows(BigInteger value)
-  {
-    this.rows = value;
-  }
+    /**
+     * Sets the value of the rows property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link BigInteger }
+     *     
+     */
+    public void setRows(BigInteger value) {
+        this.rows = value;
+    }
 
-  /**
-   * Gets the value of the cols property.
-   * 
-   * @return possible object is {@link BigInteger }
-   * 
-   */
-  public BigInteger getCols()
-  {
-    return cols;
-  }
+    /**
+     * Gets the value of the cols property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link BigInteger }
+     *     
+     */
+    public BigInteger getCols() {
+        return cols;
+    }
 
-  /**
-   * Sets the value of the cols property.
-   * 
-   * @param value
-   *          allowed object is {@link BigInteger }
-   * 
-   */
-  public void setCols(BigInteger value)
-  {
-    this.cols = value;
-  }
+    /**
+     * Sets the value of the cols property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link BigInteger }
+     *     
+     */
+    public void setCols(BigInteger value) {
+        this.cols = value;
+    }
 
-  /**
-   * Gets the value of the treeMethod property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getTreeMethod()
-  {
-    return treeMethod;
-  }
+    /**
+     * Gets the value of the treeMethod property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getTreeMethod() {
+        return treeMethod;
+    }
 
-  /**
-   * Sets the value of the treeMethod property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setTreeMethod(String value)
-  {
-    this.treeMethod = value;
-  }
+    /**
+     * Sets the value of the treeMethod property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setTreeMethod(String value) {
+        this.treeMethod = value;
+    }
 
-  /**
-   * Gets the value of the cutHeight property.
-   * 
-   * @return possible object is {@link Double }
-   * 
-   */
-  public Double getCutHeight()
-  {
-    return cutHeight;
-  }
+    /**
+     * Gets the value of the cutHeight property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link Double }
+     *     
+     */
+    public Double getCutHeight() {
+        return cutHeight;
+    }
 
-  /**
-   * Sets the value of the cutHeight property.
-   * 
-   * @param value
-   *          allowed object is {@link Double }
-   * 
-   */
-  public void setCutHeight(Double value)
-  {
-    this.cutHeight = value;
-  }
+    /**
+     * Sets the value of the cutHeight property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link Double }
+     *     
+     */
+    public void setCutHeight(Double value) {
+        this.cutHeight = value;
+    }
 
-  /**
-   * Gets the value of the id property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getId()
-  {
-    return id;
-  }
+    /**
+     * Gets the value of the id property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getId() {
+        return id;
+    }
 
-  /**
-   * Sets the value of the id property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setId(String value)
-  {
-    this.id = value;
-  }
+    /**
+     * Sets the value of the id property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setId(String value) {
+        this.id = value;
+    }
 
 }
index eeeed22..8d22ad8 100644 (file)
@@ -1,68 +1,60 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlEnum;
 import javax.xml.bind.annotation.XmlEnumValue;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for NoValueColour.
+ * &lt;p&gt;Java class for NoValueColour.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p>
- * 
- * <pre>
- * &lt;simpleType name="NoValueColour">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
- *     &lt;enumeration value="None"/>
- *     &lt;enumeration value="Min"/>
- *     &lt;enumeration value="Max"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+ * &lt;pre&gt;
+ * &amp;lt;simpleType name="NoValueColour"&amp;gt;
+ *   &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}string"&amp;gt;
+ *     &amp;lt;enumeration value="None"/&amp;gt;
+ *     &amp;lt;enumeration value="Min"/&amp;gt;
+ *     &amp;lt;enumeration value="Max"/&amp;gt;
+ *   &amp;lt;/restriction&amp;gt;
+ * &amp;lt;/simpleType&amp;gt;
+ * &lt;/pre&gt;
  * 
  */
 @XmlType(name = "NoValueColour", namespace = "www.jalview.org/colours")
 @XmlEnum
-public enum NoValueColour
-{
-
-  @XmlEnumValue("None")
-  NONE("None"), @XmlEnumValue("Min")
-  MIN("Min"), @XmlEnumValue("Max")
-  MAX("Max");
-
-  private final String value;
-
-  NoValueColour(String v)
-  {
-    value = v;
-  }
+public enum NoValueColour {
+
+    @XmlEnumValue("None")
+    NONE("None"),
+    @XmlEnumValue("Min")
+    MIN("Min"),
+    @XmlEnumValue("Max")
+    MAX("Max");
+    private final String value;
+
+    NoValueColour(String v) {
+        value = v;
+    }
 
-  public String value()
-  {
-    return value;
-  }
+    public String value() {
+        return value;
+    }
 
-  public static NoValueColour fromValue(String v)
-  {
-    for (NoValueColour c : NoValueColour.values())
-    {
-      if (c.value.equals(v))
-      {
-        return c;
-      }
+    public static NoValueColour fromValue(String v) {
+        for (NoValueColour c: NoValueColour.values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v);
     }
-    throw new IllegalArgumentException(v);
-  }
 
 }
index 993adae..90ce3fa 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.JAXBElement;
@@ -12,567 +13,512 @@ import javax.xml.bind.annotation.XmlElementDecl;
 import javax.xml.bind.annotation.XmlRegistry;
 import javax.xml.namespace.QName;
 
+
 /**
- * This object contains factory methods for each Java content interface and Java
- * element interface generated in the jalview.xml.binding.jalview package.
- * <p>
- * An ObjectFactory allows you to programatically construct new instances of the
- * Java representation for XML content. The Java representation of XML content
- * can consist of schema derived interfaces and classes representing the binding
- * of schema type definitions, element declarations and model groups. Factory
- * methods for each of these are provided in this class.
+ * This object contains factory methods for each 
+ * Java content interface and Java element interface 
+ * generated in the jalview.xml.binding.jalview package. 
+ * &lt;p&gt;An ObjectFactory allows you to programatically 
+ * construct new instances of the Java representation 
+ * for XML content. The Java representation of XML 
+ * content can consist of schema derived interfaces 
+ * and classes representing the binding of schema 
+ * type definitions, element declarations and model 
+ * groups.  Factory methods for each of these are 
+ * provided in this class.
  * 
  */
 @XmlRegistry
-public class ObjectFactory
-{
-
-  private final static QName _WebServiceParameterSet_QNAME = new QName(
-          "www.jalview.org/xml/wsparamset", "WebServiceParameterSet");
-
-  private final static QName _JalviewModel_QNAME = new QName(
-          "www.jalview.org", "JalviewModel");
-
-  private final static QName _JalviewUserColours_QNAME = new QName(
-          "www.jalview.org/colours", "JalviewUserColours");
-
-  /**
-   * Create a new ObjectFactory that can be used to create new instances of
-   * schema derived classes for package: jalview.xml.binding.jalview
-   * 
-   */
-  public ObjectFactory()
-  {
-  }
-
-  /**
-   * Create an instance of {@link AlcodonFrame }
-   * 
-   */
-  public AlcodonFrame createAlcodonFrame()
-  {
-    return new AlcodonFrame();
-  }
-
-  /**
-   * Create an instance of {@link MapListType }
-   * 
-   */
-  public MapListType createMapListType()
-  {
-    return new MapListType();
-  }
-
-  /**
-   * Create an instance of {@link Sequence }
-   * 
-   */
-  public Sequence createSequence()
-  {
-    return new Sequence();
-  }
-
-  /**
-   * Create an instance of {@link Annotation }
-   * 
-   */
-  public Annotation createAnnotation()
-  {
-    return new Annotation();
-  }
-
-  /**
-   * Create an instance of {@link SequenceSet }
-   * 
-   */
-  public SequenceSet createSequenceSet()
-  {
-    return new SequenceSet();
-  }
-
-  /**
-   * Create an instance of {@link FeatureMatcherSet }
-   * 
-   */
-  public FeatureMatcherSet createFeatureMatcherSet()
-  {
-    return new FeatureMatcherSet();
-  }
-
-  /**
-   * Create an instance of {@link JalviewUserColours }
-   * 
-   */
-  public JalviewUserColours createJalviewUserColours()
-  {
-    return new JalviewUserColours();
-  }
-
-  /**
-   * Create an instance of {@link Pdbentry }
-   * 
-   */
-  public Pdbentry createPdbentry()
-  {
-    return new Pdbentry();
-  }
-
-  /**
-   * Create an instance of {@link Feature }
-   * 
-   */
-  public Feature createFeature()
-  {
-    return new Feature();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel }
-   * 
-   */
-  public JalviewModel createJalviewModel()
-  {
-    return new JalviewModel();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.FeatureSettings }
-   * 
-   */
-  public JalviewModel.FeatureSettings createJalviewModelFeatureSettings()
-  {
-    return new JalviewModel.FeatureSettings();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.PcaViewer }
-   * 
-   */
-  public JalviewModel.PcaViewer createJalviewModelPcaViewer()
-  {
-    return new JalviewModel.PcaViewer();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.Viewport }
-   * 
-   */
-  public JalviewModel.Viewport createJalviewModelViewport()
-  {
-    return new JalviewModel.Viewport();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.JSeq }
-   * 
-   */
-  public JalviewModel.JSeq createJalviewModelJSeq()
-  {
-    return new JalviewModel.JSeq();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.JSeq.RnaViewer }
-   * 
-   */
-  public JalviewModel.JSeq.RnaViewer createJalviewModelJSeqRnaViewer()
-  {
-    return new JalviewModel.JSeq.RnaViewer();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.JSeq.Pdbids }
-   * 
-   */
-  public JalviewModel.JSeq.Pdbids createJalviewModelJSeqPdbids()
-  {
-    return new JalviewModel.JSeq.Pdbids();
-  }
-
-  /**
-   * Create an instance of {@link DoubleMatrix }
-   * 
-   */
-  public DoubleMatrix createDoubleMatrix()
-  {
-    return new DoubleMatrix();
-  }
-
-  /**
-   * Create an instance of {@link AnnotationColourScheme }
-   * 
-   */
-  public AnnotationColourScheme createAnnotationColourScheme()
-  {
-    return new AnnotationColourScheme();
-  }
-
-  /**
-   * Create an instance of {@link PcaDataType }
-   * 
-   */
-  public PcaDataType createPcaDataType()
-  {
-    return new PcaDataType();
-  }
-
-  /**
-   * Create an instance of {@link DoubleVector }
-   * 
-   */
-  public DoubleVector createDoubleVector()
-  {
-    return new DoubleVector();
-  }
-
-  /**
-   * Create an instance of {@link AlcodonFrame.Alcodon }
-   * 
-   */
-  public AlcodonFrame.Alcodon createAlcodonFrameAlcodon()
-  {
-    return new AlcodonFrame.Alcodon();
-  }
-
-  /**
-   * Create an instance of {@link AlcodonFrame.AlcodMap }
-   * 
-   */
-  public AlcodonFrame.AlcodMap createAlcodonFrameAlcodMap()
-  {
-    return new AlcodonFrame.AlcodMap();
-  }
-
-  /**
-   * Create an instance of {@link AnnotationElement }
-   * 
-   */
-  public AnnotationElement createAnnotationElement()
-  {
-    return new AnnotationElement();
-  }
-
-  /**
-   * Create an instance of {@link Mapping }
-   * 
-   */
-  public Mapping createMapping()
-  {
-    return new Mapping();
-  }
-
-  /**
-   * Create an instance of {@link MapListType.MapListFrom }
-   * 
-   */
-  public MapListType.MapListFrom createMapListTypeMapListFrom()
-  {
-    return new MapListType.MapListFrom();
-  }
-
-  /**
-   * Create an instance of {@link MapListType.MapListTo }
-   * 
-   */
-  public MapListType.MapListTo createMapListTypeMapListTo()
-  {
-    return new MapListType.MapListTo();
-  }
-
-  /**
-   * Create an instance of {@link SequenceType }
-   * 
-   */
-  public SequenceType createSequenceType()
-  {
-    return new SequenceType();
-  }
-
-  /**
-   * Create an instance of {@link Sequence.DBRef }
-   * 
-   */
-  public Sequence.DBRef createSequenceDBRef()
-  {
-    return new Sequence.DBRef();
-  }
-
-  /**
-   * Create an instance of {@link Annotation.ThresholdLine }
-   * 
-   */
-  public Annotation.ThresholdLine createAnnotationThresholdLine()
-  {
-    return new Annotation.ThresholdLine();
-  }
-
-  /**
-   * Create an instance of {@link MatrixType }
-   * 
-   */
-  public MatrixType createMatrixType()
-  {
-    return new MatrixType();
-  }
-
-  /**
-   * Create an instance of {@link jalview.xml.binding.jalview.Property }
-   * 
-   */
-  public jalview.xml.binding.jalview.Property createProperty()
-  {
-    return new jalview.xml.binding.jalview.Property();
-  }
-
-  /**
-   * Create an instance of {@link SequenceSet.SequenceSetProperties }
-   * 
-   */
-  public SequenceSet.SequenceSetProperties createSequenceSetSequenceSetProperties()
-  {
-    return new SequenceSet.SequenceSetProperties();
-  }
-
-  /**
-   * Create an instance of {@link VAMSAS }
-   * 
-   */
-  public VAMSAS createVAMSAS()
-  {
-    return new VAMSAS();
-  }
-
-  /**
-   * Create an instance of {@link FeatureMatcher }
-   * 
-   */
-  public FeatureMatcher createFeatureMatcher()
-  {
-    return new FeatureMatcher();
-  }
-
-  /**
-   * Create an instance of {@link WebServiceParameterSet }
-   * 
-   */
-  public WebServiceParameterSet createWebServiceParameterSet()
-  {
-    return new WebServiceParameterSet();
-  }
-
-  /**
-   * Create an instance of {@link FeatureMatcherSet.CompoundMatcher }
-   * 
-   */
-  public FeatureMatcherSet.CompoundMatcher createFeatureMatcherSetCompoundMatcher()
-  {
-    return new FeatureMatcherSet.CompoundMatcher();
-  }
-
-  /**
-   * Create an instance of {@link JalviewUserColours.Colour }
-   * 
-   */
-  public JalviewUserColours.Colour createJalviewUserColoursColour()
-  {
-    return new JalviewUserColours.Colour();
-  }
-
-  /**
-   * Create an instance of {@link JalviewUserColours.Filter }
-   * 
-   */
-  public JalviewUserColours.Filter createJalviewUserColoursFilter()
-  {
-    return new JalviewUserColours.Filter();
-  }
-
-  /**
-   * Create an instance of {@link Pdbentry.Property }
-   * 
-   */
-  public Pdbentry.Property createPdbentryProperty()
-  {
-    return new Pdbentry.Property();
-  }
-
-  /**
-   * Create an instance of {@link Feature.OtherData }
-   * 
-   */
-  public Feature.OtherData createFeatureOtherData()
-  {
-    return new Feature.OtherData();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.JGroup }
-   * 
-   */
-  public JalviewModel.JGroup createJalviewModelJGroup()
-  {
-    return new JalviewModel.JGroup();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.UserColours }
-   * 
-   */
-  public JalviewModel.UserColours createJalviewModelUserColours()
-  {
-    return new JalviewModel.UserColours();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.Tree }
-   * 
-   */
-  public JalviewModel.Tree createJalviewModelTree()
-  {
-    return new JalviewModel.Tree();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.FeatureSettings.Setting }
-   * 
-   */
-  public JalviewModel.FeatureSettings.Setting createJalviewModelFeatureSettingsSetting()
-  {
-    return new JalviewModel.FeatureSettings.Setting();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.FeatureSettings.Group }
-   * 
-   */
-  public JalviewModel.FeatureSettings.Group createJalviewModelFeatureSettingsGroup()
-  {
-    return new JalviewModel.FeatureSettings.Group();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.PcaViewer.SequencePoint }
-   * 
-   */
-  public JalviewModel.PcaViewer.SequencePoint createJalviewModelPcaViewerSequencePoint()
-  {
-    return new JalviewModel.PcaViewer.SequencePoint();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.PcaViewer.Axis }
-   * 
-   */
-  public JalviewModel.PcaViewer.Axis createJalviewModelPcaViewerAxis()
-  {
-    return new JalviewModel.PcaViewer.Axis();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.PcaViewer.SeqPointMin }
-   * 
-   */
-  public JalviewModel.PcaViewer.SeqPointMin createJalviewModelPcaViewerSeqPointMin()
-  {
-    return new JalviewModel.PcaViewer.SeqPointMin();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.PcaViewer.SeqPointMax }
-   * 
-   */
-  public JalviewModel.PcaViewer.SeqPointMax createJalviewModelPcaViewerSeqPointMax()
-  {
-    return new JalviewModel.PcaViewer.SeqPointMax();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.Viewport.HiddenColumns }
-   * 
-   */
-  public JalviewModel.Viewport.HiddenColumns createJalviewModelViewportHiddenColumns()
-  {
-    return new JalviewModel.Viewport.HiddenColumns();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.Viewport.CalcIdParam }
-   * 
-   */
-  public JalviewModel.Viewport.CalcIdParam createJalviewModelViewportCalcIdParam()
-  {
-    return new JalviewModel.Viewport.CalcIdParam();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.Viewport.Overview }
-   * 
-   */
-  public JalviewModel.Viewport.Overview createJalviewModelViewportOverview()
-  {
-    return new JalviewModel.Viewport.Overview();
-  }
-
-  /**
-   * Create an instance of
-   * {@link JalviewModel.JSeq.RnaViewer.SecondaryStructure }
-   * 
-   */
-  public JalviewModel.JSeq.RnaViewer.SecondaryStructure createJalviewModelJSeqRnaViewerSecondaryStructure()
-  {
-    return new JalviewModel.JSeq.RnaViewer.SecondaryStructure();
-  }
-
-  /**
-   * Create an instance of {@link JalviewModel.JSeq.Pdbids.StructureState }
-   * 
-   */
-  public JalviewModel.JSeq.Pdbids.StructureState createJalviewModelJSeqPdbidsStructureState()
-  {
-    return new JalviewModel.JSeq.Pdbids.StructureState();
-  }
-
-  /**
-   * Create an instance of {@link JAXBElement
-   * }{@code <}{@link WebServiceParameterSet }{@code >}}
-   * 
-   */
-  @XmlElementDecl(
-    namespace = "www.jalview.org/xml/wsparamset",
-    name = "WebServiceParameterSet")
-  public JAXBElement<WebServiceParameterSet> createWebServiceParameterSet(
-          WebServiceParameterSet value)
-  {
-    return new JAXBElement<WebServiceParameterSet>(
-            _WebServiceParameterSet_QNAME, WebServiceParameterSet.class,
-            null, value);
-  }
-
-  /**
-   * Create an instance of {@link JAXBElement }{@code <}{@link JalviewModel
-   * }{@code >}}
-   * 
-   */
-  @XmlElementDecl(namespace = "www.jalview.org", name = "JalviewModel")
-  public JAXBElement<JalviewModel> createJalviewModel(JalviewModel value)
-  {
-    return new JAXBElement<JalviewModel>(_JalviewModel_QNAME,
-            JalviewModel.class, null, value);
-  }
-
-  /**
-   * Create an instance of {@link JAXBElement
-   * }{@code <}{@link JalviewUserColours }{@code >}}
-   * 
-   */
-  @XmlElementDecl(
-    namespace = "www.jalview.org/colours",
-    name = "JalviewUserColours")
-  public JAXBElement<JalviewUserColours> createJalviewUserColours(
-          JalviewUserColours value)
-  {
-    return new JAXBElement<JalviewUserColours>(_JalviewUserColours_QNAME,
-            JalviewUserColours.class, null, value);
-  }
+public class ObjectFactory {
+
+    private final static QName _JalviewModel_QNAME = new QName("www.jalview.org", "JalviewModel");
+    private final static QName _JalviewUserColours_QNAME = new QName("www.jalview.org/colours", "JalviewUserColours");
+    private final static QName _WebServiceParameterSet_QNAME = new QName("www.jalview.org/xml/wsparamset", "WebServiceParameterSet");
+
+    /**
+     * Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: jalview.xml.binding.jalview
+     * 
+     */
+    public ObjectFactory() {
+    }
+
+    /**
+     * Create an instance of {@link MapListType }
+     * 
+     */
+    public MapListType createMapListType() {
+        return new MapListType();
+    }
+
+    /**
+     * Create an instance of {@link Sequence }
+     * 
+     */
+    public Sequence createSequence() {
+        return new Sequence();
+    }
+
+    /**
+     * Create an instance of {@link AlcodonFrame }
+     * 
+     */
+    public AlcodonFrame createAlcodonFrame() {
+        return new AlcodonFrame();
+    }
+
+    /**
+     * Create an instance of {@link Annotation }
+     * 
+     */
+    public Annotation createAnnotation() {
+        return new Annotation();
+    }
+
+    /**
+     * Create an instance of {@link SequenceSet }
+     * 
+     */
+    public SequenceSet createSequenceSet() {
+        return new SequenceSet();
+    }
+
+    /**
+     * Create an instance of {@link FeatureMatcherSet }
+     * 
+     */
+    public FeatureMatcherSet createFeatureMatcherSet() {
+        return new FeatureMatcherSet();
+    }
+
+    /**
+     * Create an instance of {@link JalviewUserColours }
+     * 
+     */
+    public JalviewUserColours createJalviewUserColours() {
+        return new JalviewUserColours();
+    }
+
+    /**
+     * Create an instance of {@link Pdbentry }
+     * 
+     */
+    public Pdbentry createPdbentry() {
+        return new Pdbentry();
+    }
+
+    /**
+     * Create an instance of {@link Feature }
+     * 
+     */
+    public Feature createFeature() {
+        return new Feature();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel }
+     * 
+     */
+    public JalviewModel createJalviewModel() {
+        return new JalviewModel();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.FeatureSettings }
+     * 
+     */
+    public JalviewModel.FeatureSettings createJalviewModelFeatureSettings() {
+        return new JalviewModel.FeatureSettings();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.PcaViewer }
+     * 
+     */
+    public JalviewModel.PcaViewer createJalviewModelPcaViewer() {
+        return new JalviewModel.PcaViewer();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.Viewport }
+     * 
+     */
+    public JalviewModel.Viewport createJalviewModelViewport() {
+        return new JalviewModel.Viewport();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.JSeq }
+     * 
+     */
+    public JalviewModel.JSeq createJalviewModelJSeq() {
+        return new JalviewModel.JSeq();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.JSeq.RnaViewer }
+     * 
+     */
+    public JalviewModel.JSeq.RnaViewer createJalviewModelJSeqRnaViewer() {
+        return new JalviewModel.JSeq.RnaViewer();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.JSeq.Pdbids }
+     * 
+     */
+    public JalviewModel.JSeq.Pdbids createJalviewModelJSeqPdbids() {
+        return new JalviewModel.JSeq.Pdbids();
+    }
+
+    /**
+     * Create an instance of {@link AnnotationColourScheme }
+     * 
+     */
+    public AnnotationColourScheme createAnnotationColourScheme() {
+        return new AnnotationColourScheme();
+    }
+
+    /**
+     * Create an instance of {@link PcaDataType }
+     * 
+     */
+    public PcaDataType createPcaDataType() {
+        return new PcaDataType();
+    }
+
+    /**
+     * Create an instance of {@link DoubleVector }
+     * 
+     */
+    public DoubleVector createDoubleVector() {
+        return new DoubleVector();
+    }
+
+    /**
+     * Create an instance of {@link DoubleMatrix }
+     * 
+     */
+    public DoubleMatrix createDoubleMatrix() {
+        return new DoubleMatrix();
+    }
+
+    /**
+     * Create an instance of {@link Mapping }
+     * 
+     */
+    public Mapping createMapping() {
+        return new Mapping();
+    }
+
+    /**
+     * Create an instance of {@link MapListType.MapListFrom }
+     * 
+     */
+    public MapListType.MapListFrom createMapListTypeMapListFrom() {
+        return new MapListType.MapListFrom();
+    }
+
+    /**
+     * Create an instance of {@link MapListType.MapListTo }
+     * 
+     */
+    public MapListType.MapListTo createMapListTypeMapListTo() {
+        return new MapListType.MapListTo();
+    }
+
+    /**
+     * Create an instance of {@link SequenceType }
+     * 
+     */
+    public SequenceType createSequenceType() {
+        return new SequenceType();
+    }
+
+    /**
+     * Create an instance of {@link Sequence.DBRef }
+     * 
+     */
+    public Sequence.DBRef createSequenceDBRef() {
+        return new Sequence.DBRef();
+    }
+
+    /**
+     * Create an instance of {@link AlcodonFrame.Alcodon }
+     * 
+     */
+    public AlcodonFrame.Alcodon createAlcodonFrameAlcodon() {
+        return new AlcodonFrame.Alcodon();
+    }
+
+    /**
+     * Create an instance of {@link AlcodonFrame.AlcodMap }
+     * 
+     */
+    public AlcodonFrame.AlcodMap createAlcodonFrameAlcodMap() {
+        return new AlcodonFrame.AlcodMap();
+    }
+
+    /**
+     * Create an instance of {@link AnnotationElement }
+     * 
+     */
+    public AnnotationElement createAnnotationElement() {
+        return new AnnotationElement();
+    }
+
+    /**
+     * Create an instance of {@link Annotation.ThresholdLine }
+     * 
+     */
+    public Annotation.ThresholdLine createAnnotationThresholdLine() {
+        return new Annotation.ThresholdLine();
+    }
+
+    /**
+     * Create an instance of {@link MapOnAMatrixType }
+     * 
+     */
+    public MapOnAMatrixType createMapOnAMatrixType() {
+        return new MapOnAMatrixType();
+    }
+
+    /**
+     * Create an instance of {@link jalview.xml.binding.jalview.Property }
+     * 
+     */
+    public jalview.xml.binding.jalview.Property createProperty() {
+        return new jalview.xml.binding.jalview.Property();
+    }
+
+    /**
+     * Create an instance of {@link SequenceSet.SequenceSetProperties }
+     * 
+     */
+    public SequenceSet.SequenceSetProperties createSequenceSetSequenceSetProperties() {
+        return new SequenceSet.SequenceSetProperties();
+    }
+
+    /**
+     * Create an instance of {@link MatrixType }
+     * 
+     */
+    public MatrixType createMatrixType() {
+        return new MatrixType();
+    }
+
+    /**
+     * Create an instance of {@link VAMSAS }
+     * 
+     */
+    public VAMSAS createVAMSAS() {
+        return new VAMSAS();
+    }
+
+    /**
+     * Create an instance of {@link FeatureMatcher }
+     * 
+     */
+    public FeatureMatcher createFeatureMatcher() {
+        return new FeatureMatcher();
+    }
+
+    /**
+     * Create an instance of {@link WebServiceParameterSet }
+     * 
+     */
+    public WebServiceParameterSet createWebServiceParameterSet() {
+        return new WebServiceParameterSet();
+    }
+
+    /**
+     * Create an instance of {@link FeatureMatcherSet.CompoundMatcher }
+     * 
+     */
+    public FeatureMatcherSet.CompoundMatcher createFeatureMatcherSetCompoundMatcher() {
+        return new FeatureMatcherSet.CompoundMatcher();
+    }
+
+    /**
+     * Create an instance of {@link JalviewUserColours.Colour }
+     * 
+     */
+    public JalviewUserColours.Colour createJalviewUserColoursColour() {
+        return new JalviewUserColours.Colour();
+    }
+
+    /**
+     * Create an instance of {@link JalviewUserColours.Filter }
+     * 
+     */
+    public JalviewUserColours.Filter createJalviewUserColoursFilter() {
+        return new JalviewUserColours.Filter();
+    }
+
+    /**
+     * Create an instance of {@link Pdbentry.Property }
+     * 
+     */
+    public Pdbentry.Property createPdbentryProperty() {
+        return new Pdbentry.Property();
+    }
+
+    /**
+     * Create an instance of {@link Feature.OtherData }
+     * 
+     */
+    public Feature.OtherData createFeatureOtherData() {
+        return new Feature.OtherData();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.JGroup }
+     * 
+     */
+    public JalviewModel.JGroup createJalviewModelJGroup() {
+        return new JalviewModel.JGroup();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.UserColours }
+     * 
+     */
+    public JalviewModel.UserColours createJalviewModelUserColours() {
+        return new JalviewModel.UserColours();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.Tree }
+     * 
+     */
+    public JalviewModel.Tree createJalviewModelTree() {
+        return new JalviewModel.Tree();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.FeatureSettings.Setting }
+     * 
+     */
+    public JalviewModel.FeatureSettings.Setting createJalviewModelFeatureSettingsSetting() {
+        return new JalviewModel.FeatureSettings.Setting();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.FeatureSettings.Group }
+     * 
+     */
+    public JalviewModel.FeatureSettings.Group createJalviewModelFeatureSettingsGroup() {
+        return new JalviewModel.FeatureSettings.Group();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.PcaViewer.SequencePoint }
+     * 
+     */
+    public JalviewModel.PcaViewer.SequencePoint createJalviewModelPcaViewerSequencePoint() {
+        return new JalviewModel.PcaViewer.SequencePoint();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.PcaViewer.Axis }
+     * 
+     */
+    public JalviewModel.PcaViewer.Axis createJalviewModelPcaViewerAxis() {
+        return new JalviewModel.PcaViewer.Axis();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.PcaViewer.SeqPointMin }
+     * 
+     */
+    public JalviewModel.PcaViewer.SeqPointMin createJalviewModelPcaViewerSeqPointMin() {
+        return new JalviewModel.PcaViewer.SeqPointMin();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.PcaViewer.SeqPointMax }
+     * 
+     */
+    public JalviewModel.PcaViewer.SeqPointMax createJalviewModelPcaViewerSeqPointMax() {
+        return new JalviewModel.PcaViewer.SeqPointMax();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.Viewport.HiddenColumns }
+     * 
+     */
+    public JalviewModel.Viewport.HiddenColumns createJalviewModelViewportHiddenColumns() {
+        return new JalviewModel.Viewport.HiddenColumns();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.Viewport.CalcIdParam }
+     * 
+     */
+    public JalviewModel.Viewport.CalcIdParam createJalviewModelViewportCalcIdParam() {
+        return new JalviewModel.Viewport.CalcIdParam();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.Viewport.Overview }
+     * 
+     */
+    public JalviewModel.Viewport.Overview createJalviewModelViewportOverview() {
+        return new JalviewModel.Viewport.Overview();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.JSeq.RnaViewer.SecondaryStructure }
+     * 
+     */
+    public JalviewModel.JSeq.RnaViewer.SecondaryStructure createJalviewModelJSeqRnaViewerSecondaryStructure() {
+        return new JalviewModel.JSeq.RnaViewer.SecondaryStructure();
+    }
+
+    /**
+     * Create an instance of {@link JalviewModel.JSeq.Pdbids.StructureState }
+     * 
+     */
+    public JalviewModel.JSeq.Pdbids.StructureState createJalviewModelJSeqPdbidsStructureState() {
+        return new JalviewModel.JSeq.Pdbids.StructureState();
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link JalviewModel }{@code >}
+     * 
+     * @param value
+     *     Java instance representing xml element's value.
+     * @return
+     *     the new instance of {@link JAXBElement }{@code <}{@link JalviewModel }{@code >}
+     */
+    @XmlElementDecl(namespace = "www.jalview.org", name = "JalviewModel")
+    public JAXBElement<JalviewModel> createJalviewModel(JalviewModel value) {
+        return new JAXBElement<JalviewModel>(_JalviewModel_QNAME, JalviewModel.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link JalviewUserColours }{@code >}
+     * 
+     * @param value
+     *     Java instance representing xml element's value.
+     * @return
+     *     the new instance of {@link JAXBElement }{@code <}{@link JalviewUserColours }{@code >}
+     */
+    @XmlElementDecl(namespace = "www.jalview.org/colours", name = "JalviewUserColours")
+    public JAXBElement<JalviewUserColours> createJalviewUserColours(JalviewUserColours value) {
+        return new JAXBElement<JalviewUserColours>(_JalviewUserColours_QNAME, JalviewUserColours.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link WebServiceParameterSet }{@code >}
+     * 
+     * @param value
+     *     Java instance representing xml element's value.
+     * @return
+     *     the new instance of {@link JAXBElement }{@code <}{@link WebServiceParameterSet }{@code >}
+     */
+    @XmlElementDecl(namespace = "www.jalview.org/xml/wsparamset", name = "WebServiceParameterSet")
+    public JAXBElement<WebServiceParameterSet> createWebServiceParameterSet(WebServiceParameterSet value) {
+        return new JAXBElement<WebServiceParameterSet>(_WebServiceParameterSet_QNAME, WebServiceParameterSet.class, null, value);
+    }
 
 }
index 2ff7a55..aa418e5 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlAccessType;
@@ -12,119 +13,117 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
  * 
- * The results of a PCA calculation
- * 
+ *                             The results of a PCA calculation
+ *                     
  * 
- * <p>
- * Java class for PcaDataType complex type.
+ * &lt;p&gt;Java class for PcaDataType complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="PcaDataType">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="pairwiseMatrix" type="{www.jalview.org}DoubleMatrix"/>
- *         &lt;element name="tridiagonalMatrix" type="{www.jalview.org}DoubleMatrix"/>
- *         &lt;element name="eigenMatrix" type="{www.jalview.org}DoubleMatrix"/>
- *       &lt;/sequence>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="PcaDataType"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="pairwiseMatrix" type="{www.jalview.org}DoubleMatrix"/&amp;gt;
+ *         &amp;lt;element name="tridiagonalMatrix" type="{www.jalview.org}DoubleMatrix"/&amp;gt;
+ *         &amp;lt;element name="eigenMatrix" type="{www.jalview.org}DoubleMatrix"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "PcaDataType",
-  namespace = "www.jalview.org",
-  propOrder =
-  { "pairwiseMatrix", "tridiagonalMatrix", "eigenMatrix" })
-public class PcaDataType
-{
-
-  @XmlElement(required = true)
-  protected DoubleMatrix pairwiseMatrix;
-
-  @XmlElement(required = true)
-  protected DoubleMatrix tridiagonalMatrix;
+@XmlType(name = "PcaDataType", namespace = "www.jalview.org", propOrder = {
+    "pairwiseMatrix",
+    "tridiagonalMatrix",
+    "eigenMatrix"
+})
+public class PcaDataType {
 
-  @XmlElement(required = true)
-  protected DoubleMatrix eigenMatrix;
+    @XmlElement(required = true)
+    protected DoubleMatrix pairwiseMatrix;
+    @XmlElement(required = true)
+    protected DoubleMatrix tridiagonalMatrix;
+    @XmlElement(required = true)
+    protected DoubleMatrix eigenMatrix;
 
-  /**
-   * Gets the value of the pairwiseMatrix property.
-   * 
-   * @return possible object is {@link DoubleMatrix }
-   * 
-   */
-  public DoubleMatrix getPairwiseMatrix()
-  {
-    return pairwiseMatrix;
-  }
+    /**
+     * Gets the value of the pairwiseMatrix property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link DoubleMatrix }
+     *     
+     */
+    public DoubleMatrix getPairwiseMatrix() {
+        return pairwiseMatrix;
+    }
 
-  /**
-   * Sets the value of the pairwiseMatrix property.
-   * 
-   * @param value
-   *          allowed object is {@link DoubleMatrix }
-   * 
-   */
-  public void setPairwiseMatrix(DoubleMatrix value)
-  {
-    this.pairwiseMatrix = value;
-  }
+    /**
+     * Sets the value of the pairwiseMatrix property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link DoubleMatrix }
+     *     
+     */
+    public void setPairwiseMatrix(DoubleMatrix value) {
+        this.pairwiseMatrix = value;
+    }
 
-  /**
-   * Gets the value of the tridiagonalMatrix property.
-   * 
-   * @return possible object is {@link DoubleMatrix }
-   * 
-   */
-  public DoubleMatrix getTridiagonalMatrix()
-  {
-    return tridiagonalMatrix;
-  }
+    /**
+     * Gets the value of the tridiagonalMatrix property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link DoubleMatrix }
+     *     
+     */
+    public DoubleMatrix getTridiagonalMatrix() {
+        return tridiagonalMatrix;
+    }
 
-  /**
-   * Sets the value of the tridiagonalMatrix property.
-   * 
-   * @param value
-   *          allowed object is {@link DoubleMatrix }
-   * 
-   */
-  public void setTridiagonalMatrix(DoubleMatrix value)
-  {
-    this.tridiagonalMatrix = value;
-  }
+    /**
+     * Sets the value of the tridiagonalMatrix property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link DoubleMatrix }
+     *     
+     */
+    public void setTridiagonalMatrix(DoubleMatrix value) {
+        this.tridiagonalMatrix = value;
+    }
 
-  /**
-   * Gets the value of the eigenMatrix property.
-   * 
-   * @return possible object is {@link DoubleMatrix }
-   * 
-   */
-  public DoubleMatrix getEigenMatrix()
-  {
-    return eigenMatrix;
-  }
+    /**
+     * Gets the value of the eigenMatrix property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link DoubleMatrix }
+     *     
+     */
+    public DoubleMatrix getEigenMatrix() {
+        return eigenMatrix;
+    }
 
-  /**
-   * Sets the value of the eigenMatrix property.
-   * 
-   * @param value
-   *          allowed object is {@link DoubleMatrix }
-   * 
-   */
-  public void setEigenMatrix(DoubleMatrix value)
-  {
-    this.eigenMatrix = value;
-  }
+    /**
+     * Sets the value of the eigenMatrix property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link DoubleMatrix }
+     *     
+     */
+    public void setEigenMatrix(DoubleMatrix value) {
+        this.eigenMatrix = value;
+    }
 
 }
index f0fd2f3..144076b 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -15,240 +16,232 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlSeeAlso;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for pdbentry complex type.
+ * &lt;p&gt;Java class for pdbentry complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="pdbentry">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence maxOccurs="unbounded" minOccurs="0">
- *         &lt;element name="property" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/sequence>
- *       &lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="file" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="pdbentry"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *         &amp;lt;element name="property" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="file" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "pdbentry",
-  namespace = "www.jalview.org",
-  propOrder =
-  { "property" })
-@XmlSeeAlso({ jalview.xml.binding.jalview.JalviewModel.JSeq.Pdbids.class })
-public class Pdbentry
-{
-
-  protected List<Pdbentry.Property> property;
-
-  @XmlAttribute(name = "id", required = true)
-  protected String id;
-
-  @XmlAttribute(name = "type")
-  protected String type;
-
-  @XmlAttribute(name = "file")
-  protected String file;
-
-  /**
-   * Gets the value of the property property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the property property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getProperty().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link Pdbentry.Property }
-   * 
-   * 
-   */
-  public List<Pdbentry.Property> getProperty()
-  {
-    if (property == null)
-    {
-      property = new ArrayList<Pdbentry.Property>();
-    }
-    return this.property;
-  }
-
-  /**
-   * Gets the value of the id property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getId()
-  {
-    return id;
-  }
-
-  /**
-   * Sets the value of the id property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setId(String value)
-  {
-    this.id = value;
-  }
-
-  /**
-   * Gets the value of the type property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getType()
-  {
-    return type;
-  }
-
-  /**
-   * Sets the value of the type property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setType(String value)
-  {
-    this.type = value;
-  }
-
-  /**
-   * Gets the value of the file property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getFile()
-  {
-    return file;
-  }
-
-  /**
-   * Sets the value of the file property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setFile(String value)
-  {
-    this.file = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class Property
-  {
-
-    @XmlAttribute(name = "name", required = true)
-    protected String name;
-
-    @XmlAttribute(name = "value", required = true)
-    protected String value;
+@XmlType(name = "pdbentry", namespace = "www.jalview.org", propOrder = {
+    "property"
+})
+@XmlSeeAlso({
+    jalview.xml.binding.jalview.JalviewModel.JSeq.Pdbids.class
+})
+public class Pdbentry {
+
+    protected List<Pdbentry.Property> property;
+    @XmlAttribute(name = "id", required = true)
+    protected String id;
+    @XmlAttribute(name = "type")
+    protected String type;
+    @XmlAttribute(name = "file")
+    protected String file;
 
     /**
-     * Gets the value of the name property.
+     * Gets the value of the property property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the property property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getProperty().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Pdbentry.Property }
+     * 
      * 
-     * @return possible object is {@link String }
+     */
+    public List<Pdbentry.Property> getProperty() {
+        if (property == null) {
+            property = new ArrayList<Pdbentry.Property>();
+        }
+        return this.property;
+    }
+
+    /**
+     * Gets the value of the id property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getName()
-    {
-      return name;
+    public String getId() {
+        return id;
     }
 
     /**
-     * Sets the value of the name property.
+     * Sets the value of the id property.
      * 
      * @param value
-     *          allowed object is {@link String }
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setId(String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public void setName(String value)
-    {
-      this.name = value;
+    public String getType() {
+        return type;
     }
 
     /**
-     * Gets the value of the value property.
+     * Sets the value of the type property.
      * 
-     * @return possible object is {@link String }
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setType(String value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the file property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getValue()
-    {
-      return value;
+    public String getFile() {
+        return file;
     }
 
     /**
-     * Sets the value of the value property.
+     * Sets the value of the file property.
      * 
      * @param value
-     *          allowed object is {@link String }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public void setValue(String value)
-    {
-      this.value = value;
+    public void setFile(String value) {
+        this.file = value;
     }
 
-  }
+
+    /**
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
+     * 
+     */
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class Property {
+
+        @XmlAttribute(name = "name", required = true)
+        protected String name;
+        @XmlAttribute(name = "value", required = true)
+        protected String value;
+
+        /**
+         * Gets the value of the name property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getName() {
+            return name;
+        }
+
+        /**
+         * Sets the value of the name property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setName(String value) {
+            this.name = value;
+        }
+
+        /**
+         * Gets the value of the value property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getValue() {
+            return value;
+        }
+
+        /**
+         * Sets the value of the value property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setValue(String value) {
+            this.value = value;
+        }
+
+    }
 
 }
index b70e665..5fc6047 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlAccessType;
@@ -12,82 +13,80 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for property complex type.
+ * &lt;p&gt;Java class for property complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="property">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="property"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
 @XmlType(name = "property")
-public class Property
-{
-
-  @XmlAttribute(name = "name")
-  protected String name;
+public class Property {
 
-  @XmlAttribute(name = "value")
-  protected String value;
+    @XmlAttribute(name = "name")
+    protected String name;
+    @XmlAttribute(name = "value")
+    protected String value;
 
-  /**
-   * Gets the value of the name property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getName()
-  {
-    return name;
-  }
+    /**
+     * Gets the value of the name property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getName() {
+        return name;
+    }
 
-  /**
-   * Sets the value of the name property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setName(String value)
-  {
-    this.name = value;
-  }
+    /**
+     * Sets the value of the name property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setName(String value) {
+        this.name = value;
+    }
 
-  /**
-   * Gets the value of the value property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getValue()
-  {
-    return value;
-  }
+    /**
+     * Gets the value of the value property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getValue() {
+        return value;
+    }
 
-  /**
-   * Sets the value of the value property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setValue(String value)
-  {
-    this.value = value;
-  }
+    /**
+     * Sets the value of the value property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setValue(String value) {
+        this.value = value;
+    }
 
 }
index a5923e1..af05181 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -16,340 +17,332 @@ import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for anonymous complex type.
+ * &lt;p&gt;Java class for anonymous complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType>
- *   &lt;complexContent>
- *     &lt;extension base="{www.vamsas.ac.uk/jalview/version2}SequenceType">
- *       &lt;sequence>
- *         &lt;element name="DBRef" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;sequence>
- *                   &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping" minOccurs="0"/>
- *                 &lt;/sequence>
- *                 &lt;attribute name="source" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="version" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="accessionId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="locus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *                 &lt;attribute name="canonical" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *       &lt;/sequence>
- *       &lt;attribute name="dsseqid" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="biotype" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;extension base="{www.vamsas.ac.uk/jalview/version2}SequenceType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="DBRef" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;sequence&amp;gt;
+ *                   &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping" minOccurs="0"/&amp;gt;
+ *                 &amp;lt;/sequence&amp;gt;
+ *                 &amp;lt;attribute name="source" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="version" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="accessionId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="locus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *                 &amp;lt;attribute name="canonical" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="dsseqid" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="biotype" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/extension&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "", propOrder = { "dbRef" })
+@XmlType(name = "", propOrder = {
+    "dbRef"
+})
 @XmlRootElement(name = "Sequence")
-public class Sequence extends SequenceType
+public class Sequence
+    extends SequenceType
 {
 
-  @XmlElement(name = "DBRef")
-  protected List<Sequence.DBRef> dbRef;
-
-  @XmlAttribute(name = "dsseqid")
-  protected String dsseqid;
-
-  @XmlAttribute(name = "biotype")
-  protected String biotype;
-
-  /**
-   * Gets the value of the dbRef property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the dbRef property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getDBRef().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link Sequence.DBRef }
-   * 
-   * 
-   */
-  public List<Sequence.DBRef> getDBRef()
-  {
-    if (dbRef == null)
-    {
-      dbRef = new ArrayList<Sequence.DBRef>();
-    }
-    return this.dbRef;
-  }
-
-  /**
-   * Gets the value of the dsseqid property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDsseqid()
-  {
-    return dsseqid;
-  }
-
-  /**
-   * Sets the value of the dsseqid property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDsseqid(String value)
-  {
-    this.dsseqid = value;
-  }
-
-  /**
-   * Gets the value of the biotype property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getBiotype()
-  {
-    return biotype;
-  }
-
-  /**
-   * Sets the value of the biotype property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setBiotype(String value)
-  {
-    this.biotype = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;sequence>
-   *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping" minOccurs="0"/>
-   *       &lt;/sequence>
-   *       &lt;attribute name="source" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="version" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="accessionId" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="locus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *       &lt;attribute name="canonical" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "", propOrder = { "mapping" })
-  public static class DBRef
-  {
-
-    @XmlElement(name = "Mapping")
-    protected Mapping mapping;
-
-    @XmlAttribute(name = "source")
-    protected String source;
-
-    @XmlAttribute(name = "version")
-    protected String version;
-
-    @XmlAttribute(name = "accessionId")
-    protected String accessionId;
-
-    @XmlAttribute(name = "locus")
-    protected Boolean locus;
-
-    @XmlAttribute(name = "canonical")
-    protected Boolean canonical;
+    @XmlElement(name = "DBRef")
+    protected List<Sequence.DBRef> dbRef;
+    @XmlAttribute(name = "dsseqid")
+    protected String dsseqid;
+    @XmlAttribute(name = "biotype")
+    protected String biotype;
 
     /**
-     * Gets the value of the mapping property.
+     * Gets the value of the dbRef property.
      * 
-     * @return possible object is {@link Mapping }
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the dbRef property.
      * 
-     */
-    public Mapping getMapping()
-    {
-      return mapping;
-    }
-
-    /**
-     * Sets the value of the mapping property.
-     * 
-     * @param value
-     *          allowed object is {@link Mapping }
-     * 
-     */
-    public void setMapping(Mapping value)
-    {
-      this.mapping = value;
-    }
-
-    /**
-     * Gets the value of the source property.
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getDBRef().add(newItem);
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link String }
      * 
-     */
-    public String getSource()
-    {
-      return source;
-    }
-
-    /**
-     * Sets the value of the source property.
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Sequence.DBRef }
      * 
-     * @param value
-     *          allowed object is {@link String }
      * 
      */
-    public void setSource(String value)
-    {
-      this.source = value;
+    public List<Sequence.DBRef> getDBRef() {
+        if (dbRef == null) {
+            dbRef = new ArrayList<Sequence.DBRef>();
+        }
+        return this.dbRef;
     }
 
     /**
-     * Gets the value of the version property.
-     * 
-     * @return possible object is {@link String }
+     * Gets the value of the dsseqid property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getVersion()
-    {
-      return version;
+    public String getDsseqid() {
+        return dsseqid;
     }
 
     /**
-     * Sets the value of the version property.
+     * Sets the value of the dsseqid property.
      * 
      * @param value
-     *          allowed object is {@link String }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public void setVersion(String value)
-    {
-      this.version = value;
+    public void setDsseqid(String value) {
+        this.dsseqid = value;
     }
 
     /**
-     * Gets the value of the accessionId property.
-     * 
-     * @return possible object is {@link String }
+     * Gets the value of the biotype property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getAccessionId()
-    {
-      return accessionId;
+    public String getBiotype() {
+        return biotype;
     }
 
     /**
-     * Sets the value of the accessionId property.
+     * Sets the value of the biotype property.
      * 
      * @param value
-     *          allowed object is {@link String }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public void setAccessionId(String value)
-    {
-      this.accessionId = value;
+    public void setBiotype(String value) {
+        this.biotype = value;
     }
 
-    /**
-     * Gets the value of the locus property.
-     * 
-     * @return possible object is {@link Boolean }
-     * 
-     */
-    public boolean isLocus()
-    {
-      if (locus == null)
-      {
-        return false;
-      }
-      else
-      {
-        return locus;
-      }
-    }
 
     /**
-     * Sets the value of the locus property.
+     * &lt;p&gt;Java class for anonymous complex type.
      * 
-     * @param value
-     *          allowed object is {@link Boolean }
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
      * 
-     */
-    public void setLocus(Boolean value)
-    {
-      this.locus = value;
-    }
-
-    /**
-     * Gets the value of the canonical property.
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;sequence&amp;gt;
+     *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Mapping" minOccurs="0"/&amp;gt;
+     *       &amp;lt;/sequence&amp;gt;
+     *       &amp;lt;attribute name="source" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="version" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="accessionId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="locus" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *       &amp;lt;attribute name="canonical" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
      * 
-     * @return possible object is {@link Boolean }
      * 
      */
-    public boolean isCanonical()
-    {
-      if (canonical == null)
-      {
-        return false;
-      }
-      else
-      {
-        return canonical;
-      }
-    }
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "", propOrder = {
+        "mapping"
+    })
+    public static class DBRef {
+
+        @XmlElement(name = "Mapping")
+        protected Mapping mapping;
+        @XmlAttribute(name = "source")
+        protected String source;
+        @XmlAttribute(name = "version")
+        protected String version;
+        @XmlAttribute(name = "accessionId")
+        protected String accessionId;
+        @XmlAttribute(name = "locus")
+        protected Boolean locus;
+        @XmlAttribute(name = "canonical")
+        protected Boolean canonical;
+
+        /**
+         * Gets the value of the mapping property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Mapping }
+         *     
+         */
+        public Mapping getMapping() {
+            return mapping;
+        }
+
+        /**
+         * Sets the value of the mapping property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Mapping }
+         *     
+         */
+        public void setMapping(Mapping value) {
+            this.mapping = value;
+        }
+
+        /**
+         * Gets the value of the source property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getSource() {
+            return source;
+        }
+
+        /**
+         * Sets the value of the source property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setSource(String value) {
+            this.source = value;
+        }
+
+        /**
+         * Gets the value of the version property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getVersion() {
+            return version;
+        }
+
+        /**
+         * Sets the value of the version property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setVersion(String value) {
+            this.version = value;
+        }
+
+        /**
+         * Gets the value of the accessionId property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getAccessionId() {
+            return accessionId;
+        }
+
+        /**
+         * Sets the value of the accessionId property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setAccessionId(String value) {
+            this.accessionId = value;
+        }
+
+        /**
+         * Gets the value of the locus property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isLocus() {
+            if (locus == null) {
+                return false;
+            } else {
+                return locus;
+            }
+        }
+
+        /**
+         * Sets the value of the locus property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setLocus(Boolean value) {
+            this.locus = value;
+        }
+
+        /**
+         * Gets the value of the canonical property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link Boolean }
+         *     
+         */
+        public boolean isCanonical() {
+            if (canonical == null) {
+                return false;
+            } else {
+                return canonical;
+            }
+        }
+
+        /**
+         * Sets the value of the canonical property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link Boolean }
+         *     
+         */
+        public void setCanonical(Boolean value) {
+            this.canonical = value;
+        }
 
-    /**
-     * Sets the value of the canonical property.
-     * 
-     * @param value
-     *          allowed object is {@link Boolean }
-     * 
-     */
-    public void setCanonical(Boolean value)
-    {
-      this.canonical = value;
     }
 
-  }
-
 }
index f08b225..751f6ca 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -16,319 +17,335 @@ import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for anonymous complex type.
+ * &lt;p&gt;Java class for anonymous complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType>
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Sequence" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}Annotation" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="sequenceSetProperties" maxOccurs="unbounded" minOccurs="0">
- *           &lt;complexType>
- *             &lt;complexContent>
- *               &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *                 &lt;attribute name="key" type="{http://www.w3.org/2001/XMLSchema}string" />
- *                 &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
- *               &lt;/restriction>
- *             &lt;/complexContent>
- *           &lt;/complexType>
- *         &lt;/element>
- *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}AlcodonFrame" maxOccurs="unbounded" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="gapChar" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="datasetId" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Sequence" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}Annotation" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="sequenceSetProperties" maxOccurs="unbounded" minOccurs="0"&amp;gt;
+ *           &amp;lt;complexType&amp;gt;
+ *             &amp;lt;complexContent&amp;gt;
+ *               &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *                 &amp;lt;attribute name="key" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *                 &amp;lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *               &amp;lt;/restriction&amp;gt;
+ *             &amp;lt;/complexContent&amp;gt;
+ *           &amp;lt;/complexType&amp;gt;
+ *         &amp;lt;/element&amp;gt;
+ *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}AlcodonFrame" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="Matrix" type="{www.vamsas.ac.uk/jalview/version2}MatrixType" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="gapChar" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="datasetId" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "",
-  propOrder =
-  { "sequence", "annotation", "sequenceSetProperties", "alcodonFrame" })
+@XmlType(name = "", propOrder = {
+    "sequence",
+    "annotation",
+    "sequenceSetProperties",
+    "alcodonFrame",
+    "matrix"
+})
 @XmlRootElement(name = "SequenceSet")
-public class SequenceSet
-{
-
-  @XmlElement(name = "Sequence")
-  protected List<Sequence> sequence;
-
-  @XmlElement(name = "Annotation")
-  protected List<Annotation> annotation;
-
-  protected List<SequenceSet.SequenceSetProperties> sequenceSetProperties;
+public class SequenceSet {
 
-  @XmlElement(name = "AlcodonFrame")
-  protected List<AlcodonFrame> alcodonFrame;
+    @XmlElement(name = "Sequence")
+    protected List<Sequence> sequence;
+    @XmlElement(name = "Annotation")
+    protected List<Annotation> annotation;
+    protected List<SequenceSet.SequenceSetProperties> sequenceSetProperties;
+    @XmlElement(name = "AlcodonFrame")
+    protected List<AlcodonFrame> alcodonFrame;
+    @XmlElement(name = "Matrix")
+    protected List<MatrixType> matrix;
+    @XmlAttribute(name = "gapChar", required = true)
+    protected String gapChar;
+    @XmlAttribute(name = "datasetId")
+    protected String datasetId;
 
-  @XmlAttribute(name = "gapChar", required = true)
-  protected String gapChar;
-
-  @XmlAttribute(name = "datasetId")
-  protected String datasetId;
-
-  /**
-   * Gets the value of the sequence property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the sequence property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getSequence().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link Sequence }
-   * 
-   * 
-   */
-  public List<Sequence> getSequence()
-  {
-    if (sequence == null)
-    {
-      sequence = new ArrayList<Sequence>();
+    /**
+     * Gets the value of the sequence property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the sequence property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getSequence().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Sequence }
+     * 
+     * 
+     */
+    public List<Sequence> getSequence() {
+        if (sequence == null) {
+            sequence = new ArrayList<Sequence>();
+        }
+        return this.sequence;
     }
-    return this.sequence;
-  }
 
-  /**
-   * Gets the value of the annotation property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the annotation property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getAnnotation().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link Annotation
-   * }
-   * 
-   * 
-   */
-  public List<Annotation> getAnnotation()
-  {
-    if (annotation == null)
-    {
-      annotation = new ArrayList<Annotation>();
+    /**
+     * Gets the value of the annotation property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the annotation property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getAnnotation().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link Annotation }
+     * 
+     * 
+     */
+    public List<Annotation> getAnnotation() {
+        if (annotation == null) {
+            annotation = new ArrayList<Annotation>();
+        }
+        return this.annotation;
     }
-    return this.annotation;
-  }
 
-  /**
-   * Gets the value of the sequenceSetProperties property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the sequenceSetProperties property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getSequenceSetProperties().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link SequenceSet.SequenceSetProperties }
-   * 
-   * 
-   */
-  public List<SequenceSet.SequenceSetProperties> getSequenceSetProperties()
-  {
-    if (sequenceSetProperties == null)
-    {
-      sequenceSetProperties = new ArrayList<SequenceSet.SequenceSetProperties>();
+    /**
+     * Gets the value of the sequenceSetProperties property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the sequenceSetProperties property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getSequenceSetProperties().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link SequenceSet.SequenceSetProperties }
+     * 
+     * 
+     */
+    public List<SequenceSet.SequenceSetProperties> getSequenceSetProperties() {
+        if (sequenceSetProperties == null) {
+            sequenceSetProperties = new ArrayList<SequenceSet.SequenceSetProperties>();
+        }
+        return this.sequenceSetProperties;
     }
-    return this.sequenceSetProperties;
-  }
 
-  /**
-   * Gets the value of the alcodonFrame property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the alcodonFrame property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getAlcodonFrame().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list
-   * {@link AlcodonFrame }
-   * 
-   * 
-   */
-  public List<AlcodonFrame> getAlcodonFrame()
-  {
-    if (alcodonFrame == null)
-    {
-      alcodonFrame = new ArrayList<AlcodonFrame>();
+    /**
+     * Gets the value of the alcodonFrame property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the alcodonFrame property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getAlcodonFrame().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link AlcodonFrame }
+     * 
+     * 
+     */
+    public List<AlcodonFrame> getAlcodonFrame() {
+        if (alcodonFrame == null) {
+            alcodonFrame = new ArrayList<AlcodonFrame>();
+        }
+        return this.alcodonFrame;
     }
-    return this.alcodonFrame;
-  }
-
-  /**
-   * Gets the value of the gapChar property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getGapChar()
-  {
-    return gapChar;
-  }
-
-  /**
-   * Sets the value of the gapChar property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setGapChar(String value)
-  {
-    this.gapChar = value;
-  }
-
-  /**
-   * Gets the value of the datasetId property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDatasetId()
-  {
-    return datasetId;
-  }
-
-  /**
-   * Sets the value of the datasetId property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDatasetId(String value)
-  {
-    this.datasetId = value;
-  }
-
-  /**
-   * <p>
-   * Java class for anonymous complex type.
-   * 
-   * <p>
-   * The following schema fragment specifies the expected content contained
-   * within this class.
-   * 
-   * <pre>
-   * &lt;complexType>
-   *   &lt;complexContent>
-   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
-   *       &lt;attribute name="key" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
-   *     &lt;/restriction>
-   *   &lt;/complexContent>
-   * &lt;/complexType>
-   * </pre>
-   * 
-   * 
-   */
-  @XmlAccessorType(XmlAccessType.FIELD)
-  @XmlType(name = "")
-  public static class SequenceSetProperties
-  {
-
-    @XmlAttribute(name = "key")
-    protected String key;
-
-    @XmlAttribute(name = "value")
-    protected String value;
 
     /**
-     * Gets the value of the key property.
+     * Gets the value of the matrix property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the matrix property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getMatrix().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link MatrixType }
      * 
-     * @return possible object is {@link String }
      * 
      */
-    public String getKey()
-    {
-      return key;
+    public List<MatrixType> getMatrix() {
+        if (matrix == null) {
+            matrix = new ArrayList<MatrixType>();
+        }
+        return this.matrix;
     }
 
     /**
-     * Sets the value of the key property.
-     * 
-     * @param value
-     *          allowed object is {@link String }
+     * Gets the value of the gapChar property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public void setKey(String value)
-    {
-      this.key = value;
+    public String getGapChar() {
+        return gapChar;
     }
 
     /**
-     * Gets the value of the value property.
+     * Sets the value of the gapChar property.
      * 
-     * @return possible object is {@link String }
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setGapChar(String value) {
+        this.gapChar = value;
+    }
+
+    /**
+     * Gets the value of the datasetId property.
      * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
      */
-    public String getValue()
-    {
-      return value;
+    public String getDatasetId() {
+        return datasetId;
     }
 
     /**
-     * Sets the value of the value property.
+     * Sets the value of the datasetId property.
      * 
      * @param value
-     *          allowed object is {@link String }
-     * 
+     *     allowed object is
+     *     {@link String }
+     *     
      */
-    public void setValue(String value)
-    {
-      this.value = value;
+    public void setDatasetId(String value) {
+        this.datasetId = value;
     }
 
-  }
+
+    /**
+     * &lt;p&gt;Java class for anonymous complex type.
+     * 
+     * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+     * 
+     * &lt;pre&gt;
+     * &amp;lt;complexType&amp;gt;
+     *   &amp;lt;complexContent&amp;gt;
+     *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+     *       &amp;lt;attribute name="key" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *       &amp;lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+     *     &amp;lt;/restriction&amp;gt;
+     *   &amp;lt;/complexContent&amp;gt;
+     * &amp;lt;/complexType&amp;gt;
+     * &lt;/pre&gt;
+     * 
+     * 
+     */
+    @XmlAccessorType(XmlAccessType.FIELD)
+    @XmlType(name = "")
+    public static class SequenceSetProperties {
+
+        @XmlAttribute(name = "key")
+        protected String key;
+        @XmlAttribute(name = "value")
+        protected String value;
+
+        /**
+         * Gets the value of the key property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getKey() {
+            return key;
+        }
+
+        /**
+         * Sets the value of the key property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setKey(String value) {
+            this.key = value;
+        }
+
+        /**
+         * Gets the value of the value property.
+         * 
+         * @return
+         *     possible object is
+         *     {@link String }
+         *     
+         */
+        public String getValue() {
+            return value;
+        }
+
+        /**
+         * Sets the value of the value property.
+         * 
+         * @param value
+         *     allowed object is
+         *     {@link String }
+         *     
+         */
+        public void setValue(String value) {
+            this.value = value;
+        }
+
+    }
 
 }
index 44e606d..429061b 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlAccessType;
@@ -13,137 +14,140 @@ import javax.xml.bind.annotation.XmlAttribute;
 import javax.xml.bind.annotation.XmlSeeAlso;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for SequenceType complex type.
+ * &lt;p&gt;Java class for SequenceType complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="SequenceType">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="sequence" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="SequenceType"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="sequence" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *       &amp;lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "SequenceType", propOrder = { "sequence", "name" })
-@XmlSeeAlso({ Sequence.class })
-public class SequenceType
-{
-
-  protected String sequence;
-
-  protected String name;
-
-  @XmlAttribute(name = "id")
-  protected String id;
-
-  @XmlAttribute(name = "description")
-  protected String description;
-
-  /**
-   * Gets the value of the sequence property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getSequence()
-  {
-    return sequence;
-  }
-
-  /**
-   * Sets the value of the sequence property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setSequence(String value)
-  {
-    this.sequence = value;
-  }
-
-  /**
-   * Gets the value of the name property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getName()
-  {
-    return name;
-  }
-
-  /**
-   * Sets the value of the name property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setName(String value)
-  {
-    this.name = value;
-  }
-
-  /**
-   * Gets the value of the id property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getId()
-  {
-    return id;
-  }
-
-  /**
-   * Sets the value of the id property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setId(String value)
-  {
-    this.id = value;
-  }
-
-  /**
-   * Gets the value of the description property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDescription()
-  {
-    return description;
-  }
-
-  /**
-   * Sets the value of the description property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDescription(String value)
-  {
-    this.description = value;
-  }
+@XmlType(name = "SequenceType", propOrder = {
+    "sequence",
+    "name"
+})
+@XmlSeeAlso({
+    Sequence.class
+})
+public class SequenceType {
+
+    protected String sequence;
+    protected String name;
+    @XmlAttribute(name = "id")
+    protected String id;
+    @XmlAttribute(name = "description")
+    protected String description;
+
+    /**
+     * Gets the value of the sequence property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getSequence() {
+        return sequence;
+    }
+
+    /**
+     * Sets the value of the sequence property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setSequence(String value) {
+        this.sequence = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setName(String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setId(String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the description property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDescription(String value) {
+        this.description = value;
+    }
 
 }
index ad0ea1e..f6570a2 100644 (file)
@@ -1,50 +1,46 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import javax.xml.bind.annotation.XmlEnum;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for ThresholdType.
- * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p>
+ * &lt;p&gt;Java class for ThresholdType.
  * 
- * <pre>
- * &lt;simpleType name="ThresholdType">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
- *     &lt;enumeration value="NONE"/>
- *     &lt;enumeration value="ABOVE"/>
- *     &lt;enumeration value="BELOW"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
+ * &lt;pre&gt;
+ * &amp;lt;simpleType name="ThresholdType"&amp;gt;
+ *   &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}string"&amp;gt;
+ *     &amp;lt;enumeration value="NONE"/&amp;gt;
+ *     &amp;lt;enumeration value="ABOVE"/&amp;gt;
+ *     &amp;lt;enumeration value="BELOW"/&amp;gt;
+ *   &amp;lt;/restriction&amp;gt;
+ * &amp;lt;/simpleType&amp;gt;
+ * &lt;/pre&gt;
  * 
  */
 @XmlType(name = "ThresholdType", namespace = "www.jalview.org/colours")
 @XmlEnum
-public enum ThresholdType
-{
+public enum ThresholdType {
 
-  NONE, ABOVE, BELOW;
+    NONE,
+    ABOVE,
+    BELOW;
 
-  public String value()
-  {
-    return name();
-  }
+    public String value() {
+        return name();
+    }
 
-  public static ThresholdType fromValue(String v)
-  {
-    return valueOf(v);
-  }
+    public static ThresholdType fromValue(String v) {
+        return valueOf(v);
+    }
 
 }
index 099af84..6c5240f 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -14,101 +15,95 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for VAMSAS complex type.
+ * &lt;p&gt;Java class for VAMSAS complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="VAMSAS">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="Tree" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element ref="{www.vamsas.ac.uk/jalview/version2}SequenceSet" maxOccurs="unbounded" minOccurs="0"/>
- *       &lt;/sequence>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="VAMSAS"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="Tree" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element ref="{www.vamsas.ac.uk/jalview/version2}SequenceSet" maxOccurs="unbounded" minOccurs="0"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "VAMSAS", propOrder = { "tree", "sequenceSet" })
-public class VAMSAS
-{
-
-  @XmlElement(name = "Tree")
-  protected List<String> tree;
+@XmlType(name = "VAMSAS", propOrder = {
+    "tree",
+    "sequenceSet"
+})
+public class VAMSAS {
 
-  @XmlElement(name = "SequenceSet")
-  protected List<SequenceSet> sequenceSet;
+    @XmlElement(name = "Tree")
+    protected List<String> tree;
+    @XmlElement(name = "SequenceSet")
+    protected List<SequenceSet> sequenceSet;
 
-  /**
-   * Gets the value of the tree property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the tree property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getTree().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link String }
-   * 
-   * 
-   */
-  public List<String> getTree()
-  {
-    if (tree == null)
-    {
-      tree = new ArrayList<String>();
+    /**
+     * Gets the value of the tree property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the tree property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getTree().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link String }
+     * 
+     * 
+     */
+    public List<String> getTree() {
+        if (tree == null) {
+            tree = new ArrayList<String>();
+        }
+        return this.tree;
     }
-    return this.tree;
-  }
 
-  /**
-   * Gets the value of the sequenceSet property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the sequenceSet property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getSequenceSet().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link SequenceSet
-   * }
-   * 
-   * 
-   */
-  public List<SequenceSet> getSequenceSet()
-  {
-    if (sequenceSet == null)
-    {
-      sequenceSet = new ArrayList<SequenceSet>();
+    /**
+     * Gets the value of the sequenceSet property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the sequenceSet property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getSequenceSet().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link SequenceSet }
+     * 
+     * 
+     */
+    public List<SequenceSet> getSequenceSet() {
+        if (sequenceSet == null) {
+            sequenceSet = new ArrayList<SequenceSet>();
+        }
+        return this.sequenceSet;
     }
-    return this.sequenceSet;
-  }
 
 }
index 4374c83..181d9e1 100644 (file)
@@ -1,10 +1,11 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
+
 package jalview.xml.binding.jalview;
 
 import java.util.ArrayList;
@@ -17,180 +18,177 @@ import javax.xml.bind.annotation.XmlSchemaType;
 import javax.xml.bind.annotation.XmlSeeAlso;
 import javax.xml.bind.annotation.XmlType;
 
+
 /**
- * <p>
- * Java class for WebServiceParameterSet complex type.
+ * &lt;p&gt;Java class for WebServiceParameterSet complex type.
  * 
- * <p>
- * The following schema fragment specifies the expected content contained within
- * this class.
+ * &lt;p&gt;The following schema fragment specifies the expected content contained within this class.
  * 
- * <pre>
- * &lt;complexType name="WebServiceParameterSet">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="Version" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
- *         &lt;element name="serviceURL" type="{http://www.w3.org/2001/XMLSchema}anyURI" maxOccurs="unbounded"/>
- *         &lt;element name="parameters" type="{http://www.w3.org/2001/XMLSchema}string"/>
- *       &lt;/sequence>
- *       &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
+ * &lt;pre&gt;
+ * &amp;lt;complexType name="WebServiceParameterSet"&amp;gt;
+ *   &amp;lt;complexContent&amp;gt;
+ *     &amp;lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&amp;gt;
+ *       &amp;lt;sequence&amp;gt;
+ *         &amp;lt;element name="Version" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&amp;gt;
+ *         &amp;lt;element name="serviceURL" type="{http://www.w3.org/2001/XMLSchema}anyURI" maxOccurs="unbounded"/&amp;gt;
+ *         &amp;lt;element name="parameters" type="{http://www.w3.org/2001/XMLSchema}string"/&amp;gt;
+ *       &amp;lt;/sequence&amp;gt;
+ *       &amp;lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /&amp;gt;
+ *     &amp;lt;/restriction&amp;gt;
+ *   &amp;lt;/complexContent&amp;gt;
+ * &amp;lt;/complexType&amp;gt;
+ * &lt;/pre&gt;
  * 
  * 
  */
 @XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(
-  name = "WebServiceParameterSet",
-  namespace = "www.jalview.org/xml/wsparamset",
-  propOrder =
-  { "version", "description", "serviceURL", "parameters" })
+@XmlType(name = "WebServiceParameterSet", namespace = "www.jalview.org/xml/wsparamset", propOrder = {
+    "version",
+    "description",
+    "serviceURL",
+    "parameters"
+})
 @XmlSeeAlso({
-    jalview.xml.binding.jalview.JalviewModel.Viewport.CalcIdParam.class })
-public class WebServiceParameterSet
-{
-
-  @XmlElement(name = "Version", namespace = "")
-  protected String version;
-
-  @XmlElement(namespace = "")
-  protected String description;
-
-  @XmlElement(namespace = "", required = true)
-  @XmlSchemaType(name = "anyURI")
-  protected List<String> serviceURL;
-
-  @XmlElement(namespace = "", required = true)
-  protected String parameters;
-
-  @XmlAttribute(name = "name", required = true)
-  protected String name;
-
-  /**
-   * Gets the value of the version property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getVersion()
-  {
-    return version;
-  }
-
-  /**
-   * Sets the value of the version property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setVersion(String value)
-  {
-    this.version = value;
-  }
-
-  /**
-   * Gets the value of the description property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getDescription()
-  {
-    return description;
-  }
-
-  /**
-   * Sets the value of the description property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setDescription(String value)
-  {
-    this.description = value;
-  }
-
-  /**
-   * Gets the value of the serviceURL property.
-   * 
-   * <p>
-   * This accessor method returns a reference to the live list, not a snapshot.
-   * Therefore any modification you make to the returned list will be present
-   * inside the JAXB object. This is why there is not a <CODE>set</CODE> method
-   * for the serviceURL property.
-   * 
-   * <p>
-   * For example, to add a new item, do as follows:
-   * 
-   * <pre>
-   * getServiceURL().add(newItem);
-   * </pre>
-   * 
-   * 
-   * <p>
-   * Objects of the following type(s) are allowed in the list {@link String }
-   * 
-   * 
-   */
-  public List<String> getServiceURL()
-  {
-    if (serviceURL == null)
-    {
-      serviceURL = new ArrayList<String>();
+    jalview.xml.binding.jalview.JalviewModel.Viewport.CalcIdParam.class
+})
+public class WebServiceParameterSet {
+
+    @XmlElement(name = "Version", namespace = "")
+    protected String version;
+    @XmlElement(namespace = "")
+    protected String description;
+    @XmlElement(namespace = "", required = true)
+    @XmlSchemaType(name = "anyURI")
+    protected List<String> serviceURL;
+    @XmlElement(namespace = "", required = true)
+    protected String parameters;
+    @XmlAttribute(name = "name", required = true)
+    protected String name;
+
+    /**
+     * Gets the value of the version property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getVersion() {
+        return version;
+    }
+
+    /**
+     * Sets the value of the version property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setVersion(String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the description property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setDescription(String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the serviceURL property.
+     * 
+     * &lt;p&gt;
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a &lt;CODE&gt;set&lt;/CODE&gt; method for the serviceURL property.
+     * 
+     * &lt;p&gt;
+     * For example, to add a new item, do as follows:
+     * &lt;pre&gt;
+     *    getServiceURL().add(newItem);
+     * &lt;/pre&gt;
+     * 
+     * 
+     * &lt;p&gt;
+     * Objects of the following type(s) are allowed in the list
+     * {@link String }
+     * 
+     * 
+     */
+    public List<String> getServiceURL() {
+        if (serviceURL == null) {
+            serviceURL = new ArrayList<String>();
+        }
+        return this.serviceURL;
+    }
+
+    /**
+     * Gets the value of the parameters property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getParameters() {
+        return parameters;
+    }
+
+    /**
+     * Sets the value of the parameters property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setParameters(String value) {
+        this.parameters = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setName(String value) {
+        this.name = value;
     }
-    return this.serviceURL;
-  }
-
-  /**
-   * Gets the value of the parameters property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getParameters()
-  {
-    return parameters;
-  }
-
-  /**
-   * Sets the value of the parameters property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setParameters(String value)
-  {
-    this.parameters = value;
-  }
-
-  /**
-   * Gets the value of the name property.
-   * 
-   * @return possible object is {@link String }
-   * 
-   */
-  public String getName()
-  {
-    return name;
-  }
-
-  /**
-   * Sets the value of the name property.
-   * 
-   * @param value
-   *          allowed object is {@link String }
-   * 
-   */
-  public void setName(String value)
-  {
-    this.name = value;
-  }
 
 }
index 65d49d5..bb3301a 100644 (file)
@@ -1,11 +1,9 @@
 //
-// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802 
-// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
+// This file was generated by the Eclipse Implementation of JAXB, v2.3.3 
+// See https://eclipse-ee4j.github.io/jaxb-ri 
 // Any modifications to this file will be lost upon recompilation of the source schema. 
-// Generated on: 2023.05.13 at 06:58:41 PM BST 
+// Generated on: 2023.11.01 at 07:03:09 PM GMT 
 //
 
-@javax.xml.bind.annotation.XmlSchema(
-  namespace = "www.vamsas.ac.uk/jalview/version2",
-  elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
+@javax.xml.bind.annotation.XmlSchema(namespace = "www.vamsas.ac.uk/jalview/version2", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
 package jalview.xml.binding.jalview;
diff --git a/test/files/annotation_label_width/sample.a2m b/test/files/annotation_label_width/sample.a2m
new file mode 100644 (file)
index 0000000..0ca6801
--- /dev/null
@@ -0,0 +1,80 @@
+>101
+P.I...A..Q..I.....H.....I........L.......E........G.......R.......S....D.......E.......Q.....K....E.
+T..LI....RE...V.S.E...A...I......S.......R...S.......L........D....A.....P......L...................
+..........T......S.......V.......R......V...I....I.......T......E.....M........A....K.........G.....
+.H..........F..........G........I..........G........G......E........L....A...SK
+>UPI
+P.Hye.V..S..V.....T.....M........P.......T........G.......Wl......N....T.......V.......R.....K....Q.
+G..MI....DA...V.T.R...A...L......L.......E...A.......I........A....T.....P......F...................
+..........D......Essrfr..V.......R......C...L....I.......P......E.....I........P....D.........G.....
+.N..........W..........G........S..........G........Gya....L........P....L...S-
+>SRR
+P.H...V..A..V.....K.....L........Y.......P........G.......R.......T....E.......Q.......Q.....K....E.
+Q..LA....RA...I.A.D...D...V......M.......R...I.......L........G....S.....S......E...................
+..........A......S.......V.......S......V...S....I.......E......E.....V........D....A.........A.....
+.D..........W..........A........EkvyrplivegG........G......T........L....Y...KK
+>SRR
+P.H...V..I..V.....K.....L........W.......P........G.......R.......S....E.......P.......Q.....K....Q.
+K..LV....ES...V.T.K...A...V......T.......T...S.......L........G....Y.....S......D...................
+..........E......A.......V.......S......V...S....L.......Q......E.....V........P....S.........D.....
+.Q..........WtekvyrpdilG........T..........A........G......R........L....Y...KK
+>MGY
+P.I...V..R..I.....T.....M........F.......E........G.......R.......T....K.......E.......Q.....K....Q.
+E..LA....RV...I.T.E...A...V......V.......N...I.......A........K....T.....T......P...................
+..........D......A.......T.......E......VkdqI....L.......Q......K.....VllvrslrlP....PppasrrqvsG.....
+.A..........W..........S........A..........D........G......K........P....T...SE
+>446
+P.H...V..I..V.....K.....L........W.......P........G.......K.......S....E.......R.......E.....E....T.
+Q..LA....EA...I.T.K...S...V......T.......E...T.......L........N....F.....G......P...................
+..........E......S.......V.......S......V...A....F.......E......E.....I........P....A.........K.....
+.D..........W..........AskvyhadiI..........Gne......G......K........L....Y...KK
+>SRR
+P.L...V..R..I.....T.....Y........P.......R........Ga......L.......S....P.......E.......H.....K....T.
+R..IA....RA...L.T.E...I...V......L.......D...Vevdaa..T........D....A.....G......R...................
+..........M......V.......T.......V......V...H....F.......N......E.....A........A....P.........D.....
+.D..........W..........A........V..........G........G......Eirs.....T....A...AE
+>SRR
+P.L...V..R..I.....T.....Y........P.......R........Ga......L.......S....P.......D.......H.....K....R.
+R..IA....RE...L.T.E...I...V......L.......D...Vevdaa..T........D....A.....G......R...................
+..........M......V.......T.......V......I...H....F.......N......E.....A........A....A.........D.....
+.D..........W..........A........V..........G........G......Eirs.....T....A...AE
+>SRR
+P.R...Y..R..Vip...T.....V........P.......E........G.......Qy......S....N.......E.......S.....R....K.
+A..LV....KD...V.T.E...A...V......V.......R...A.......D........G....G.....K......Y...................
+..........E......Dvapr...V.......W......V...F....P.......T......E.....I........P....D.........G.....
+.Q..........W..........G........S..........R........Gvi....R........P....L...PE
+>SRR
+P.R...Y..R..Iip...T.....V........P.......E........G.......Qy......S....N.......E.......S.....R....K.
+A..LV....KD...V.T.E...A...V......V.......R...A.......D........G....G.....K......Y...................
+..........E......Dvapr...V.......W......V...F....P.......T......E.....I........P....D.........G.....
+.Q..........W..........G........S..........R........Gvi....R........P....L...PE
+>SRR
+P.V...I..E..M.....F.....V........P.......E........G.......La......D....A.......E.......A.....K....R.
+A..LH....DR...V.S.R...Q...V......L.......E...V.......E........G....AtydesP......L...................
+..........A......Qsi.....T.......W......M...L....I.......Q......E.....V........L....E.........C.....
+.G..........W..........S........V..........G........S......K........Avw..A...SE
+>SRR
+P.I...I..E..M.....H.....V........Q.......E........Gv......L.......D....E.......E.......T.....K....R.
+T..LH....ER...V.G.R...Q...V......L.......E...I.......E........G....Any...D......E...................
+..........N......D.......Varllt..F......M...F....I.......R......E.....H........P....E.........G.....
+.G..........F..........S........I..........G........G......E........M....It..SE
+>SRR
+P.Lyr.V..D..V.....T.....V........P.......E........Gsmihg..Q.......G....Pwal....S.......R.....R....R.
+A..IV....RE...V.T.E...I...V......L.......E...A.......E........G....S.....D......P...................
+..........Slgeaw.R.......V.......W......V...V....L.......R......E.....V........G....D.........A.....
+.F..........W..........G........A..........A........G......E........L....-...--
+>SRR
+P.Lyr.V..Q..I.....T.....V........P.......E........Gsmlhg..Q.......G....Pwai....E.......R.....R....R.
+E..LV....RA...V.S.K...A...V......L.......D...A.......E........G....Teyn..P......A...................
+..........Saw....R.......V.......W......V...L....M.......S......E.....I........S....E.........T.....
+.H..........W..........G........A..........A........G......E........-....-...--
+>SRR
+P.L...V..E..M.....S.....F........P.......V........Gv......L.......T....L.......D.......Q.....K....A.
+A..MI....KS...V.T.D...V...V......R.......G...A.......M........K....L.....P......P...................
+..........Dpar...K.......L.......F......V...E....I.......F......E.....T........P....G.........G.....
+.G..........F..........G........Vtakvvvvp..G........Gky....R........P....A...P-
+>SRR
+P.L...V..E..I.....D.....L........L.......E........A.......W.......A....P.......D.......Q.....I....D.
+A..IA....DA...I.H.E...A...M......V.......E...T.......L........G....V.....P......Eraagrdsatkqhfysrfaa
+llaeratvqsA......D.......L.......T......A...V....L.......V......E.....N........S....R.........D.....
+.D..........W..........S........F..........Gm.......G......Q........-....-...--
diff --git a/test/files/annotation_label_width/test_fab41_nostructureviewers.txt b/test/files/annotation_label_width/test_fab41_nostructureviewers.txt
new file mode 100644 (file)
index 0000000..b40c4e2
--- /dev/null
@@ -0,0 +1,15 @@
+--nonews
+--nosplash
+--open=./test/files/annotation_label_width/sample.a2m
+--colour=gecos:flower
+--gui
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb
+--paematrix=./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_2_model_4.pdb
+--paematrix=./examples/test_fab41.result/test_fab41_unrelaxed_rank_2_model_4_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_3_model_2.pdb
+--paematrix=./examples/test_fab41.result/test_fab41_unrelaxed_rank_3_model_2_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_4_model_5.pdb
+--paematrix=./examples/test_fab41.result/test_fab41_unrelaxed_rank_4_model_5_scores.json
+--structure=[structureviewer=none]./examples/test_fab41.result/test_fab41_unrelaxed_rank_5_model_1.pdb
+--paematrix=./examples/test_fab41.result/test_fab41_unrelaxed_rank_5_model_1_scores.json
index 0486744..77cbd92 100644 (file)
@@ -229,12 +229,13 @@ public class CommandLineOperations
     String ln = null;
     while ((ln = worker.getOutputReader().readLine()) != null)
     {
-      System.out.println(ln);
+      System.out.println("STDOUT: " + ln);
       successfulCMDs.add(ln);
     }
     while ((ln = worker.getErrorReader().readLine()) != null)
     {
-      System.err.println(ln);
+      System.err.println("STDERR: " + ln);
+      successfulCMDs.add(ln);
     }
   }
 
@@ -247,6 +248,7 @@ public class CommandLineOperations
 
     // number of lines expected on STDERR when Jalview starts up normally
     // may need to adjust this if Jalview is excessively noisy ?
+    final int STDOUT_SETUPLINES = 50;
     final int STDERR_SETUPLINES = 50;
 
     // thread monitors stderr - bails after SETUP_TIMEOUT or when
@@ -257,14 +259,24 @@ public class CommandLineOperations
       public void run()
       {
         String ln = null;
-        int count = 0;
+        int stdoutcount = 0;
+        int stderrcount = 0;
         try
         {
           while ((ln = worker.getOutputReader().readLine()) != null)
           {
             System.out.println(ln);
             successfulCMDs.add(ln);
-            if (++count > STDERR_SETUPLINES)
+            if (++stdoutcount > STDOUT_SETUPLINES)
+            {
+              break;
+            }
+          }
+          while ((ln = worker.getErrorReader().readLine()) != null)
+          {
+            System.err.println(ln);
+            successfulCMDs.add(ln);
+            if (++stderrcount > STDERR_SETUPLINES)
             {
               break;
             }
index 30a1b9f..56d4300 100644 (file)
@@ -27,6 +27,7 @@ import java.io.BufferedReader;
 import java.io.File;
 import java.io.IOException;
 import java.io.InputStreamReader;
+import java.nio.file.Files;
 import java.nio.file.Path;
 import java.nio.file.Paths;
 import java.util.ArrayList;
@@ -161,6 +162,12 @@ public class CommandLineOperationsNG
   private Worker getJalviewDesktopRunner(boolean withAwt, String cmd,
           int timeout)
   {
+    return getJalviewDesktopRunner(withAwt, cmd, timeout, true);
+  }
+
+  private Worker getJalviewDesktopRunner(boolean withAwt, String cmd,
+          int timeout, boolean testoutput)
+  {
     /*
     boolean win = System.getProperty("os.name").indexOf("Win") >= 0;
     String pwd = "";
@@ -193,7 +200,7 @@ public class CommandLineOperationsNG
     Worker worker = null;
     try
     {
-      cmd = " --testoutput " + cmd;
+      cmd = cmd + (testoutput ? " --testoutput " : "");
       System.out.println("Running '" + _cmd + cmd + "'");
       ls2_proc = Runtime.getRuntime().exec(_cmd + cmd);
     } catch (Throwable e1)
@@ -368,6 +375,42 @@ public class CommandLineOperationsNG
     file.delete();
   }
 
+  @Test(
+    groups =
+    { "Functional", "testTask1" },
+    dataProvider = "headlessModeOutputToStdout")
+  public void testHeadlessModeOutputToStdout(String args,
+          String comparisonFile, int timeout)
+  {
+    String cmd = args;
+    File file = new File(comparisonFile);
+    Worker worker = getJalviewDesktopRunner(true, cmd, timeout, false);
+    int b = -1;
+    StringBuilder sb = new StringBuilder();
+    try
+    {
+      while ((b = worker.getOutputReader().read()) != -1)
+      {
+        sb.append(Character.toChars(b));
+      }
+    } catch (IOException e)
+    {
+      Assert.fail("IOException whilst trying to read from jalview process");
+    }
+
+    String comparisonContent = null;
+    try
+    {
+      comparisonContent = new String(Files.readAllBytes(file.toPath()));
+    } catch (IOException e)
+    {
+      Assert.fail("IOException whilst trying to read comparison file");
+    }
+
+    Assert.assertEquals(sb.toString(), comparisonContent,
+            "STDOUT from jalview command did not match the comparison file");
+  }
+
   @DataProvider(name = "allInputOperationsData")
   public Object[][] getHeadlessModeInputParams()
   {
@@ -459,4 +502,36 @@ public class CommandLineOperationsNG
         //
     };
   }
+
+  @DataProvider(name = "headlessModeOutputToStdout")
+  public static Object[][] getHeadlessModeOutputToStdout()
+  {
+    // JBPNote: I'm not clear why need to specify full path for output file
+    // when running tests on build server, but we will keep this patch for now
+    // since it works.
+    // https://issues.jalview.org/browse/JAL-1889?focusedCommentId=21609&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-21609
+    String workingDir = "test/jalview/bin";
+    return new Object[][] {
+        //
+        { "--open=examples/uniref50.fa --output=-",
+            workingDir + "/uniref50-output.fa", TEST_TIMEOUT },
+        { "--open examples/uniref50.fa --output -",
+            workingDir + "/uniref50-output.fa", TEST_TIMEOUT },
+        { "--open examples/uniref50.fa --output=[format=blc]-",
+            workingDir + "/uniref50-output.blc", TEST_TIMEOUT },
+        { "--open examples/uniref50.fa --output - --format blc",
+            workingDir + "/uniref50-output.blc", TEST_TIMEOUT },
+        { "./examples/uniref50.fa --output=-",
+            workingDir + "/uniref50-output.fa", TEST_TIMEOUT },
+        { "./examples/uniref50.fa --output - --format blc",
+            workingDir + "/uniref50-output.blc", TEST_TIMEOUT },
+        // remember you can't use shell wildcards for filenames in a test
+        { "./test/jalview/bin/argparser/testfiles/test1.fa ./test/jalview/bin/argparser/testfiles/test2.fa ./test/jalview/bin/argparser/testfiles/test3.fa --all --output -",
+            workingDir + "/test1-3.fa", TEST_TIMEOUT },
+        // but you can use java wildcards when using an equals sign
+        { "--open=./test/jalview/bin/argparser/testfiles/test*.fa --all --output -",
+            workingDir + "/test1-3.fa", TEST_TIMEOUT },
+        //
+    };
+  }
 }
index 73a0241..de6185c 100644 (file)
@@ -2,11 +2,14 @@ package jalview.bin;
 
 import java.io.File;
 import java.io.IOException;
+import java.lang.reflect.InvocationTargetException;
 import java.nio.file.Files;
 import java.util.Date;
 import java.util.HashSet;
 import java.util.Set;
 
+import javax.swing.SwingUtilities;
+
 import org.testng.Assert;
 import org.testng.annotations.AfterClass;
 import org.testng.annotations.AfterMethod;
@@ -46,15 +49,36 @@ public class CommandsTest
   }
 
   @AfterMethod(alwaysRun = true)
-  public void tearDown()
+  public void tearDown() 
   {
-    Desktop.closeDesktop();
+    try
+    {
+      // occasionally we are blocked by Jmol redraws
+      SwingUtilities.invokeAndWait(new Runnable()
+      {
+
+        @Override
+        public void run()
+        {
+          Desktop.closeDesktop();
+        }
+      });
+    } catch (Exception foo)
+    {
+      System.err.println("Failed during teardown with exception");
+      foo.printStackTrace();
+    }
+
   }
-  
-  public static void callJalviewMain(String[] args) {
-    if (Jalview.getInstance()!=null) {
+
+  public static void callJalviewMain(String[] args)
+  {
+    if (Jalview.getInstance() != null)
+    {
       Jalview.getInstance().doMain(args);
-    } else {
+    }
+    else
+    {
       Jalview.main(args);
     }
   }
@@ -72,7 +96,7 @@ public class CommandsTest
   }
   */
 
-  @Test(groups = "Functional", dataProvider = "cmdLines")
+  @Test(groups = {"Functional","testTask3"}, dataProvider = "cmdLines")
   public void commandsOpenTest(String cmdLine, boolean cmdArgs,
           int numFrames, String[] sequences)
   {
@@ -87,13 +111,13 @@ public class CommandsTest
       Assert.assertEquals(cmds.argsWereParsed(), cmdArgs,
               "Overall command parse and operation is false");
 
-      Assert.assertEquals(Desktop.getAlignFrames().length, numFrames,
+      Assert.assertEquals(Desktop.getDesktopAlignFrames().length, numFrames,
               "Wrong number of AlignFrames");
 
       if (sequences != null)
       {
         Set<String> openedSequenceNames = new HashSet<>();
-        AlignFrame[] afs = Desktop.getAlignFrames();
+        AlignFrame[] afs = Desktop.getDesktopAlignFrames();
         for (AlignFrame af : afs)
         {
           openedSequenceNames.addAll(
@@ -121,7 +145,10 @@ public class CommandsTest
     }
   }
 
-  @Test(groups = {"Functional","testTask1"}, dataProvider = "structureImageOutputFiles")
+  @Test(
+    groups =
+    { "Functional", "testTask3" },
+    dataProvider = "structureImageOutputFiles")
   public void structureImageOutputTest(String cmdLine, String[] filenames)
           throws IOException
   {
@@ -164,28 +191,30 @@ public class CommandsTest
   {
     cleanupFiles(filenames);
     String[] args = (cmdLine + " --gui").split("\\s+");
-    try {
-    callJalviewMain(args);
-    Commands cmds = Jalview.getInstance().getCommands();
-    Assert.assertNotNull(cmds);
-    File lastFile = null;
-    for (String filename : filenames)
+    try
     {
-      File file = new File(filename);
-      Assert.assertTrue(file.exists(), "File '" + filename
-              + "' was not created by '" + cmdLine + "'");
-      Assert.assertTrue(file.isFile(), "File '" + filename
-              + "' is not a file from '" + cmdLine + "'");
-      Assert.assertTrue(Files.size(file.toPath()) > 0, "File '" + filename
-              + "' has no content from '" + cmdLine + "'");
-      // make sure the successive output files get bigger!
-      if (lastFile != null)
-        Assert.assertTrue(
-                Files.size(file.toPath()) > Files.size(lastFile.toPath()));
-    }
+      callJalviewMain(args);
+      Commands cmds = Jalview.getInstance().getCommands();
+      Assert.assertNotNull(cmds);
+      File lastFile = null;
+      for (String filename : filenames)
+      {
+        File file = new File(filename);
+        Assert.assertTrue(file.exists(), "File '" + filename
+                + "' was not created by '" + cmdLine + "'");
+        Assert.assertTrue(file.isFile(), "File '" + filename
+                + "' is not a file from '" + cmdLine + "'");
+        Assert.assertTrue(Files.size(file.toPath()) > 0, "File '" + filename
+                + "' has no content from '" + cmdLine + "'");
+        // make sure the successive output files get bigger!
+        if (lastFile != null)
+          Assert.assertTrue(Files.size(file.toPath()) > Files
+                  .size(lastFile.toPath()));
+      }
     } catch (Exception x)
     {
-      Assert.fail("Unexpected exception during argFilesGlobAndSubstitutions",
+      Assert.fail(
+              "Unexpected exception during argFilesGlobAndSubstitutions",
               x);
     } finally
     {
@@ -205,31 +234,31 @@ public class CommandsTest
                 + "--open=./examples/test_fab41.result/sample.a2m "
                 + "--structure=./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb "
                 + "--structureimage=" + testfiles
-                + "/structureimage2.png --structureimagescale=1.5"
+                + "/structureimage2.png --scale=1.5 "
                 + "--open=./examples/test_fab41.result/sample.a2m "
                 + "--structure=./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb "
                 + "--structureimage=" + testfiles
-                + "/structureimage3.png --structureimagescale=2.0",
+                + "/structureimage3.png --scale=2.0 ",
             new String[]
             { testfiles + "/structureimage1.png",
                 testfiles + "/structureimage2.png",
                 testfiles + "/structureimage3.png" } },
-        /*
         { "--headless --noquit --open=./examples/test_fab41.result/sample.a2m "
                 + "--structure=./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb "
                 + "--structureimage=" + testfiles + "/structureimage1.png "
                 + "--open=./examples/test_fab41.result/sample.a2m "
                 + "--structure=./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb "
                 + "--structureimage=" + testfiles
-                + "/structureimage2.png --structureimagescale=1.5"
+                + "/structureimage2.png --scale=1.5 "
                 + "--open=./examples/test_fab41.result/sample.a2m "
                 + "--structure=./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb "
                 + "--structureimage=" + testfiles
-                + "/structureimage3.png --structureimagescale=2.0",
+                + "/structureimage3.png --scale=2.0 ",
             new String[]
             { testfiles + "/structureimage1.png",
                 testfiles + "/structureimage2.png",
                 testfiles + "/structureimage3.png" } },
+        /*
                 */
         //
     };
@@ -296,7 +325,7 @@ public class CommandsTest
 
   public static boolean lookForSequenceName(String sequenceName)
   {
-    AlignFrame[] afs = Desktop.getAlignFrames();
+    AlignFrame[] afs = Desktop.getDesktopAlignFrames();
     for (AlignFrame af : afs)
     {
       for (String name : af.getViewport().getAlignment().getSequenceNames())
@@ -322,6 +351,8 @@ public class CommandsTest
     }
   }
 
+  private final String deleteDir = "test/deleteAfter";
+
   @Test(
     groups = "Functional",
     dataProvider = "allLinkedIdsData",
@@ -348,6 +379,12 @@ public class CommandsTest
                 "File " + nonfilename + " exists when it shouldn't!");
       }
     }
+
+    File deleteDirF = new File(deleteDir);
+    if (deleteDirF.exists())
+    {
+      deleteDirF.delete();
+    }
   }
 
   @DataProvider(name = "allLinkedIdsData")
@@ -355,8 +392,6 @@ public class CommandsTest
   {
     return new Object[][] {
         //
-        /*
-         */
         { "--gui --open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --output={dirname}/{basename}.stk --close",
             new String[]
             { "test/jalview/bin/argparser/testfiles/test1.stk",
@@ -399,7 +434,7 @@ public class CommandsTest
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk", },
             null },
-        { "--gui --open=test/jalview/bin/argparser/**/*.fa --output=*.stk --close",
+        { "--gui --open=test/jalview/bin/argparser/**/*.fa --output=*/*.stk --close",
             new String[]
             { "test/jalview/bin/argparser/testfiles/test1.stk",
                 "test/jalview/bin/argparser/testfiles/test2.stk",
@@ -414,7 +449,7 @@ public class CommandsTest
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk", },
             null },
-        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output=*.stk --close",
+        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --all --output=*/*.stk --close",
             new String[]
             { "test/jalview/bin/argparser/testfiles/dir1/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir1/test2.stk",
@@ -429,7 +464,20 @@ public class CommandsTest
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk", }, },
-        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output=open*.stk --close",
+        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output=*/*.stk --close",
+            new String[]
+            { "test/jalview/bin/argparser/testfiles/dir2/test1.stk",
+                "test/jalview/bin/argparser/testfiles/dir2/test2.stk",
+                "test/jalview/bin/argparser/testfiles/dir2/test3.stk", },
+            new String[]
+            { "test/jalview/bin/argparser/testfiles/test1.stk",
+                "test/jalview/bin/argparser/testfiles/test2.stk",
+                "test/jalview/bin/argparser/testfiles/test3.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test0.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk", }, },
+        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output={dirname}/{basename}.stk --close",
             new String[]
             { "test/jalview/bin/argparser/testfiles/dir2/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir2/test2.stk",
@@ -444,7 +492,7 @@ public class CommandsTest
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk", }, },
-        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --opened --output={dirname}/{basename}.stk --close",
+        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output={dirname}/{basename}.stk --close",
             new String[]
             { "test/jalview/bin/argparser/testfiles/dir2/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir2/test2.stk",
@@ -459,7 +507,7 @@ public class CommandsTest
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk", }, },
-        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --output open*.stk --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output=open*.aln --close",
+        { "--gui --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --output {dirname}/{basename}.stk --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output={dirname}/{basename}.aln --close",
             new String[]
             { "test/jalview/bin/argparser/testfiles/dir1/test1.stk",
                 "test/jalview/bin/argparser/testfiles/dir1/test2.stk",
@@ -486,6 +534,81 @@ public class CommandsTest
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.aln",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.aln",
                 "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.aln", }, },
+        // --mkdirs
+        { "--headless --open=test/jalview/bin/argparser/testfiles/dir1/*.fa --output "
+                + deleteDir
+                + "/{dirname}/{basename}.stk --open=test/jalview/bin/argparser/testfiles/dir2/*.fa --output="
+                + deleteDir
+                + "/{dirname}/{basename}.aln --close --all --mkdirs",
+            new String[]
+            { deleteDir
+                    + "/test/jalview/bin/argparser/testfiles/dir1/test1.stk",
+                deleteDir
+                        + "/test/jalview/bin/argparser/testfiles/dir1/test2.stk",
+                deleteDir
+                        + "/test/jalview/bin/argparser/testfiles/dir2/test1.aln",
+                deleteDir
+                        + "/test/jalview/bin/argparser/testfiles/dir2/test2.aln",
+                deleteDir
+                        + "/test/jalview/bin/argparser/testfiles/dir2/test3.aln", },
+            new String[]
+            { "test/jalview/bin/argparser/testfiles/test1.stk",
+                "test/jalview/bin/argparser/testfiles/test2.stk",
+                "test/jalview/bin/argparser/testfiles/test3.stk",
+                "test/jalview/bin/argparser/testfiles/dir2/test1.stk",
+                "test/jalview/bin/argparser/testfiles/dir2/test2.stk",
+                "test/jalview/bin/argparser/testfiles/dir2/test3.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test0.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk",
+                "test/jalview/bin/argparser/testfiles/test1.aln",
+                "test/jalview/bin/argparser/testfiles/test2.aln",
+                "test/jalview/bin/argparser/testfiles/test3.aln",
+                "test/jalview/bin/argparser/testfiles/dir1/test1.aln",
+                "test/jalview/bin/argparser/testfiles/dir1/test2.aln",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test0.aln",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.aln",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.aln",
+                "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/test1.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/test2.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/test3.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir2/test1.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir2/test2.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir2/test3.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test0.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.stk",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/test1.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/test2.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/test3.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir1/test1.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir1/test2.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test0.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test1.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test2.aln",
+                deleteDir
+                        + "test/jalview/bin/argparser/testfiles/dir3/subdir/test3.aln", }, },
         //
     };
   }
index d6b6f3c..a78ca5a 100644 (file)
@@ -65,7 +65,8 @@ public class CommandsTest2
     String[] args = cmdLine.split("\\s+");
 
     CommandsTest.callJalviewMain(args);
-    while (Desktop.instance!=null && Desktop.instance.operationsAreInProgress())
+    while (Desktop.instance != null
+            && Desktop.instance.operationsAreInProgress())
     {
       try
       {
@@ -78,7 +79,7 @@ public class CommandsTest2
     }
     ;
 
-    AlignFrame[] afs = Desktop.getAlignFrames();
+    AlignFrame[] afs = Desktop.getDesktopAlignFrames();
     Assert.assertNotNull(afs);
     Assert.assertTrue(afs.length > 0);
 
index 49a721f..f737c92 100644 (file)
@@ -62,8 +62,8 @@ public class HiDPISettingTest1
     Cache.loadProperties("test/jalview/bin/hidpiTestProps.jvprops");
     Jalview.main(
             new String[]
-            { "-nosplash", "-nonews", "-noquestionnaire",
-                "-nowebservicediscovery" });
+            { "--nosplash", "--nonews", "--noquestionnaire",
+                "--nowebservicediscovery" });
 
     af = new FileLoader().LoadFileWaitTillLoaded("examples/uniref50.fa",
             DataSourceType.FILE);
index 87a26d1..6812bce 100644 (file)
@@ -171,7 +171,7 @@ public class HiDPISettingTest2
 
     String jvmArgs = HiDPISetting.getScalePropertyArg(scale);
 
-    String appArgs = " -open examples/uniref50.fa -nosplash -nonews -noquestionnaire -nousagestats -nowebservicediscovery";
+    String appArgs = " --open examples/uniref50.fa --nosplash --nonews --noquestionnaire --nousagestats --nowebservicediscovery";
 
     Worker worker = getJalviewDesktopRunner(jvmArgs, appArgs);
     assertNotNull(worker, "worker is null");
@@ -183,7 +183,7 @@ public class HiDPISettingTest2
     {
       while ((ln = worker.getErrorReader().readLine()) != null)
       {
-        if (++count > 100)
+        if (++count > 150)
         {
           break;
         }
index 9beba17..3ba096e 100644 (file)
@@ -279,9 +279,15 @@ public class ArgParserTest
   }
 
   @Test(groups = "Functional", dataProvider = "allLinkedIdsData")
-  public void allLinkedIdsTest(String commandLineArgs, Arg a,
+  public void allLinkedIdsTest(String pwd, String commandLineArgs, Arg a,
           String[] values, String[] nonvalues)
   {
+    String userDir = System.getProperty("user.dir");
+    if (pwd != null)
+    {
+      File pwdFile = new File(pwd);
+      System.setProperty("user.dir", pwdFile.getAbsolutePath());
+    }
     String[] args = commandLineArgs.split("\\s+");
     ArgParser argparser = new ArgParser(args);
 
@@ -306,12 +312,13 @@ public class ArgParserTest
         ArgValues avs = avm.getArgValues(a);
         ArgValue av = avs.getArgValue();
         String v = av.getValue();
-        value = new File(value).getAbsolutePath();
+        value = new File(value).getPath();
         Assert.assertEquals(v, value, "Arg value for " + a.argString()
                 + " not applied correctly to linkedId '" + linkedId + "'");
       }
     }
 
+    System.setProperty("user.dir", userDir);
   }
 
   @DataProvider(name = "allLinkedIdsData")
@@ -321,22 +328,33 @@ public class ArgParserTest
         //
         /*
         */
-        { "--open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --image={dirname}/{basename}.png --close",
+        { null,
+            "--open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --image={dirname}/{basename}.png --close",
             Arg.CLOSE, new String[]
             { null, null, null },
             null },
-        { "--open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --output={dirname}/{basename}.stk --close",
+        { null,
+            "--open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --output={dirname}/{basename}.stk --close",
             Arg.OUTPUT, new String[]
             { "test/jalview/bin/argparser/testfiles/test1.stk",
                 "test/jalview/bin/argparser/testfiles/test2.stk",
                 "test/jalview/bin/argparser/testfiles/test3.stk", },
             null },
-        { "--open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --image={dirname}/{basename}.png --close",
+        { null,
+            "--open=test/jalview/bin/argparser/testfiles/*.fa --substitutions --all --image={dirname}/{basename}.png --close",
             Arg.IMAGE, new String[]
             { "test/jalview/bin/argparser/testfiles/test1.png",
                 "test/jalview/bin/argparser/testfiles/test2.png",
                 "test/jalview/bin/argparser/testfiles/test3.png", },
             null },
+        /*
+         * Find a way to change pwd reliably -- need to match "*.fa" against some files!
+         { "test/jalview/bin/argparser/testfiles",
+         
+            "--open=*.fa --image={dirname}/{basename}.png --close",
+            Arg.IMAGE, new String[]
+            { "./test1.png", "./test2.png", "./test3.png", }, null },
+            */
         //
     };
   }
@@ -414,4 +432,4 @@ public class ArgParserTest
     };
   }
 
-}
+}
\ No newline at end of file
index ea3a1be..85eccd9 100644 (file)
@@ -1,9 +1,8 @@
---substitutions
 --append=examples/test_fab41.result/sample.a2m
 --showannotations
 --showssannotations
 --colour=gecos-flower
---structure=[viewer=jmol,tempfac=plddt,paematrix={dirname}/test_fab41_unrelaxed_rank_1_model_3_scores.json]{dirname}/test_fab41_unrelaxed_rank_1_model_3.pdb
+--structure=[structureviewer=jmol,tempfac=plddt,paematrix={dirname}/test_fab41_unrelaxed_rank_1_model_3_scores.json]{dirname}/test_fab41_unrelaxed_rank_1_model_3.pdb
 --structure={dirname}/test_fab41_unrelaxed_rank_2_model_4.pdb
 --structureviewer=jmol
 --paematrix={dirname}/test_fab41_unrelaxed_rank_2_model_4_scores.json
@@ -12,7 +11,7 @@
 --structureviewer=jmol
 --paematrix={dirname}/test_fab41_unrelaxed_rank_3_model_2_scores.json
 --tempfac=plddt
---structure=[viewer=none]{dirname}/test_fab41_unrelaxed_rank_4_model_5.pdb
+--structure=[structureviewer=none]{dirname}/test_fab41_unrelaxed_rank_4_model_5.pdb
 --paematrix={dirname}/test_fab41_unrelaxed_rank_4_model_5_scores.json
 --tempfac=plddt
 --structure={dirname}/test_fab41_unrelaxed_rank_5_model_1.pdb
diff --git a/test/jalview/bin/test1-3.fa b/test/jalview/bin/test1-3.fa
new file mode 100644 (file)
index 0000000..c01e6cf
--- /dev/null
@@ -0,0 +1,6 @@
+>TEST1/1-4
+AAAA
+>TEST2/1-4
+LLLL
+>TEST3/1-5
+AAARG
diff --git a/test/jalview/bin/uniref50-output.blc b/test/jalview/bin/uniref50-output.blc
new file mode 100644 (file)
index 0000000..3614ef8
--- /dev/null
@@ -0,0 +1,174 @@
+>FER_CAPAA/1-97 Ferredoxin
+>FER_CAPAN/1-144 Ferredoxin, chloroplast precursor
+>FER1_SOLLC/1-144 Ferredoxin-1, chloroplast precursor
+>Q93XJ9_SOLTU/1-144 Ferredoxin I precursor
+>FER1_PEA/1-149 Ferredoxin-1, chloroplast precursor
+>Q7XA98_TRIPR/1-152 Ferredoxin I
+>FER1_MESCR/1-148 Ferredoxin-1, chloroplast precursor
+>FER1_SPIOL/1-147 Ferredoxin-1, chloroplast precursor
+>FER3_RAPSA/1-96 Ferredoxin, leaf L-A
+>FER2_ARATH/1-148 Ferredoxin-2, chloroplast precursor
+>FER_BRANA/1-96 Ferredoxin
+>FER1_ARATH/1-148 Ferredoxin-1, chloroplast precursor
+>Q93Z60_ARATH/1-118 At1g10960/T19D16_12
+>FER1_MAIZE/1-150 Ferredoxin-1, chloroplast precursor
+>O80429_MAIZE/1-140 Ferredoxin
+* iteration 1
+-MMMMMMM-M-MMMM
+-AAAAAAA-A-AAAA
+----TTAA-S-SSTA
+----TTTT-T-TTVT
+-------------L-
+-------------G-
+------TT-----S-
+----PPAT-----P-
+-SSSAAAT-A-AAR-
+-VIILLLM-L-LLA-
+-SSSYYSM-S-SSP-
+-AGGGGGG-S-SSA-
+-TTTTTA--A-AAF-
+-MMMAAT--I-IIFA
+-IIIVVMM-V-VVFL
+-SSSSSSA-G-SSSS
+-TTTTTTT-T-TTSM
+-SSSSSAT-S-SSSS
+-FFFFFFF-F-FFSI
+-MLLLMAV-I-LLLL
+-PPPRRPP-R-RRRR
+-RRRTRKK-R-RRA-
+-KKKQQ-P-S-QQA-
+-PPPPP-Q-P-QQP-
+-AAVMVTA-A-TTAA
+-VVVPPPP-P-PPPP
+-TTTMMPP-I-IITP
+-SSSSSMM-S-SSAP
+-LLLVVTM-L-LLVC
+------AA-R-RR-F
+-KKKTAAA-S-SS-S
+-PAATTLL-L-LLAS
+-IIITTPP-P-PPLP
+-PSSKTTS-S-FFPL
+-NNNATNN-A-AAAR
+-VVVFTVT-N-NNAL
+-GGGSKGG-T-TTKR
+-EEENARR-Q-QQVV
+-----F---------
+-----P---------
+-AAAGSAS-S-SSGA
+-LLLFGLL-L-LLIV
+-FFFLFFF-F-FFMA
+-GGGGGGG-G-GGGK
+-LLLLLLL-L-LLRP
+-KKKKKKK-K-KKSL
+-SSSTSST-S-SSAA
+-----V---------
+-AGGSSSG-G-SSSA
+----LTAS-T-TTSP
+----KKSR-A-AARM
+-NRRRRR--R-RRRR
+-GNNGG---G-GG-R
+-GGGDDGG-G-GG-Q
+-KRRLLRG-R-RRRL
+-VIIAAVR-V-VVLL
+-TTTVVTM-T-TTRR
+-CCCAAAT-A-AAAA
+-MMMMMMM-M-MMQQ
+AAAAAAAAAAAAAAA
+SSSSSTAATTTTTTT
+YYYYYYYYYYYYYYY
+KKKKKKKKKKKKKNN
+VVVVVVVVVVVVVVV
+KKKKKKTTKKKKKKK
+LLLLLLLLFFFFFLL
+IIIIVIVVIIIIIII
+TTTTTTTTTTTTTTT
+PPPPPPPPPPPPPPP
+DDEDDEETEEEEEEE
+GGGGGGGGGGGGGGG
+PPPPTPKNEEEEEEE
+IIIIQQQVQLQQQVV
+EEEEEEEEEEEEEEE
+FFFFFFLFVVVVVLL
+DDEEEDEQEEEEEQQ
+CCCCCCCCCCCCCVV
+PPPPPPPPDDDEEPP
+DDDDSDDDDDDEEDD
+DNDDDDDDDDDDDDD
+VVVVVVVVVVVVVVV
+YYYYYYYYYYYYYYY
+IIIIIIIIVVVVVII
+LLLLLLLLLLLLLLL
+DDDDDDDDDDDDDDD
+QQQQHHAAAAAAAQF
+AAAAAAAAAAAAAAA
+EEEEEEEEEEEEEEE
+EEEEEEEEEEEEEEE
+AAEEVVAEAAAAADE
+GGGGGGGGGGGGGGG
+HHHHIIIIIIILLII
+DDDDDEDDDDDDDDD
+LLLLLLLLLLLLLLL
+PPPPPPPPPPPPPPP
+YYYYYYYYYYYYYYF
+SSSSSSSSSSSSSSS
+CCCCCCCCCCCCCCC
+RRRRRRRRRRRRRRR
+AAAAAAAAAAAAAAA
+GGGGGGGGGGGGGGG
+SSSSSSSSSSSSSSS
+CCCCCCCCCCCCCCC
+SSSSSSSSSSSSSSS
+SSSSSSSSSSSSSSS
+CCCCCCCCCCCCCCC
+AAAAAAAAAAAAAAA
+GGGGGGGGGGGGGGG
+KKKKKKKKKKKKKKK
+IIVVVVVLVVVVVVV
+AATTVVTKVVVVVVV
+GGAAGNSTSSSSSSS
+GGGGGGGGGGGGGGG
+AASTENSSSSFSSSS
+VVVVVVVLVVVIIVV
+DDDDDNNNDDDDDDD
+QQQQQQQQQQQQQQQ
+TTSSSEDDSSSSSSS
+DDDDDDDDDDDDDDD
+GGGGGGGQQQEQQQQ
+NNNKSSSSSSSSSSS
+FFFFFFFFFFFFFYF
+LLLLLLLLLLLLLLL
+DDDDDDDDDDDDDDN
+DDEDDDDDDDDDDDD
+DDDDEEDDDEDE-GN
+QQQQQQQQQQQQ-QQ
+LLEEIIIIIIIM-IV
+EEAAEEKDAGAS-AA
+EEAAAGEEEEEE-DD
+GGGGGGGGGGGG-GG
+WWFFFWWWFFFY-WW
+VVVVVVVVVVVV-VV
+LLLLLLLLLLLL-LL
+TTTTTTTTTTTT-TT
+CCCCCCCCCCCC-CC
+VVVVVVVAAAAV-HA
+AAAAAAAAAAAA-AA
+YYYYYFYYYYYY-YY
+PPPPPPPPPPPP-PP
+QQKKTTTVTTTT-TT
+SSGCSSGSSSSS-SS
+DDDDDDDDDDDD-DD
+VVVVVVVVVVVV-VV
+TTTTVTTTTTTV-VV
+IIIIIIIIIIII-II
+EEEEEEEEEEEE-EE
+TTTTTTTTTTTT-TT
+HHHHHHHHHHHH-HH
+KKKKKKKKRKKK-KK
+EEEEEEEEEEEE-EE
+AAEEEEEEEEEE-ED
+EEEEDEEEDDEA-ED
+LLLLLLLLMILI-LL
+VVTTTTTTVVVM-TL
+GGAAAAAA-----G-
+-------------A-
+*
diff --git a/test/jalview/bin/uniref50-output.fa b/test/jalview/bin/uniref50-output.fa
new file mode 100644 (file)
index 0000000..98e89f2
--- /dev/null
@@ -0,0 +1,60 @@
+>FER_CAPAA/1-97 Ferredoxin
+-----------------------------------------------------------ASYKVKLITPDGP
+IEFDCPDDVYILDQAEEAGHDLPYSCRAGSCSSCAGKIAGGAVDQTDGNFLDDDQLEEGWVLTCVAYPQSDV
+TIETHKEAELVG-
+>FER_CAPAN/1-144 Ferredoxin, chloroplast precursor
+MA------SVSATMISTSFMPRKPAVTSL-KPIPNVGE--ALFGLKS-A--NGGKVTCMASYKVKLITPDGP
+IEFDCPDNVYILDQAEEAGHDLPYSCRAGSCSSCAGKIAGGAVDQTDGNFLDDDQLEEGWVLTCVAYPQSDV
+TIETHKEAELVG-
+>FER1_SOLLC/1-144 Ferredoxin-1, chloroplast precursor
+MA------SISGTMISTSFLPRKPAVTSL-KAISNVGE--ALFGLKS-G--RNGRITCMASYKVKLITPEGP
+IEFECPDDVYILDQAEEEGHDLPYSCRAGSCSSCAGKVTAGSVDQSDGNFLDEDQEAAGFVLTCVAYPKGDV
+TIETHKEEELTA-
+>Q93XJ9_SOLTU/1-144 Ferredoxin I precursor
+MA------SISGTMISTSFLPRKPVVTSL-KAISNVGE--ALFGLKS-G--RNGRITCMASYKVKLITPDGP
+IEFECPDDVYILDQAEEEGHDLPYSCRAGSCSSCAGKVTAGTVDQSDGKFLDDDQEAAGFVLTCVAYPKCDV
+TIETHKEEELTA-
+>FER1_PEA/1-149 Ferredoxin-1, chloroplast precursor
+MATT---PALYGTAVSTSFLRTQPMPMSV-TTTKAFSN--GFLGLKT-SLKRGDLAVAMASYKVKLVTPDGT
+QEFECPSDVYILDHAEEVGIDLPYSCRAGSCSSCAGKVVGGEVDQSDGSFLDDEQIEAGFVLTCVAYPTSDV
+VIETHKEEDLTA-
+>Q7XA98_TRIPR/1-152 Ferredoxin I
+MATT---PALYGTAVSTSFMRRQPVPMSV-ATTTTTKAFPSGFGLKSVSTKRGDLAVAMATYKVKLITPEGP
+QEFDCPDDVYILDHAEEVGIELPYSCRAGSCSSCAGKVVNGNVNQEDGSFLDDEQIEGGWVLTCVAFPTSDV
+TIETHKEEELTA-
+>FER1_MESCR/1-148 Ferredoxin-1, chloroplast precursor
+MAAT--TAALSGATMSTAFAPK--TPPMTAALPTNVGR--ALFGLKS-SASR-GRVTAMAAYKVTLVTPEGK
+QELECPDDVYILDAAEEAGIDLPYSCRAGSCSSCAGKVTSGSVNQDDGSFLDDDQIKEGWVLTCVAYPTGDV
+TIETHKEEELTA-
+>FER1_SPIOL/1-147 Ferredoxin-1, chloroplast precursor
+MAAT--TTTMMG--MATTFVPKPQAPPMMAALPSNTGR--SLFGLKT-GSR--GGRMTMAAYKVTLVTPTGN
+VEFQCPDDVYILDAAEEEGIDLPYSCRAGSCSSCAGKLKTGSLNQDDQSFLDDDQIDEGWVLTCAAYPVSDV
+TIETHKEEELTA-
+>FER3_RAPSA/1-96 Ferredoxin, leaf L-A
+-----------------------------------------------------------ATYKVKFITPEGE
+QEVECDDDVYVLDAAEEAGIDLPYSCRAGSCSSCAGKVVSGSVDQSDQSFLDDDQIAEGFVLTCAAYPTSDV
+TIETHREEDMV--
+>FER2_ARATH/1-148 Ferredoxin-2, chloroplast precursor
+MAST----ALSSAIVGTSFIRRSPAPISLRSLPSANTQ--SLFGLKS-GTARGGRVTAMATYKVKFITPEGE
+LEVECDDDVYVLDAAEEAGIDLPYSCRAGSCSSCAGKVVSGSVDQSDQSFLDDEQIGEGFVLTCAAYPTSDV
+TIETHKEEDIV--
+>FER_BRANA/1-96 Ferredoxin
+-----------------------------------------------------------ATYKVKFITPEGE
+QEVECDDDVYVLDAAEEAGIDLPYSCRAGSCSSCAGKVVSGFVDQSDESFLDDDQIAEGFVLTCAAYPTSDV
+TIETHKEEELV--
+>FER1_ARATH/1-148 Ferredoxin-1, chloroplast precursor
+MAST----ALSSAIVSTSFLRRQQTPISLRSLPFANTQ--SLFGLKS-STARGGRVTAMATYKVKFITPEGE
+QEVECEEDVYVLDAAEEAGLDLPYSCRAGSCSSCAGKVVSGSIDQSDQSFLDDEQMSEGYVLTCVAYPTSDV
+VIETHKEEAIM--
+>Q93Z60_ARATH/1-118 At1g10960/T19D16_12
+MAST----ALSSAIVSTSFLRRQQTPISLRSLPFANTQ--SLFGLKS-STARGGRVTAMATYKVKFITPEGE
+QEVECEEDVYVLDAAEEAGLDLPYSCRAGSCSSCAGKVVSGSIDQSDQSFLDD-------------------
+-------------
+>FER1_MAIZE/1-150 Ferredoxin-1, chloroplast precursor
+MATVLGSPRAPAFFFSSSSLRAAPAPTAV--ALPAAKV--GIMGRSA-SSRR--RLRAQATYNVKLITPEGE
+VELQVPDDVYILDQAEEDGIDLPYSCRAGSCSSCAGKVVSGSVDQSDQSYLDDGQIADGWVLTCHAYPTSDV
+VIETHKEEELTGA
+>O80429_MAIZE/1-140 Ferredoxin
+MAAT---------ALSMSILR---APPPCFSSPLRLRV--AVAKPLA-APMRRQLLRAQATYNVKLITPEGE
+VELQVPDDVYILDFAEEEGIDLPFSCRAGSCSSCAGKVVSGSVDQSDQSFLNDNQVADGWVLTCAAYPTSDV
+VIETHKEDDLL--
index bdfa5a3..fa7aca5 100644 (file)
@@ -116,7 +116,11 @@ public class PAEContactMatrixTest
     AlignmentI alForSeq = new Alignment(new SequenceI[] { alseq });
     newaa = AlignmentUtils.addReferenceAnnotationTo(alForSeq, alseq, newaa,
             null);
-    ContactListI alcl = alForSeq.getContactListFor(newaa, 1);
+    // check for null on out of bounds
+    ContactListI alcl = alForSeq.getContactListFor(newaa, newaa.annotations.length);
+    assertNull(alcl,"Should've gotten null!");
+    // now check for mapping
+    alcl = alForSeq.getContactListFor(newaa, 1);
     assertNotNull(alcl);
     mappedCl = alcl.getMappedPositionsFor(0, 4);
     assertNotNull(mappedCl);
index b1bb43c..8059af9 100644 (file)
@@ -206,6 +206,32 @@ public class SearchResultsTest
     assertFalse(m.contains(null, 3, 3));
   }
 
+  @Test(groups = { "Functional" })
+  public void testMatchAdjacent()
+  {
+    SequenceI seq1 = new Sequence("", "abcdefghijklm");
+    SequenceI seq2 = new Sequence("", "abcdefghijklm");
+    SearchResultMatchI m = new SearchResults().new Match(seq1, 2, 5);
+
+    assertTrue(m.adjacent(seq1, 2, 5));
+    assertTrue(m.adjacent(seq1, 3, 5));
+    assertTrue(m.adjacent(seq1, 2, 4));
+    assertTrue(m.adjacent(seq1, 3, 3));
+
+    assertTrue(m.adjacent(seq1, 2, 6));
+    assertTrue(m.adjacent(seq1, 1, 5));
+    assertTrue(m.adjacent(seq1, 1, 8));
+    assertFalse(m.adjacent(seq1, 0, 0));
+    assertFalse(m.adjacent(seq1, 7, 8));
+    assertTrue(m.adjacent(seq1, 6, 8));
+    assertTrue(m.adjacent(seq1, 5, 8));
+    assertTrue(m.adjacent(seq1, 0, 1));
+    
+    
+    assertFalse(m.adjacent(seq2, 3, 3));
+    assertFalse(m.adjacent(null, 3, 3));
+  }
+
   /**
    * test markColumns for creating column selections
    */
@@ -308,6 +334,36 @@ public class SearchResultsTest
   }
 
   /**
+   * Test to verify appending creates a minimal set of results
+   */
+  @Test(groups = { "Functional" })
+  public void testAppendResult()
+  {
+    SequenceI seq1 = new Sequence("", "abcdefghijklm"),seq2=new Sequence("","defdefdefdef");
+    SearchResultsI sr = new SearchResults();
+    sr.appendResult(seq1, 3, 5);
+    assertEquals(1, sr.getCount());
+    sr.appendResult(seq1, 3, 6);
+    assertEquals(1, sr.getCount());
+    sr.appendResult(seq1, 8, 8);
+    assertEquals(2, sr.getCount());
+    sr.appendResult(seq1, 7, 7);
+    assertEquals(1, sr.getCount());
+    sr.appendResult(seq2, 7, 7);
+    assertEquals(2, sr.getCount());
+    sr.appendResult(seq2, 2, 7);
+    assertTrue(sr.appendResult(seq2, 7, 49));
+    assertTrue(sr.appendResult(seq2, 0, 30));
+    assertEquals(2, sr.getCount());
+    int c=0;
+    for (SearchResultMatchI sre: sr.getResults())
+    {
+      c++;
+    }
+    assertEquals(c,2);
+    
+  }
+  /**
    * Test for method that checks if search results matches a sequence region
    */
   @Test(groups = { "Functional" })
index 9dec19b..a74e51d 100644 (file)
@@ -65,7 +65,7 @@ public class JmolViewerTest
   {
     Jalview.main(
             new String[]
-            { "-noquestionnaire", "-nonews", "-props",
+            { "--noquestionnaire", "--nonews", "--props",
                 "test/jalview/ext/rbvi/chimera/testProps.jvprops" });
   }
 
index c8e30a7..e191980 100644 (file)
@@ -81,7 +81,7 @@ public class JalviewChimeraView
   {
     Jalview.main(
             new String[]
-            { "-noquestionnaire", "-nonews", "-props",
+            { "--noquestionnaire", "--nonews", "--props",
                 "test/jalview/ext/rbvi/chimera/testProps.jvprops" });
     Cache.setProperty(Preferences.STRUCTURE_DISPLAY,
             ViewerType.CHIMERA.name());
index 3839065..00e7b21 100644 (file)
@@ -824,6 +824,11 @@ public class PDBFTSRestClientTest
                           + "        \"resolution\":2.2,\n"
                           + "        \"title\":\"Crystal structure of the complex between maize sulfite reductase and ferredoxin in the form-2 crystal\"}]\n"
                           + "  }}" });
+      mocks.add(new String[] { 
+          "https://www.ebi.ac.uk/pdbe/search/pdb/select?wt=json&fl=pdb_id,title,experimental_method,resolution&rows=500&start=0&q=(4gs9+OR+6bvb+OR+8ck8+OR+8ck3+OR+6x3d+OR+8ck4+OR+6x28+OR+6i7r+OR+3h82+OR+6i7q+OR+6x21+OR+4xt2+OR+5kiz+OR+7q5v+OR+6x2h+OR+7q5x+OR+3f1n+OR+3f1o+OR+2a24+OR+3f1p+OR+1p97+OR+4ghi+OR+3h7w+OR+6d09+OR+6czw+OR+7ujv+OR+5tbm+OR+5ufp+OR+4pky+OR+6d0b+OR+6d0c+OR+6x37)+AND+molecule_sequence:%5B''+TO+*%5D+AND+status:REL&sort="
+           ,
+          readJsonStringFromFile(
+                  "test/jalview/fts/threedbeacons/q99814_tdb_pdbfts_query_resp.txt")});
     } catch (Throwable e)
     {
       Assert.fail("Couldn't read mock data.", e);
index c37058a..40e29d3 100644 (file)
@@ -39,14 +39,20 @@ import org.testng.annotations.BeforeClass;
 import org.testng.annotations.BeforeMethod;
 import org.testng.annotations.Test;
 
+import jalview.datamodel.Sequence;
+import jalview.fts.api.FTSData;
 import jalview.fts.api.FTSDataColumnI;
 import jalview.fts.api.FTSDataColumnI.FTSDataColumnGroupI;
 import jalview.fts.core.FTSRestClient;
 import jalview.fts.core.FTSRestRequest;
 import jalview.fts.core.FTSRestResponse;
 import jalview.fts.service.pdb.PDBFTSRestClientTest;
+import jalview.fts.service.threedbeacons.TDB_FTSData;
 import jalview.fts.service.threedbeacons.TDBeaconsFTSRestClient;
 import jalview.gui.JvOptionPane;
+import jalview.gui.structurechooser.PDBStructureChooserQuerySource;
+import jalview.gui.structurechooser.TDBResultAnalyser;
+import jalview.gui.structurechooser.ThreeDBStructureChooserQuerySource;
 
 public class TDBeaconsFTSRestClientTest
 {
@@ -301,7 +307,8 @@ public class TDBeaconsFTSRestClientTest
   private static String[][] mocks = { { "P38398.json", null },
       { "P01308.json", null },
       { "P0DTD1.json", null },
-      { "P27787.json", null }
+      { "P27787.json", null },
+      { "Q99814.json", null }
 
       // , { "P0DTD3.json", "{}" } actually results in 404, but {} is in body
   };
@@ -321,6 +328,8 @@ public class TDBeaconsFTSRestClientTest
 
       mocks[3][1] = PDBFTSRestClientTest.readJsonStringFromFile(
               "test/jalview/fts/threedbeacons/p27787_tdb_fts_query_resp.txt");
+      mocks[4][1] = PDBFTSRestClientTest.readJsonStringFromFile(
+              "test/jalview/fts/threedbeacons/q99814_tdb_fts_query_resp.txt");
 
     } catch (IOException e)
     {
@@ -491,4 +500,5 @@ public class TDBeaconsFTSRestClientTest
     System.out.println("Search summary : \n" + response.getSearchSummary());
     // System.out.println(response.getSearchSummary().size());
   }
+  
 }
diff --git a/test/jalview/fts/threedbeacons/q99814_tdb_fts_query.txt b/test/jalview/fts/threedbeacons/q99814_tdb_fts_query.txt
new file mode 100644 (file)
index 0000000..774b719
--- /dev/null
@@ -0,0 +1 @@
+https://www.ebi.ac.uk/pdbe/pdbe-kb/3dbeacons/api/uniprot/summary/Q99814.json
diff --git a/test/jalview/fts/threedbeacons/q99814_tdb_fts_query_resp.txt b/test/jalview/fts/threedbeacons/q99814_tdb_fts_query_resp.txt
new file mode 100644 (file)
index 0000000..17ef5e2
--- /dev/null
@@ -0,0 +1 @@
+{"uniprot_entry":{"ac":"Q99814","id":"EPAS1_HUMAN","uniprot_checksum":"4838989598234FC1","sequence_length":870,"segment_start":8,"segment_end":359},"structures":[{"summary":{"model_identifier":"3f1p","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/3f1p_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/3f1p","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2008-10-28","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.17,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"7q5v","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/7q5v_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/7q5v","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2021-11-04","sequence_identity":100.0,"uniprot_start":523,"uniprot_end":542,"coverage":0.023,"experimental_method":"X-RAY DIFFRACTION","resolution":1.17,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q9GZT9","identifier_category":"UNIPROT","description":"Egl nine homolog 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"GOL","identifier_category":"CCD","description":"GLYCEROL","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FMT","identifier_category":"CCD","description":"FORMIC ACID","chain_ids":["A","B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"CL","identifier_category":"CCD","description":"CHLORIDE ION","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"MG","identifier_category":"CCD","description":"MAGNESIUM ION","chain_ids":["A","B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"OGA","identifier_category":"CCD","description":"N-OXALYLGLYCINE","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"MN","identifier_category":"CCD","description":"MANGANESE (II) ION","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"PEG","identifier_category":"CCD","description":"DI(HYDROXYETHYL)ETHER","chain_ids":["A"]}]}},{"summary":{"model_identifier":"7q5x","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/7q5x_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/7q5x","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2021-11-04","sequence_identity":100.0,"uniprot_start":523,"uniprot_end":542,"coverage":0.023,"experimental_method":"X-RAY DIFFRACTION","resolution":1.21,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q9GZT9","identifier_category":"UNIPROT","description":"Egl nine homolog 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"GOL","identifier_category":"CCD","description":"GLYCEROL","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FMT","identifier_category":"CCD","description":"FORMIC ACID","chain_ids":["A","B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"CL","identifier_category":"CCD","description":"CHLORIDE ION","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"MG","identifier_category":"CCD","description":"MAGNESIUM ION","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"AKG","identifier_category":"CCD","description":"2-OXOGLUTARIC ACID","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"MN","identifier_category":"CCD","description":"MANGANESE (II) ION","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"PEG","identifier_category":"CCD","description":"DI(HYDROXYETHYL)ETHER","chain_ids":["A"]}]}},{"summary":{"model_identifier":"3f1n","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/3f1n_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/3f1n","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2008-10-28","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.479,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"EDO","identifier_category":"CCD","description":"1,2-ETHANEDIOL","chain_ids":["A"]}]}},{"summary":{"model_identifier":"4ghi","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/4ghi_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/4ghi","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2012-08-07","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.5,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"0X3","identifier_category":"CCD","description":"N-(3-chloro-5-fluorophenyl)-4-nitro-2,1,3-benzoxadiazol-5-amine","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6d0c","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6d0c_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6d0c","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2018-04-10","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.5,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"3h82","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/3h82_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/3h82","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2009-04-28","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.5,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"020","identifier_category":"CCD","description":"N-(furan-2-ylmethyl)-2-nitro-4-(trifluoromethyl)aniline","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6x21","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6x21_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6x21","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2020-05-19","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":348,"coverage":0.126,"experimental_method":"X-RAY DIFFRACTION","resolution":1.54,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"UKJ","identifier_category":"CCD","description":"1-(3-bromo-5-fluorophenoxy)-4-[(difluoromethyl)sulfonyl]-2-nitrobenzene","chain_ids":["A"]}]}},{"summary":{"model_identifier":"3f1o","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/3f1o_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/3f1o","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2008-10-28","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.598,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"EDO","identifier_category":"CCD","description":"1,2-ETHANEDIOL","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"2XY","identifier_category":"CCD","description":"N-[2-nitro-4-(trifluoromethyl)phenyl]morpholin-4-amine","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6czw","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6czw_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6czw","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2018-04-09","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.6,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FO7","identifier_category":"CCD","description":"{2-bromo-3-(3-chloro-5-fluorophenoxy)-6-[(difluoromethyl)sulfonyl]phenyl}methanol","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6d0b","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6d0b_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6d0b","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2018-04-10","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.6,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FOV","identifier_category":"CCD","description":"N-(3-chloro-5-fluorophenyl)-2-nitro-4-[(trifluoromethyl)sulfonyl]aniline","chain_ids":["A"]}]}},{"summary":{"model_identifier":"3h7w","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/3h7w_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/3h7w","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2009-04-28","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.65,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"018","identifier_category":"CCD","description":"2-nitro-N-(thiophen-3-ylmethyl)-4-(trifluoromethyl)aniline","chain_ids":["A"]}]}},{"summary":{"model_identifier":"4xt2","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/4xt2_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/4xt2","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2015-01-22","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.698,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["D","B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A","C"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"43L","identifier_category":"CCD","description":"(5S,7R)-5,7-bis(3-bromophenyl)-4,5,6,7-tetrahydrotetrazolo[1,5-a]pyrimidine","chain_ids":["A","C"]}]}},{"summary":{"model_identifier":"8ck3","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/8ck3_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/8ck3","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2023-02-14","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.707,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"DMS","identifier_category":"CCD","description":"DIMETHYL SULFOXIDE","chain_ids":["B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"UXU","identifier_category":"CCD","description":"(4~{S})-1-[3,5-bis(fluoranyl)phenyl]-5,5-bis(fluoranyl)-3-methylsulfonyl-4,6-dihydrocyclopenta[c]thiophen-4-ol","chain_ids":["A"]}]}},{"summary":{"model_identifier":"4gs9","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/4gs9_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/4gs9","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2012-08-27","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.72,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"PE8","identifier_category":"CCD","description":"3,6,9,12,15,18,21-HEPTAOXATRICOSANE-1,23-DIOL","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"0XB","identifier_category":"CCD","description":"N-(3-fluorophenyl)-4-nitro-2,1,3-benzoxadiazol-5-amine","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6i7q","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6i7q_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6i7q","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2018-11-17","sequence_identity":95.0,"uniprot_start":523,"uniprot_end":542,"coverage":0.023,"experimental_method":"X-RAY DIFFRACTION","resolution":1.798,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P40337","identifier_category":"UNIPROT","description":"von Hippel-Lindau disease tumor suppressor","chain_ids":["V"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q15370","identifier_category":"UNIPROT","description":"Elongin-B","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q2KII4","identifier_category":"UNIPROT","description":"Elongin-C","chain_ids":["C"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["H"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"GOL","identifier_category":"CCD","description":"GLYCEROL","chain_ids":["V"]}]}},{"summary":{"model_identifier":"7ujv","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/7ujv_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/7ujv","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2022-03-31","sequence_identity":100.0,"uniprot_start":523,"uniprot_end":542,"coverage":0.023,"experimental_method":"X-RAY DIFFRACTION","resolution":1.8,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q9GZT9","identifier_category":"UNIPROT","description":"Egl nine homolog 1","chain_ids":["B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"GOL","identifier_category":"CCD","description":"GLYCEROL","chain_ids":["B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FE","identifier_category":"CCD","description":"FE (III) ION","chain_ids":["B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"OGA","identifier_category":"CCD","description":"N-OXALYLGLYCINE","chain_ids":["B"]}]}},{"summary":{"model_identifier":"6d09","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6d09_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6d09","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2018-04-10","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.85,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FOJ","identifier_category":"CCD","description":"3-{[(3R)-4-(difluoromethyl)-2,2-difluoro-3-hydroxy-1,1-dioxo-2,3-dihydro-1H-1-benzothiophen-5-yl]oxy}-5-fluorobenzonitrile","chain_ids":["A"]}]}},{"summary":{"model_identifier":"5tbm","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/5tbm_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/5tbm","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2016-09-12","sequence_identity":97.0,"uniprot_start":237,"uniprot_end":348,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":1.85,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"79A","identifier_category":"CCD","description":"3-{[(1S)-2,2-difluoro-1-hydroxy-7-(methylsulfonyl)-2,3-dihydro-1H-inden-4-yl]oxy}-5-fluorobenzonitrile","chain_ids":["A"]}]}},{"summary":{"model_identifier":"5ufp","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/5ufp_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/5ufp","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2017-01-05","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":348,"coverage":0.126,"experimental_method":"X-RAY DIFFRACTION","resolution":1.9,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"86D","identifier_category":"CCD","description":"3-({(1S)-7-[(difluoromethyl)sulfonyl]-2,2-difluoro-1-hydroxy-2,3-dihydro-1H-inden-4-yl}oxy)-5-fluorobenzonitrile","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6x28","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6x28_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6x28","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2020-05-20","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":348,"coverage":0.126,"experimental_method":"X-RAY DIFFRACTION","resolution":1.92,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"ULG","identifier_category":"CCD","description":"(1R)-4-(3,5-difluorophenoxy)-7-(trifluoromethyl)-2,3-dihydro-1H-inden-1-ol","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6x37","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6x37_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6x37","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2020-05-21","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":348,"coverage":0.126,"experimental_method":"X-RAY DIFFRACTION","resolution":1.94,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"ULS","identifier_category":"CCD","description":"3-fluoro-5-{[(7R)-7-hydroxy-1-(trifluoromethyl)-6,7-dihydro-5H-cyclopenta[c]pyridin-4-yl]oxy}benzonitrile","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6i7r","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6i7r_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6i7r","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2018-11-17","sequence_identity":95.0,"uniprot_start":523,"uniprot_end":542,"coverage":0.023,"experimental_method":"X-RAY DIFFRACTION","resolution":1.949,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P40337","identifier_category":"UNIPROT","description":"von Hippel-Lindau disease tumor suppressor","chain_ids":["V"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q15369","identifier_category":"UNIPROT","description":"Elongin-C","chain_ids":["C"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q15370","identifier_category":"UNIPROT","description":"Elongin-B","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["H"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"FMT","identifier_category":"CCD","description":"FORMIC ACID","chain_ids":["V"]}]}},{"summary":{"model_identifier":"6x2h","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6x2h_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6x2h","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2020-05-20","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":348,"coverage":0.126,"experimental_method":"X-RAY DIFFRACTION","resolution":2.0,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"ULD","identifier_category":"CCD","description":"cis-3-({(1S)-7-[dihydroxy(trifluoromethyl)-lambda~4~-sulfanyl]-2,2-difluoro-1-hydroxy-2,3-dihydro-1H-inden-4-yl}oxy)cyclobutane-1-carbonitrile","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6x3d","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6x3d_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6x3d","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2020-05-21","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":348,"coverage":0.126,"experimental_method":"X-RAY DIFFRACTION","resolution":2.0,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"ULM","identifier_category":"CCD","description":"(6R,7S)-4-[(3,3-difluorocyclobutyl)oxy]-6-fluoro-1-(trifluoromethyl)-6,7-dihydro-5H-cyclopenta[c]pyridin-7-ol","chain_ids":["A"]}]}},{"summary":{"model_identifier":"6bvb","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/6bvb_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/6bvb","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2017-12-12","sequence_identity":100.0,"uniprot_start":523,"uniprot_end":540,"coverage":0.021,"experimental_method":"X-RAY DIFFRACTION","resolution":2.002,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P40337","identifier_category":"UNIPROT","description":"von Hippel-Lindau disease tumor suppressor","chain_ids":["V"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q15369","identifier_category":"UNIPROT","description":"Elongin-C","chain_ids":["C"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q15370","identifier_category":"UNIPROT","description":"Elongin-B","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Hypoxia-Inducible Factor 2 alpha","chain_ids":["H"]}]}},{"summary":{"model_identifier":"8ck4","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/8ck4_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/8ck4","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2023-02-14","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":2.29,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"UY3","identifier_category":"CCD","description":"(4~{S})-1-[3,5-bis(fluoranyl)phenyl]-5,5-bis(fluoranyl)-3-methylsulfonyl-6,7-dihydro-4~{H}-2-benzothiophen-4-ol","chain_ids":["A"]}]}},{"summary":{"model_identifier":"8ck8","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/8ck8_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/8ck8","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2023-02-14","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":2.302,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"UYF","identifier_category":"CCD","description":"(4~{S})-1-cyclohexyloxy-5,5-bis(fluoranyl)-3-methylsulfonyl-4,6-dihydrocyclopenta[c]thiophen-4-ol","chain_ids":["A"]}]}},{"summary":{"model_identifier":"4pky","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/4pky_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/4pky","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2014-05-15","sequence_identity":97.0,"uniprot_start":239,"uniprot_end":350,"coverage":0.129,"experimental_method":"X-RAY DIFFRACTION","resolution":3.2,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["A","D"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["G"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q9JJ11","identifier_category":"UNIPROT","description":"Transforming acidic coiled-coil-containing protein 3","chain_ids":["E","F","C","B"]},{"entity_type":"NON-POLYMER","entity_poly_type":null,"identifier":"SO4","identifier_category":"CCD","description":"SULFATE ION","chain_ids":["B"]}]}},{"summary":{"model_identifier":"1p97","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/1p97_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/1p97","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2003-05-09","sequence_identity":100.0,"uniprot_start":240,"uniprot_end":350,"coverage":0.128,"experimental_method":"SOLUTION NMR","resolution":null,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"5kiz","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/5kiz_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/5kiz","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2016-06-17","sequence_identity":94.0,"uniprot_start":239,"uniprot_end":349,"coverage":0.128,"experimental_method":"SOLUTION NMR","resolution":null,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"2a24","model_category":"EXPERIMENTALLY DETERMINED","model_url":"https://www.ebi.ac.uk/pdbe/static/entry/2a24_updated.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://www.ebi.ac.uk/pdbe/entry/pdb/2a24","provider":"PDBe","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2005-06-21","sequence_identity":100.0,"uniprot_start":242,"uniprot_end":348,"coverage":0.123,"experimental_method":"SOLUTION NMR","resolution":null,"confidence_type":null,"confidence_version":null,"confidence_avg_local_score":null,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"P27540","identifier_category":"UNIPROT","description":"Aryl hydrocarbon receptor nuclear translocator","chain_ids":["B"]},{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"Q99814_8-359:4zpk.1.B","model_category":"TEMPLATE-BASED","model_url":"https://swissmodel.expasy.org/3d-beacons/uniprot/Q99814.pdb?range=8-359&template=4zpk.1.B&provider=swissmodel","model_format":"PDB","model_type":"ATOMIC","model_page_url":"https://swissmodel.expasy.org/repository/uniprot/Q99814?range=8-359&template=4zpk.1.B","provider":"SWISS-MODEL","created":"2023-10-21","sequence_identity":1.0,"uniprot_start":8,"uniprot_end":359,"coverage":0.405,"confidence_type":"QMEANDisCo","confidence_version":"4.3.1","confidence_avg_local_score":0.676,"oligomeric_state":"MONOMER","entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"model based on template 4zpk.1.B: Endothelial PAS domain-containing protein 1","chain_ids":["B"]}]}},{"summary":{"model_identifier":"Q99814_26-342:7w80.1.A","model_category":"TEMPLATE-BASED","model_url":"https://swissmodel.expasy.org/3d-beacons/uniprot/Q99814.pdb?range=26-342&template=7w80.1.A&provider=swissmodel","model_format":"PDB","model_type":"ATOMIC","model_page_url":"https://swissmodel.expasy.org/repository/uniprot/Q99814?range=26-342&template=7w80.1.A","provider":"SWISS-MODEL","created":"2023-10-21","sequence_identity":1.0,"uniprot_start":26,"uniprot_end":342,"coverage":0.364,"confidence_type":"QMEANDisCo","confidence_version":"4.3.1","confidence_avg_local_score":0.586,"oligomeric_state":"MONOMER","entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"model based on template 7w80.1.A: Aryl hydrocarbon receptor nuclear translocator","chain_ids":["A"]}]}},{"summary":{"model_identifier":"AF-Q99814-F1","model_category":"AB-INITIO","model_url":"https://alphafold.ebi.ac.uk/files/AF-Q99814-F1-model_v4.cif","model_format":"MMCIF","model_type":null,"model_page_url":"https://alphafold.ebi.ac.uk/entry/Q99814","provider":"AlphaFold DB","number_of_conformers":null,"ensemble_sample_url":null,"ensemble_sample_format":null,"created":"2022-06-01","sequence_identity":1.0,"uniprot_start":1,"uniprot_end":870,"coverage":1.0,"experimental_method":null,"resolution":null,"confidence_type":"pLDDT","confidence_version":null,"confidence_avg_local_score":58.6,"oligomeric_state":null,"preferred_assembly_id":null,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"Q99814","model_category":"TEMPLATE-BASED","model_url":"https://alphafill.eu/v1/aff/Q99814","model_format":"MMCIF","model_page_url":"https://alphafill.eu/model?id=Q99814","provider":"AlphaFill","created":"2022-05-07","sequence_identity":1.0,"uniprot_start":1,"uniprot_end":870,"coverage":1.0,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]},{"entity_type":"NON-POLYMER","description":"PROFLAVIN","chain_ids":["B","C"]},{"entity_type":"NON-POLYMER","description":"ERBIUM (III) ION","chain_ids":["D","E","F","G","H","I","J","K"]}]}},{"summary":{"model_identifier":"CHS.29392.1","model_category":"AB-INITIO","model_url":"https://storage.googleapis.com/isoform.io/pdb/CHS.29392.1.pdb","model_format":"PDB","provider":"isoform.io","created":"2022-06-05","sequence_identity":1.0,"uniprot_start":1,"uniprot_end":870,"coverage":1.0,"entities":[{"entity_type":"POLYMER","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A"]}]}},{"summary":{"model_identifier":"Q99814_V1_5","model_category":"AB-INITIO","model_url":"https://shmoo.weizmann.ac.il/elevy/HomAtlas/Q99814_V1_5.pdb","model_format":"PDB","model_type":"ATOMIC","provider":"levylab","created":"2023-09-14","sequence_identity":1.0,"uniprot_start":1,"uniprot_end":870,"coverage":1.0,"confidence_type":"pLDDT","confidence_version":"AlphaFold2","confidence_avg_local_score":50.9166,"oligomeric_state":"HOMODIMER","oligomeric_state_confidence":0.6276,"entities":[{"entity_type":"POLYMER","entity_poly_type":"POLYPEPTIDE(L)","identifier":"Q99814","identifier_category":"UNIPROT","description":"Endothelial PAS domain-containing protein 1","chain_ids":["A","B"]}]}}]}
\ No newline at end of file
diff --git a/test/jalview/fts/threedbeacons/q99814_tdb_pdbfts_query_resp.txt b/test/jalview/fts/threedbeacons/q99814_tdb_pdbfts_query_resp.txt
new file mode 100644 (file)
index 0000000..a69d63a
--- /dev/null
@@ -0,0 +1,354 @@
+{
+  "responseHeader":{
+    "status":0,
+    "QTime":0,
+    "params":{
+      "q":"(4gs9 OR 6bvb OR 8ck8 OR 8ck3 OR 6x3d OR 8ck4 OR 6x28 OR 6i7r OR 3h82 OR 6i7q OR 6x21 OR 4xt2 OR 5kiz OR 7q5v OR 6x2h OR 7q5x OR 3f1n OR 3f1o OR 2a24 OR 3f1p OR 1p97 OR 4ghi OR 3h7w OR 6d09 OR 6czw OR 7ujv OR 5tbm OR 5ufp OR 4pky OR 6d0b OR 6d0c OR 6x37) AND molecule_sequence:['' TO *] AND status:REL",
+      "fl":"pdb_id,title,experimental_method,resolution",
+      "start":"0",
+      "sort":"",
+      "rows":"500",
+      "wt":"json"}},
+  "response":{"numFound":69,"start":0,"docs":[
+      {
+        "experimental_method":["Solution NMR"],
+        "pdb_id":"1p97",
+        "title":"NMR structure of the C-terminal PAS domain of HIF2a"},
+      {
+        "experimental_method":["Solution NMR"],
+        "pdb_id":"5kiz",
+        "title":"Solution Structure of a repacked version of HIF-2 alpha PAS-B"},
+      {
+        "experimental_method":["Solution NMR"],
+        "pdb_id":"2a24",
+        "title":"HADDOCK Structure of HIF-2a/ARNT PAS-B Heterodimer"},
+      {
+        "experimental_method":["Solution NMR"],
+        "pdb_id":"2a24",
+        "title":"HADDOCK Structure of HIF-2a/ARNT PAS-B Heterodimer"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x28",
+        "resolution":1.92,
+        "title":"Crystal structure of PT2243 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x2h",
+        "resolution":2.0,
+        "title":"Crystal structure of PT2863 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6d0c",
+        "resolution":1.5,
+        "title":"Crystal structure of HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6d0c",
+        "resolution":1.5,
+        "title":"Crystal structure of HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x28",
+        "resolution":1.92,
+        "title":"Crystal structure of PT2243 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x3d",
+        "resolution":2.0,
+        "title":"Crystal structure of PT3388 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x3d",
+        "resolution":2.0,
+        "title":"Crystal structure of PT3388 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x37",
+        "resolution":1.94,
+        "title":"Crystal structure of PT3245 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x37",
+        "resolution":1.94,
+        "title":"Crystal structure of PT3245 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x21",
+        "resolution":1.54,
+        "title":"Crystal structure of PT1673 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x21",
+        "resolution":1.54,
+        "title":"Crystal structure of PT1673 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6x2h",
+        "resolution":2.0,
+        "title":"Crystal structure of PT2863 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6d0b",
+        "resolution":1.6,
+        "title":"Crystal structure of PT1614 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6d09",
+        "resolution":1.85,
+        "title":"Crystal structure of PT2440 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6czw",
+        "resolution":1.6,
+        "title":"Crystal structure of PT1940 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"8ck8",
+        "resolution":2.302,
+        "title":"STRUCTURE OF HIF2A-ARNT HETERODIMER IN COMPLEX WITH (S)-1-Cyclohexyloxy-5,5-difluoro-3-methanesulfonyl-5,6-dihydro-4H-cyclopenta[c]thiophen-4-ol"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"8ck4",
+        "resolution":2.29,
+        "title":"STRUCTURE OF HIF2A-ARNT HETERODIMER IN COMPLEX WITH (4S)-1-(3,5-difluorophenyl)-5,5-difluoro-3-methanesulfonyl-4,5,6,7-tetrahydro-2-benzothiophen-4-ol"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"8ck4",
+        "resolution":2.29,
+        "title":"STRUCTURE OF HIF2A-ARNT HETERODIMER IN COMPLEX WITH (4S)-1-(3,5-difluorophenyl)-5,5-difluoro-3-methanesulfonyl-4,5,6,7-tetrahydro-2-benzothiophen-4-ol"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"8ck8",
+        "resolution":2.302,
+        "title":"STRUCTURE OF HIF2A-ARNT HETERODIMER IN COMPLEX WITH (S)-1-Cyclohexyloxy-5,5-difluoro-3-methanesulfonyl-5,6-dihydro-4H-cyclopenta[c]thiophen-4-ol"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4xt2",
+        "resolution":1.698,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains in complex with a tetrazole-containing antagonist"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3h82",
+        "resolution":1.5,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains with the artificial ligand THS020"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3h7w",
+        "resolution":1.65,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains with the artificial ligand THS017"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3f1p",
+        "resolution":1.17,
+        "title":"Crystal structure of a high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3f1p",
+        "resolution":1.17,
+        "title":"Crystal structure of a high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6d0b",
+        "resolution":1.6,
+        "title":"Crystal structure of PT1614 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6d09",
+        "resolution":1.85,
+        "title":"Crystal structure of PT2440 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6czw",
+        "resolution":1.6,
+        "title":"Crystal structure of PT1940 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4xt2",
+        "resolution":1.698,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains in complex with a tetrazole-containing antagonist"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"5tbm",
+        "resolution":1.85,
+        "title":"Crystal structure of PT2385 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3h82",
+        "resolution":1.5,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains with the artificial ligand THS020"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4gs9",
+        "resolution":1.72,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains in complex with an inactive benzoxadiazole antagonist"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4ghi",
+        "resolution":1.5,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains in complex with a benzoxadiazole antagonist"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4ghi",
+        "resolution":1.5,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains in complex with a benzoxadiazole antagonist"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3h7w",
+        "resolution":1.65,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains with the artificial ligand THS017"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3f1n",
+        "resolution":1.479,
+        "title":"Crystal structure of a high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains, with internally bound ethylene glycol."},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3f1n",
+        "resolution":1.479,
+        "title":"Crystal structure of a high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains, with internally bound ethylene glycol."},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3f1o",
+        "resolution":1.598,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains, with an internally-bound artificial ligand"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"3f1o",
+        "resolution":1.598,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains, with an internally-bound artificial ligand"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"7ujv",
+        "resolution":1.8,
+        "title":"Structure of PHD2 in complex with HIF2a-CODD"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"8ck3",
+        "resolution":1.707,
+        "title":"STRUCTURE OF HIF2A-ARNT HETERODIMER IN COMPLEX WITH (S)-1-(3,5-Difluoro-phenyl)-5,5-difluoro-3-methanesulfonyl-5,6-dihydro-4H-cyclopenta[c]thiophen-4-ol"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"8ck3",
+        "resolution":1.707,
+        "title":"STRUCTURE OF HIF2A-ARNT HETERODIMER IN COMPLEX WITH (S)-1-(3,5-Difluoro-phenyl)-5,5-difluoro-3-methanesulfonyl-5,6-dihydro-4H-cyclopenta[c]thiophen-4-ol"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4gs9",
+        "resolution":1.72,
+        "title":"Crystal structure of the high affinity heterodimer of HIF2 alpha and ARNT C-terminal PAS domains in complex with an inactive benzoxadiazole antagonist"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"5tbm",
+        "resolution":1.85,
+        "title":"Crystal structure of PT2385 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"5ufp",
+        "resolution":1.9,
+        "title":"Crystal structure of PT2399 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"5ufp",
+        "resolution":1.9,
+        "title":"Crystal structure of PT2399 bound to HIF2a-B*:ARNT-B* complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4pky",
+        "resolution":3.2,
+        "title":"ARNT/HIF transcription factor/coactivator complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6bvb",
+        "resolution":2.002,
+        "title":"Crystal structure of HIF-2alpha-pVHL-elongin B-elongin C"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4pky",
+        "resolution":3.2,
+        "title":"ARNT/HIF transcription factor/coactivator complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"4pky",
+        "resolution":3.2,
+        "title":"ARNT/HIF transcription factor/coactivator complex"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7q",
+        "resolution":1.798,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the C2221 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7r",
+        "resolution":1.949,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the P43212 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"7ujv",
+        "resolution":1.8,
+        "title":"Structure of PHD2 in complex with HIF2a-CODD"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"7q5v",
+        "resolution":1.17,
+        "title":"HIF PROLYL HYDROXYLASE 2 (PHD2/EGLN1) IN COMPLEX WITH N-OXALYLGLYCINE (NOG) AND HIF-2 ALPHA CODD (523-542)"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"7q5x",
+        "resolution":1.21,
+        "title":"HIF PROLYL HYDROXYLASE 2 (PHD2/EGLN1) IN COMPLEX WITH 2-OXOGLUTARATE (2OG) AND HIF-2 ALPHA CODD (523-542)"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"7q5v",
+        "resolution":1.17,
+        "title":"HIF PROLYL HYDROXYLASE 2 (PHD2/EGLN1) IN COMPLEX WITH N-OXALYLGLYCINE (NOG) AND HIF-2 ALPHA CODD (523-542)"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6bvb",
+        "resolution":2.002,
+        "title":"Crystal structure of HIF-2alpha-pVHL-elongin B-elongin C"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"7q5x",
+        "resolution":1.21,
+        "title":"HIF PROLYL HYDROXYLASE 2 (PHD2/EGLN1) IN COMPLEX WITH 2-OXOGLUTARATE (2OG) AND HIF-2 ALPHA CODD (523-542)"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7r",
+        "resolution":1.949,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the P43212 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7q",
+        "resolution":1.798,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the C2221 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6bvb",
+        "resolution":2.002,
+        "title":"Crystal structure of HIF-2alpha-pVHL-elongin B-elongin C"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7r",
+        "resolution":1.949,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the P43212 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7q",
+        "resolution":1.798,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the C2221 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6bvb",
+        "resolution":2.002,
+        "title":"Crystal structure of HIF-2alpha-pVHL-elongin B-elongin C"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7q",
+        "resolution":1.798,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the C2221 form"},
+      {
+        "experimental_method":["X-ray diffraction"],
+        "pdb_id":"6i7r",
+        "resolution":1.949,
+        "title":"Structure of pVHL-elongin B-elongin C (VCB) in complex with hydroxylated-HIF-2alpha (523-542) in the P43212 form"}]
+  }}
index ab2a1d0..2affde0 100644 (file)
@@ -69,7 +69,7 @@ public class AlignFrameTest
      * use read-only test properties file
      */
     Cache.loadProperties("test/jalview/io/testProps.jvprops");
-    Jalview.main(new String[] { "-nonews" });
+    Jalview.main(new String[] { "--nonews" });
   }
 
   @AfterMethod(alwaysRun = true)
index 4537dcc..7399c66 100644 (file)
@@ -77,7 +77,7 @@ public class AlignViewportTest
   {
     Jalview.main(
             new String[]
-            { "-nonews", "-props", "test/jalview/testProps.jvprops" });
+            { "--nonews", "--props", "test/jalview/testProps.jvprops" });
 
     /*
      * remove any sequence mappings left lying around by other tests
index c1896bc..a39257c 100644 (file)
@@ -23,7 +23,9 @@ package jalview.gui;
 import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertNotEquals;
 import static org.testng.Assert.assertNotNull;
+import static org.testng.Assert.assertTrue;
 
+import java.awt.Container;
 import java.awt.Dimension;
 import java.awt.Font;
 import java.awt.FontMetrics;
@@ -52,7 +54,7 @@ public class AlignmentPanelTest
   {
     Jalview.main(
             new String[]
-            { "-nonews", "-props", "test/jalview/testProps.jvprops" });
+            { "--nonews", "--props", "test/jalview/testProps.jvprops" });
 
     Cache.applicationProperties.setProperty("SHOW_IDENTITY",
             Boolean.TRUE.toString());
@@ -208,8 +210,9 @@ public class AlignmentPanelTest
   /**
    * Test the variant of calculateIdWidth that computes the longest of any
    * sequence name or annotation label width
+   * FIXME: JAL-4291: test needs updating for JAL-244 and JAL-4091
    */
-  @Test(groups = "Functional")
+  @Test(groups = "Functional",enabled=false)
   public void testCalculateIdWidth_withMaxWidth()
   {
     AlignViewportI av = af.alignPanel.getAlignViewport();
@@ -218,13 +221,20 @@ public class AlignmentPanelTest
     av.setShowAnnotation(false);
     av.setIdWidth(18);
 
+    FontMetrics fmfor = new Container()
+            .getFontMetrics(new Font(af.viewport.font.getName(),
+                    Font.ITALIC, af.viewport.font.getSize()));
+
     /*
      * note 4 pixels 'padding' are added to the longest seq name/annotation label
      */
     Dimension d = af.alignPanel.calculateIdWidth(2000);
+    // Assumption ID_WIDTH_PADDING == 4
+    int expwidth = 3 + fmfor.stringWidth("Conservation");
+
     assertEquals(d.width, 166); // 4 + pixel width of "Q93Z60_ARATH/1-118"
     assertEquals(d.height, 12); // fixed value (not used?)
-    assertEquals(av.getIdWidth(), 18); // not changed by this method
+    assertEquals(av.getIdWidth(), expwidth); // not changed by this method
 
     /*
      * make the longest sequence name longer
@@ -243,11 +253,10 @@ public class AlignmentPanelTest
      */
     AlignmentAnnotation aa = av.getAlignment().getAlignmentAnnotation()[0];
     aa.label = "THIS IS A VERY LONG LABEL INDEED";
-    FontMetrics fmfor = af.alignPanel
-            .getFontMetrics(af.alignPanel.getAlabels().getFont());
-    // Assumption ID_WIDTH_PADDING == 4
-    int expwidth = 4 + fmfor.stringWidth(aa.label);
     d = af.alignPanel.calculateIdWidth(2000);
+    // Assumption ID_WIDTH_PADDING == 3
+    expwidth = 3 + fmfor.stringWidth(aa.label);
+
     assertEquals(d.width, expwidth); // 228 == ID_WIDTH_PADDING + pixel width of
                                      // "THIS IS A VERY LONG LABEL INDEED"
     assertEquals(d.height, 12);
@@ -291,7 +300,30 @@ public class AlignmentPanelTest
     Cache.setProperty("FIGURE_AUTOIDWIDTH", Boolean.TRUE.toString());
     assertEquals(115, af.alignPanel.getVisibleIdWidth(false));
   }
+  @Test(groups = { "Functional", "Not-bamboo" })
+  public void testresetIdWidth()
+  {
+    /*
+     * width for onscreen rendering is IDPanel width
+     */
+    int w = af.alignPanel.getVisibleIdWidth(true);
+    assertEquals(w, af.alignPanel.getIdPanel().getWidth());
+    assertEquals(w, 115);
 
+    // manually adjust 
+    af.viewport.setIdWidth(200);
+    w = af.alignPanel.calculateIdWidth().width;
+    assertTrue(af.alignPanel.getIdPanel().getIdCanvas().isManuallyAdjusted());
+    assertEquals(w, af.alignPanel.getIdPanel().getWidth());
+
+    af.viewport.setIdWidth(-1);
+    af.alignPanel.getIdPanel().getIdCanvas().setManuallyAdjusted(false);
+    w = af.alignPanel.calculateIdWidth().width;
+    
+    assertEquals(w, af.alignPanel.getIdPanel().getWidth());
+
+    assertNotEquals(w,115);
+  }
   @Test(groups = "Functional")
   public void testSetOverviewTitle()
   {
diff --git a/test/jalview/gui/AnnotationLabelsTest2.java b/test/jalview/gui/AnnotationLabelsTest2.java
new file mode 100644 (file)
index 0000000..ad97e8b
--- /dev/null
@@ -0,0 +1,253 @@
+/*
+ * 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 
+ * 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 
+ * 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 <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
+ */
+package jalview.gui;
+
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertFalse;
+import static org.testng.Assert.assertTrue;
+
+import java.io.File;
+
+import org.testng.annotations.AfterMethod;
+import org.testng.annotations.BeforeClass;
+import org.testng.annotations.BeforeMethod;
+import org.testng.annotations.DataProvider;
+import org.testng.annotations.Test;
+
+import jalview.bin.Cache;
+import jalview.bin.Jalview;
+import jalview.datamodel.AlignmentI;
+import jalview.datamodel.SequenceI;
+import jalview.gui.StructureViewer.ViewerType;
+import jalview.io.DataSourceType;
+import jalview.io.FileLoader;
+import jalview.structure.StructureImportSettings.TFType;
+
+public class AnnotationLabelsTest2
+{
+  @BeforeClass(alwaysRun = true)
+  public static void setUpBeforeClass() throws Exception
+  {
+    if (Desktop.instance != null)
+      Desktop.instance.closeAll_actionPerformed(null);
+
+    setUpJvOptionPane();
+    /*
+     * use read-only test properties file
+     */
+    Cache.loadProperties("test/jalview/io/testProps.jvprops");
+    Jalview.main(new String[] { "--nonews", "--nosplash", });
+  }
+
+  @AfterMethod(alwaysRun = true)
+  public void tearDown()
+  {
+    if (Desktop.instance != null)
+      Desktop.instance.closeAll_actionPerformed(null);
+  }
+
+  /**
+   * configure (read-only) properties for test to ensure Consensus is computed
+   * for colour Above PID testing
+   */
+  @BeforeMethod(alwaysRun = true)
+  public void setUp()
+  {
+    Cache.loadProperties("test/jalview/io/testProps.jvprops");
+    Cache.applicationProperties.setProperty("SHOW_IDENTITY",
+            Boolean.TRUE.toString());
+
+  }
+
+  public static void setUpJvOptionPane()
+  {
+    JvOptionPane.setInteractiveMode(false);
+    JvOptionPane.setMockResponse(JvOptionPane.CANCEL_OPTION);
+  }
+
+  @Test(
+    groups =
+    { "Functional", "testTask1" },
+    dataProvider = "openFilesWithIdWidthChanges")
+  public void testIdWidthChanges(String alignmentFilename, boolean wrap,
+          int idWidth1min, int idWidth1max, int manualWidth,
+          String structureFilename, String paeFilename,
+          boolean secondaryStructureView, TFType temperatureFactorType,
+          ViewerType viewerType, int idWidth2min, int idWidth2max)
+  {
+    AlignFrame af = new FileLoader()
+            .LoadFileWaitTillLoaded(alignmentFilename, DataSourceType.FILE);
+    try
+    {
+      Thread.sleep(200); // to allow alignment annotations to open
+    } catch (InterruptedException e)
+    {
+      // TODO Auto-generated catch block
+      e.printStackTrace();
+    }
+    AlignViewport av = af.getCurrentView();
+
+    int idWidth = 0;
+
+    idWidth = av.getIdWidth();
+    assertTrue(idWidth > idWidth1min,
+            "idWidth (" + idWidth + ") is not greater than " + idWidth1min);
+    assertTrue(idWidth < idWidth1max,
+            "idWidth (" + idWidth + ") is not narrower than" + idWidth1max);
+
+    // set wrap
+    if (wrap)
+    {
+      af.setWrapFormat(true, false);
+      idWidth = av.getIdWidth();
+      assertTrue(idWidth > idWidth1min, "After wrap idWidth (" + idWidth
+              + ") is not greater than " + idWidth1min);
+      assertTrue(idWidth < idWidth1max, "After wrap idWidth (" + idWidth
+              + ") is not narrower than" + idWidth1max);
+    }
+
+    AlignmentI al = av.getAlignment();
+    SequenceI s = al.getSequenceAt(0);
+    AlignmentPanel ap = af.alignPanel;
+
+    File structureFile = new File(structureFilename);
+    File paeFile = new File(paeFilename);
+
+    StructureViewer sv = StructureChooser.openStructureFileForSequence(null,
+            null, ap, s, false, structureFile.getAbsolutePath(),
+            temperatureFactorType, paeFile.getAbsolutePath(), true,
+            secondaryStructureView, false, viewerType);
+    // give time for annotations to open
+    try
+    {
+      Thread.sleep(200); // to allow alignment annotations to open
+    } catch (InterruptedException e)
+    {
+      // TODO Auto-generated catch block
+      e.printStackTrace();
+    }
+
+    // idWidth = ap.getIdPanel().getWidth();
+    idWidth = av.getIdWidth();
+    assertTrue(idWidth > idWidth2min,
+            "idWidth (" + idWidth + ") is not greater than " + idWidth2min);
+    assertTrue(idWidth < idWidth2max,
+            "idWidth (" + idWidth + ") is not narrower than" + idWidth2max);
+  }
+
+  @Test(
+    groups =
+    { "Functional", "testTask1" },
+    dataProvider = "openFilesWithIdWidthChanges")
+  public void testIdWidthNoChanges(String alignmentFilename, boolean wrap,
+          int idWidth1min, int idWidth1max, int manualWidth,
+          String structureFilename, String paeFilename,
+          boolean secondaryStructureView, TFType temperatureFactorType,
+          ViewerType viewerType, int idWidth2min, int idWidth2max)
+  {
+    AlignFrame af = new FileLoader()
+            .LoadFileWaitTillLoaded(alignmentFilename, DataSourceType.FILE);
+    try
+    {
+      Thread.sleep(200); // to allow alignment annotations to open
+    } catch (InterruptedException e)
+    {
+      // TODO Auto-generated catch block
+      e.printStackTrace();
+    }
+    AlignViewport av = af.getCurrentView();
+
+    int idWidth = 0;
+
+    idWidth = av.getIdWidth();
+    assertTrue(idWidth > idWidth1min,
+            "idWidth (" + idWidth + ") is not greater than " + idWidth1min);
+    assertTrue(idWidth < idWidth1max,
+            "idWidth (" + idWidth + ") is not narrower than" + idWidth1max);
+
+    AlignmentI al = av.getAlignment();
+    SequenceI s = al.getSequenceAt(0);
+    AlignmentPanel ap = af.alignPanel;
+
+    // set width manually
+    av.setIdWidth(manualWidth);
+    ap.validateAnnotationDimensions(false);
+    ap.paintAlignment(true, false);
+    ap.getIdPanel().getIdCanvas().setManuallyAdjusted(true);
+
+    idWidth = av.getIdWidth();
+    assertEquals(idWidth, manualWidth,
+            "idWidth is not set to the manually set width " + manualWidth);
+
+    File structureFile = new File(structureFilename);
+    File paeFile = new File(paeFilename);
+
+    StructureViewer sv = StructureChooser.openStructureFileForSequence(null,
+            null, ap, s, false, structureFile.getAbsolutePath(),
+            temperatureFactorType, paeFile.getAbsolutePath(), false,
+            secondaryStructureView, false, viewerType);
+
+    idWidth = ap.getIdPanel().getWidth();// av.getIdWidth();
+    idWidth = av.getIdWidth();
+    assertEquals(idWidth, manualWidth,
+            "idWidth is not set to the manually set width " + manualWidth
+                    + " after adding structure annotations");
+    assertFalse(idWidth > idWidth2min,
+            "idWidth (" + idWidth + ") is greater than " + idWidth2min);
+  }
+
+  @DataProvider(name = "openFilesWithIdWidthChanges")
+  public Object[][] openFilesWithIdWidthChanges()
+  {
+    /*
+      String alignmentFilename,
+      boolean wrap,
+      int idWidth1min,
+      int idWidth1max,
+      int manualWidth, // ignored by testIdWidthChanges()
+      String structureFilename,
+      String paeFilename,
+      boolean secondaryStructureView,
+      TFType temperatureFactorType,
+      ViewerType viewerType,
+      int idWidth2min,
+      int idWidth2max,
+     */
+    return new Object[][] {
+        //
+        /*
+         */
+        { "./test/files/annotation_label_width/sample.a2m", false, 50, 70,
+            100,
+            "./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb",
+            "./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3_scores.json",
+            true, TFType.PLDDT, null, 115, 130 },
+        { "./test/files/annotation_label_width/sample.a2m", true, 50, 70,
+            100,
+            "./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb",
+            "./examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3_scores.json",
+            true, TFType.PLDDT, null, 115, 130 },
+        /*
+         */
+    };
+  }
+
+}
index 897f28e..f8fdb63 100644 (file)
@@ -71,7 +71,7 @@ public class DesktopTests
      * use read-only test properties file
      */
     Cache.loadProperties("test/jalview/io/testProps.jvprops");
-    Jalview.main(new String[] { "-nonews" });
+    Jalview.main(new String[] { "--nonews" });
   }
 
   @AfterMethod(alwaysRun = true)
@@ -135,7 +135,7 @@ public class DesktopTests
     {
       Assert.fail("Unexpected exception " + x);
     }
-    AlignFrame[] alfs = Desktop.getAlignFrames();
+    AlignFrame[] alfs = Desktop.getDesktopAlignFrames();
     Assert.assertEquals("Expect just 2 alignment frames", 2, alfs.length);
     // internal paste should yield a new alignment window with shared dataset
     AlignmentI dataset = internalSource.getViewport().getAlignment()
index 1b988ec..7cc4cc1 100644 (file)
@@ -42,7 +42,10 @@ import jalview.datamodel.features.FeatureMatcher;
 import jalview.datamodel.features.FeatureMatcherSet;
 import jalview.datamodel.features.FeatureMatcherSetI;
 import jalview.io.DataSourceType;
+import jalview.io.FileFormat;
+import jalview.io.FileFormatI;
 import jalview.io.FileLoader;
+import jalview.io.IdentifyFile;
 import jalview.schemes.FeatureColour;
 import jalview.schemes.FeatureColourTest;
 import jalview.util.matcher.Condition;
@@ -57,7 +60,7 @@ public class FeatureSettingsTest
      * use read-only test properties file
      */
     Cache.loadProperties("test/jalview/io/testProps.jvprops");
-    Jalview.main(new String[] { "-nonews" });
+    Jalview.main(new String[] { "--nonews" });
   }
 
   @AfterMethod(alwaysRun = true)
@@ -278,4 +281,13 @@ public class FeatureSettingsTest
             "<html>By Score (&gt; 4.0)<br>" + simpleTooltip
                     + "</br></html>");
   }
+  String fsfile="<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?><ns2:JalviewUserColours schemeName=\"Sequence Features\" xmlns:ns2=\"www.jalview.org/colours\">",fsfile2="<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<ns2:JalviewUserColours schemeName=\"Sequence Features\" xmlns:ns2=\"www.jalview.org/colours\">";
+  @Test(groups="Functional")
+  public void testIdentifyFeatureSettingsFile() throws Exception
+  {
+    FileFormatI type = new IdentifyFile().identify(fsfile, DataSourceType.PASTE);
+    assertTrue(FileFormat.FeatureSettings==type,"Feature settings file was identified as "+type);
+    type = new IdentifyFile().identify(fsfile2, DataSourceType.PASTE);
+    assertTrue(FileFormat.FeatureSettings==type,"Feature settings file with newline was identified as "+type);
+  }
 }
index a9eca49..475af2f 100644 (file)
@@ -120,7 +120,7 @@ public class FreeUpMemoryTest
   {
     Jalview.main(
             new String[]
-            { "-nonews", "-props", "test/jalview/testProps.jvprops" });
+            { "--nonews", "--props", "test/jalview/testProps.jvprops" });
     String True = Boolean.TRUE.toString();
     Cache.applicationProperties.setProperty("SHOW_ANNOTATIONS", True);
     Cache.applicationProperties.setProperty("SHOW_QUALITY", True);
index b19f160..a6a9642 100644 (file)
@@ -55,7 +55,7 @@ public class QuitHandlerTest
 
     Jalview.main(
             new String[]
-            { "-nowebservicediscovery", "-nosplash", "-nonews" });
+            { "--nowebservicediscovery", "--nosplash", "--nonews" });
   }
 
   @AfterClass(alwaysRun = true)
index 446c6ad..20e72b9 100644 (file)
@@ -64,6 +64,10 @@ public class ScalePanelTest
     ScalePanel scalePanel = alignFrame.alignPanel.getScalePanel();
 
     MouseEvent mouse = new MouseEvent(scalePanel, 0, 1, 0, 4, 0, 1, false);
+    
+    // check the bounded lookup is not returning negatives
+    assertEquals(alignFrame.alignPanel.getSeqPanel().findAlignmentColumn(mouse),0);
+    
     scalePanel.mousePressed(mouse);
     scalePanel.mouseDragged(mouse);
 
@@ -252,7 +256,7 @@ public class ScalePanelTest
      * use read-only test properties file
      */
     Cache.loadProperties("test/jalview/io/testProps.jvprops");
-    Jalview.main(new String[] { "-nonews" });
+    Jalview.main(new String[] { "--nonews" });
   }
 
 }
index 701431b..d47df46 100644 (file)
@@ -789,7 +789,7 @@ public class SeqPanelTest
   }
 
   @Test(groups = "Functional")
-  public void testFindColumn_wrapped()
+  public void testFindColumn_and_FindAlignmentColumn_wrapped()
   {
     Cache.applicationProperties.setProperty("WRAP_ALIGNMENT", "true");
     AlignFrame alignFrame = new FileLoader().LoadFileWaitTillLoaded(
@@ -811,6 +811,7 @@ public class SeqPanelTest
     MouseEvent evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0,
             x, 0, 0, 0, 0, false, 0);
     assertEquals(testee.findColumn(evt), 0);
+    assertEquals(testee.findAlignmentColumn(evt), 0);
 
     /*
      * not quite one charWidth across
@@ -819,6 +820,7 @@ public class SeqPanelTest
     evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0, x, 0, 0, 0,
             0, false, 0);
     assertEquals(testee.findColumn(evt), 0);
+    assertEquals(testee.findAlignmentColumn(evt), 0);
 
     /*
      * one charWidth across
@@ -827,6 +829,7 @@ public class SeqPanelTest
     evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0, x, 0, 0, 0,
             0, false, 0);
     assertEquals(testee.findColumn(evt), 1);
+    assertEquals(testee.findAlignmentColumn(evt), 1);
 
     /*
      * x over scale left (before drawn columns) results in -1
@@ -840,11 +843,15 @@ public class SeqPanelTest
     evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0, x, 0, 0, 0,
             0, false, 0);
     assertEquals(testee.findColumn(evt), -1);
+    assertEquals(testee.findAlignmentColumn(evt), 0);
+
 
     x = labelWidth;
     evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0, x, 0, 0, 0,
             0, false, 0);
     assertEquals(testee.findColumn(evt), 0);
+    assertEquals(testee.findAlignmentColumn(evt), 0);
+
 
     /*
      * x over right edge of last residue (including scale left)
@@ -855,6 +862,8 @@ public class SeqPanelTest
     evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0, x, 0, 0, 0,
             0, false, 0);
     assertEquals(testee.findColumn(evt), residuesWide - 1);
+    assertEquals(testee.findAlignmentColumn(evt), residuesWide-1);
+
 
     /*
      * x over scale right (beyond drawn columns) results in -1
@@ -869,7 +878,11 @@ public class SeqPanelTest
     x += 1; // just over left edge of scale right
     evt = new MouseEvent(testee, MouseEvent.MOUSE_MOVED, 0L, 0, x, 0, 0, 0,
             0, false, 0);
+    // on scale
     assertEquals(testee.findColumn(evt), -1);
+    // return right-most column visible
+    assertEquals(testee.findAlignmentColumn(evt), residuesWide2-1);
+
 
     // todo add startRes offset, hidden columns
 
@@ -882,7 +895,7 @@ public class SeqPanelTest
      * use read-only test properties file
      */
     Cache.loadProperties("test/jalview/io/testProps.jvprops");
-    Jalview.main(new String[] { "-nonews" });
+    Jalview.main(new String[] { "--nonews" });
   }
 
   /**
index 9b49232..bf78c85 100644 (file)
@@ -51,7 +51,7 @@ public class SequenceRendererTest
   {
     Jalview.main(
             new String[]
-            { "-nonews", "-props", "test/jalview/testProps.jvprops" });
+            { "--nonews", "--props", "test/jalview/testProps.jvprops" });
   }
 
   @BeforeMethod(alwaysRun = true)
index c21add1..4579b9c 100644 (file)
@@ -22,7 +22,9 @@ package jalview.gui.structurechooser;
 
 import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertTrue;
+import static org.testng.Assert.fail;
 
+import java.util.ArrayList;
 import java.util.List;
 import java.util.Vector;
 
@@ -39,8 +41,13 @@ import jalview.datamodel.DBRefSource;
 import jalview.datamodel.PDBEntry;
 import jalview.datamodel.Sequence;
 import jalview.datamodel.SequenceI;
+import jalview.fts.api.FTSData;
+import jalview.fts.api.FTSDataColumnI;
+import jalview.fts.core.FTSRestRequest;
 import jalview.fts.core.FTSRestResponse;
 import jalview.fts.service.pdb.PDBFTSRestClientTest;
+import jalview.fts.service.threedbeacons.TDB_FTSData;
+import jalview.fts.service.threedbeacons.TDBeaconsFTSRestClient;
 import jalview.fts.threedbeacons.TDBeaconsFTSRestClientTest;
 import jalview.gui.JvOptionPane;
 import jalview.gui.StructureChooser;
@@ -60,6 +67,8 @@ public class StructureChooserQuerySourceTest
 
   private Sequence upSeq_fer1_maize;
 
+  private Sequence upSeq_epas1_human;
+
   // same set up as for structurechooser test
 
   @BeforeMethod(alwaysRun = true)
@@ -237,7 +246,24 @@ public class StructureChooserQuerySourceTest
     upSeq_fer1_maize
             .addDBRef(new DBRefEntry("UNIPROT", "0", "P27787", null, true));
     upSeq_fer1_maize.createDatasetSequence();
-
+    
+    upSeq_epas1_human = new Sequence("EPAS1_HUMAN","MTADKEKKRSSSERRKEKSRDAARCRRSKETEVFYELAHELPLPHSVSSHLDKASIMRLAISFLRTHKLLSS\n"
+            + "VCSENESEAEADQQMDNLYLKALEGFIAVVTQDGDMIFLSENISKFMGLTQVELTGHSIFDFTHPCDHEEIR\n"
+            + "ENLSLKNGSGFGKKSKDMSTERDFFMRMKCTVTNRGRTVNLKSATWKVLHCTGQVKVYNNCPPHNSLCGYKE\n"
+            + "PLLSCLIIMCEPIQHPSHMDIPLDSKTFLSRHSMDMKFTYCDDRITELIGYHPEELLGRSAYEFYHALDSEN\n"
+            + "MTKSHQNLCTKGQVVSGQYRMLAKHGGYVWLETQGTVIYNPRNLQPQCIMCVNYVLSEIEKNDVVFSMDQTE\n"
+            + "SLFKPHLMAMNSIFDSSGKGAVSEKSNFLFTKLKEEPEELAQLAPTPGDAIISLDFGNQNFEESSAYGKAIL\n"
+            + "PPSQPWATELRSHSTQSEAGSLPAFTVPQAAAPGSTTPSATSSSSSCSTPNSPEDYYTSLDNDLKIEVIEKL\n"
+            + "FAMDTEAKDQCSTQTDFNELDLETLAPYIPMDGEDFQLSPICPEERLLAENPQSTPQHCFSAMTNIFQPLAP\n"
+            + "VAPHSPFLLDKFQQQLESKKTEPEHRPMSSIFFDAGSKASLPPCCGQASTPLSSMGGRSNTQWPPDPPLHFG\n"
+            + "PTKWAVGDQRTEFLGAAPLGPPVSPPHVSTFKTRSAKGFGARGPDVLSPAMVALSNKLKLKRQLEYEEQAFQ\n"
+            + "DLSGGDPPGGSTSHLMWKRMKNLRGGSCPLMPDKPLSANVPNDKFTQNPMRGLGHPLRHLPLPQPPSAISPG\n"
+            + "ENSKSRFPPQCYATQYQDYSLSSAHKVSGMASRLLGPSFESYLLPELTRYDCEVNVPVLGSSTLLQGGDLLR\n"
+            + "ALDQAT");
+    upSeq_epas1_human.setDescription("Endothelial PAS domain-containing protein 1");
+    upSeq_epas1_human
+    .addDBRef(new DBRefEntry("UNIPROT", "0", "Q99814", null, true));
+    upSeq_epas1_human.createDatasetSequence();
   }
 
   @AfterMethod(alwaysRun = true)
@@ -247,6 +273,7 @@ public class StructureChooserQuerySourceTest
     upSeq = null;
     upSeq_r1ab = null;
     upSeq_fer1_maize = null;
+    upSeq_epas1_human=null;
   }
 
   @SuppressWarnings("deprecation")
@@ -438,6 +465,31 @@ public class StructureChooserQuerySourceTest
               pdbResponse);
       assertEquals(upResponse.getNumberOfItemsFound(),
               joinedResp.getNumberOfItemsFound());
+      
+      // Special data test case
+      if (testUpSeq.getDisplayId(true)
+              .equals(upSeq_epas1_human.getDisplayId(true)))
+      {
+
+        TDBResultAnalyser tDBResultAnalyz = new TDBResultAnalyser(testUpSeq,
+                joinedResp.getSearchSummary(), tdbquery.lastTdbRequest,
+                ThreeDBStructureChooserQuerySource.FILTER_FIRST_BEST_COVERAGE,
+                tdbquery.remove_prefix(
+                        ThreeDBStructureChooserQuerySource.FILTER_FIRST_BEST_COVERAGE));
+        List<FTSData> ordered = tDBResultAnalyz.getFilteredResponse();
+        List<FTSData> selected = tDBResultAnalyz.selectStructures(ordered);
+        assertEquals(((TDB_FTSData) selected.get(0)).getProvider(),
+                "AlphaFold DB");
+        // to be sufficient, should also
+        // test that adjacent ordered structure in ordered is levyLab
+        // TDB_FTSData first = (TDB_FTSData) ordered.get(0),
+        // second = (TDB_FTSData) ordered.get(1),
+        // third = (TDB_FTSData) ordered.get(2);
+        // Assert.assertEquals("pLDDT", first.getConfidenceScoreType());
+        // Assert.assertTrue(first.getConfidenceScoreType()
+        // .equals(second.getConfidenceScoreType())); // pLDDT first and
+        // // second
+      }
 
     } catch (
 
@@ -458,7 +510,7 @@ public class StructureChooserQuerySourceTest
   {
     setUp();
     return new Object[][] { { upSeq }, { upSeq_insulin }, { upSeq_r1ab },
-        { upSeq_fer1_maize } };
+        { upSeq_fer1_maize },{upSeq_epas1_human} };
   }
 
   @Test(groups = { "Functional" })
@@ -481,5 +533,5 @@ public class StructureChooserQuerySourceTest
     name = "abcde12[345a]fg";
     AssertJUnit.assertEquals("abcde12345afg",
             PDBStructureChooserQuerySource.sanitizeSeqName(name));
-  }
+  }  
 }
index 1b62ce3..e369a02 100644 (file)
@@ -199,7 +199,7 @@ public class AnnotatedPDBFileInputTest
   {
     jalview.bin.Jalview
             .main(new String[]
-            { "-props", "test/jalview/io/testProps.jvprops" });
+            { "--props", "test/jalview/io/testProps.jvprops" });
   }
 
   /**
index c46477a..34cc17f 100644 (file)
@@ -186,7 +186,7 @@ public class CrossRef2xmlTests extends Jalview2xmlBase
         SequenceFetcher sf = new SequenceFetcher(Desktop.instance,
                 forSource, forAccession);
         sf.run();
-        AlignFrame[] afs = Desktop.getAlignFrames();
+        AlignFrame[] afs = Desktop.getDesktopAlignFrames();
         if (afs.length == 0)
         {
           failedDBRetr.add("Didn't retrieve " + first);
index 59c5986..29af915 100644 (file)
@@ -56,7 +56,7 @@ public class JalviewExportPropertiesTests
   {
     jalview.bin.Jalview
             .main(new String[]
-            { "-props", "test/jalview/io/testProps.jvprops" });
+            { "--props", "test/jalview/io/testProps.jvprops" });
   }
 
   /**
index bb5d1c4..9391eb1 100644 (file)
@@ -432,8 +432,7 @@ public class SequenceAnnotationReportTest
     assertTrue(report.startsWith("<i>\n" + "<br/>\n" + "UNIPROT P30410,\n"
             + " P30411,\n" + " P30412,\n" + " P30413,...<br/>\n"
             + "PDB0 3iu1<br/>\n" + "PDB1 3iu1<br/>"));
-    assertTrue(report.endsWith("PDB5 3iu1<br/>\n" + "PDB6 3iu1<br/>\n"
-            + "PDB7 3iu1<br/>\n" + "PDB8,...<br/>\n"
+    assertTrue(report.endsWith("PDB3 3iu1<br/>\n"+"PDB4,...<br/>\n"
             + "(Output Sequence Details to list all database references)\n"
             + "</i>"));
   }
index 288444e..ce34044 100644 (file)
@@ -45,7 +45,7 @@ public class JvCacheableInputBoxTest
     appCache = AppCache.getInstance();
   }
 
-  @Test(groups = { "Functional" })
+  @Test(groups = { "Functional", "testTask2" })
   public void getUserInputTest()
   {
     String userInput = cacheBox.getUserInput();
@@ -84,24 +84,28 @@ public class JvCacheableInputBoxTest
     cacheBox.addItem(testInput);
     cacheBox.setSelectedItem(testInput);
     cacheBox.updateCache();
-
-    try
+    boolean done[]=new boolean[] { false };
+    // this event gets processed after updateCache's update event on the swing
+    // thread
+    SwingUtilities.invokeLater(() -> {
+        done[0]=true;
+    });
+    long t=0;
+    while (!done[0] && t<200)
     {
-      // fix for JAL-4153
-      // This delay is to let cacheBox.updateCache() finish updating the cache
-      SwingUtilities.invokeAndWait(() -> {
-        try
-        {
-          Thread.sleep(1);
+      try {
+        Thread.sleep(7);
+        t++;
         } catch (InterruptedException e)
         {
           e.printStackTrace();
         }
-      });
-    } catch (InvocationTargetException | InterruptedException e)
+    }
+    if (!done[0])
     {
-      e.printStackTrace();
+      Assert.fail("Giving up after 1.4s waiting for cache to be updated.");
     }
+    
     LinkedHashSet<String> foundCache = appCache
             .getAllCachedItemsFor(TEST_CACHE_KEY);
     Assert.assertTrue(foundCache.contains(testInput));
index c9532cc..ebd265a 100644 (file)
@@ -47,6 +47,7 @@ import org.testng.AssertJUnit;
 import org.testng.annotations.BeforeClass;
 import org.testng.annotations.Test;
 
+import jalview.analysis.AlignmentUtils;
 import jalview.analysis.scoremodels.SimilarityParams;
 import jalview.api.AlignViewportI;
 import jalview.api.AlignmentViewPanel;
@@ -66,6 +67,7 @@ import jalview.datamodel.HiddenSequences;
 import jalview.datamodel.Mapping;
 import jalview.datamodel.PDBEntry;
 import jalview.datamodel.PDBEntry.Type;
+import jalview.datamodel.Sequence;
 import jalview.datamodel.Sequence.DBModList;
 import jalview.datamodel.SequenceCollectionI;
 import jalview.datamodel.SequenceFeature;
@@ -100,6 +102,7 @@ import jalview.schemes.StrandColourScheme;
 import jalview.schemes.TCoffeeColourScheme;
 import jalview.structure.StructureImportSettings;
 import jalview.util.MapList;
+import jalview.util.Platform;
 import jalview.util.matcher.Condition;
 import jalview.viewmodel.AlignmentViewport;
 import jalview.viewmodel.seqfeatures.FeatureRendererModel;
@@ -287,12 +290,12 @@ public class Jalview2xmlTests extends Jalview2xmlBase
   @Test(groups = { "Functional" })
   public void gatherViewsHere() throws Exception
   {
-    int origCount = Desktop.getAlignFrames() == null ? 0
-            : Desktop.getAlignFrames().length;
+    int origCount = Desktop.getDesktopAlignFrames() == null ? 0
+            : Desktop.getDesktopAlignFrames().length;
     AlignFrame af = new FileLoader().LoadFileWaitTillLoaded(
             "examples/exampleFile_2_7.jar", DataSourceType.FILE);
     assertNotNull(af, "Didn't read in the example file correctly.");
-    assertTrue(Desktop.getAlignFrames().length == 1 + origCount,
+    assertTrue(Desktop.getDesktopAlignFrames().length == 1 + origCount,
             "Didn't gather the views in the example file.");
 
   }
@@ -430,7 +433,7 @@ public class Jalview2xmlTests extends Jalview2xmlBase
 
     AlignFrame af = new FileLoader().LoadFileWaitTillLoaded(
             "examples/exampleFile_2_7.jar", DataSourceType.FILE);
-    Assert.assertEquals(Desktop.getAlignFrames().length, 1);
+    Assert.assertEquals(Desktop.getDesktopAlignFrames().length, 1);
     String afid = af.getViewport().getSequenceSetId();
 
     // check FileLoader returned a reference to the one alignFrame that is
@@ -440,8 +443,8 @@ public class Jalview2xmlTests extends Jalview2xmlBase
 
     Desktop.explodeViews(af);
 
-    int oldviews = Desktop.getAlignFrames().length;
-    Assert.assertEquals(Desktop.getAlignFrames().length,
+    int oldviews = Desktop.getDesktopAlignFrames().length;
+    Assert.assertEquals(Desktop.getDesktopAlignFrames().length,
             Desktop.getAlignmentPanels(afid).length);
     File tfile = File.createTempFile("testStoreAndRecoverExpanded", ".jvp");
     try
@@ -455,14 +458,14 @@ public class Jalview2xmlTests extends Jalview2xmlBase
       Assert.fail("Didn't save the expanded view state", e);
     }
     Desktop.instance.closeAll_actionPerformed(null);
-    if (Desktop.getAlignFrames() != null)
+    if (Desktop.getDesktopAlignFrames() != null)
     {
-      Assert.assertEquals(Desktop.getAlignFrames().length, 0);
+      Assert.assertEquals(Desktop.getDesktopAlignFrames().length, 0);
     }
     af = new FileLoader().LoadFileWaitTillLoaded(tfile.getAbsolutePath(),
             DataSourceType.FILE);
     Assert.assertNotNull(af);
-    Assert.assertEquals(Desktop.getAlignFrames().length,
+    Assert.assertEquals(Desktop.getDesktopAlignFrames().length,
             Desktop.getAlignmentPanels(
                     af.getViewport().getSequenceSetId()).length);
     Assert.assertEquals(Desktop
@@ -519,9 +522,9 @@ public class Jalview2xmlTests extends Jalview2xmlBase
       Assert.fail("Didn't save the expanded view state", e);
     }
     Desktop.instance.closeAll_actionPerformed(null);
-    if (Desktop.getAlignFrames() != null)
+    if (Desktop.getDesktopAlignFrames() != null)
     {
-      Assert.assertEquals(Desktop.getAlignFrames().length, 0);
+      Assert.assertEquals(Desktop.getDesktopAlignFrames().length, 0);
     }
 
     af = new FileLoader().LoadFileWaitTillLoaded(tfile.getAbsolutePath(),
@@ -698,9 +701,9 @@ public class Jalview2xmlTests extends Jalview2xmlBase
       Assert.fail("Didn't save the expanded view state", e);
     }
     Desktop.instance.closeAll_actionPerformed(null);
-    if (Desktop.getAlignFrames() != null)
+    if (Desktop.getDesktopAlignFrames() != null)
     {
-      Assert.assertEquals(Desktop.getAlignFrames().length, 0);
+      Assert.assertEquals(Desktop.getDesktopAlignFrames().length, 0);
     }
 
     af = new FileLoader().LoadFileWaitTillLoaded(tfile.getAbsolutePath(),
@@ -792,9 +795,9 @@ public class Jalview2xmlTests extends Jalview2xmlBase
       Assert.fail("Didn't save the state", e);
     }
     Desktop.instance.closeAll_actionPerformed(null);
-    if (Desktop.getAlignFrames() != null)
+    if (Desktop.getDesktopAlignFrames() != null)
     {
-      Assert.assertEquals(Desktop.getAlignFrames().length, 0);
+      Assert.assertEquals(Desktop.getDesktopAlignFrames().length, 0);
     }
 
     AlignFrame restoredFrame = new FileLoader().LoadFileWaitTillLoaded(
@@ -1217,7 +1220,7 @@ public class Jalview2xmlTests extends Jalview2xmlBase
     assertNotNull(af);
 
     AlignmentI ds = null;
-    for (AlignFrame alignFrame : Desktop.getAlignFrames())
+    for (AlignFrame alignFrame : Desktop.getDesktopAlignFrames())
     {
       if (ds == null)
       {
@@ -1546,6 +1549,44 @@ public class Jalview2xmlTests extends Jalview2xmlBase
   }
 
   @Test(groups = { "Functional" })
+  public void testMatrixToFloatsAndBack()
+  {
+    int imax=2000;
+    int i=imax;
+    SequenceI sq = new Sequence("dummy","SEQ");
+    while (sq.getLength()<i)
+    {
+      sq.setSequence(sq.getSequenceAsString()+'Q');
+    }
+    float[][] paevals = new float[i][i];
+    for (i = imax - 1; i >= 0; i--)
+    {
+      for (int j = 0; j <= i; j++)
+      {
+        paevals[i][j] = ((i - j < 2)
+                || ((i > 1 && i < 5) && (j > 1 && i < 5))) ? 1 : 0f;
+        paevals[j][i] = -paevals[i][j];
+      }
+    }
+    PAEContactMatrix dummyMat = new PAEContactMatrix(sq, paevals);
+    String content = ContactMatrix.contactToFloatString(dummyMat);
+    Assert.assertTrue(content.contains("\t1.")); // at least one element must be
+                                                 // 1
+    float[][] vals = ContactMatrix.fromFloatStringToContacts(content,
+            sq.getLength(), sq.getLength());
+    assertEquals(vals[3][4], paevals[3][4]);
+    assertEquals(vals[4][3], paevals[4][3]);
+    
+    // test recovery
+    for (i=0;i<imax;i++)
+    {
+      for (int j=0;j<imax;j++)
+      {
+        assertEquals(vals[i][j],paevals[i][j]);
+      }
+    }
+  }
+  @Test(groups = { "Functional" })
   public void testPAEsaveRestore() throws Exception
   {
     Desktop.instance.closeAll_actionPerformed(null);
@@ -1646,6 +1687,120 @@ public class Jalview2xmlTests extends Jalview2xmlBase
     Assert.assertEquals(restoredMat.getGroups(), dummyMat.getGroups());
     Assert.assertEquals(restoredMat.hasTree(), dummyMat.hasTree());
     Assert.assertEquals(restoredMat.getNewick(), dummyMat.getNewick());
+
+    // verify no duplicate PAE matrix data when new view created and saved
+    
+    // add reference annotations to view first, then copy
+    AlignmentUtils.addReferenceAnnotationTo(newAl, newAl.getSequenceAt(0), newSeq.getAnnotation()[0],null);
+    
+    AlignmentViewPanel newview = af.newView("copy of PAE", true);
+    
+    // redundant asserts here check all is good with the new view firest...
+    AlignmentI newviewAl = newview.getAlignment();
+    SequenceI newviewSeq = newviewAl.getSequenceAt(0);
+    // check annotation of the expected type exists
+    Assert.assertEquals(newviewSeq.getAnnotation().length, 1);
+    Assert.assertEquals(newviewSeq.getAnnotation()[0].graph, paeCm.graph);
+    // check we have just one contact matrix mapping
+    Assert.assertEquals(newviewSeq.getContactMaps().size(), 1);
+    
+    // and can be found for the annotation on the sequence
+    ContactMatrixI newviewMat = newviewSeq
+            .getContactMatrixFor(newviewSeq.getAnnotation()[0]);
+    Assert.assertNotNull(newviewMat);
+
+    Assert.assertTrue(newviewMat == restoredMat);
+    
+    // save the two views and restore. Now look at visible annotation to check all views have shared refs.
+    
+    tfile = File.createTempFile("testStoreAndRecoverPAEmatrixTwoViews",
+            ".jvp");
+    new Jalview2XML(false).saveState(tfile);
+    Desktop.instance.closeAll_actionPerformed(null);
+
+    af = new FileLoader().LoadFileWaitTillLoaded(tfile.getAbsolutePath(),
+            DataSourceType.FILE);
+    newAl = af.getAlignPanels().get(0).getAlignment();
+    AlignmentAnnotation view1aa = newAl.getSequenceAt(0).getAnnotation()[0];
+
+    newviewAl = af.getAlignPanels().get(1).getAlignment();
+    AlignmentAnnotation view2aa = newviewAl.getSequenceAt(0).getAnnotation()[0];
+
+    // annotations are shared across alignment views - so should still have an identical pair of annotations.
+    Assert.assertTrue(view1aa==view2aa);
+    // identical annotations means identical contact matrix mappings
+    Assert.assertEquals(newAl.getDataset().getSequenceAt(0).getContactMaps().size(), 1);
+
+    // TODO Verify when distinct mappable PAEs are created, only one PAE dataset is actually held.
+    // Assert.assertTrue(view1aa!=view2aa);
+    // restoredMat = newAl.getContactMatrixFor(view1aa);
+    // newviewMat = newviewAl.getContactMatrixFor(view2aa);
+    // Assert.assertTrue(restoredMat!=newviewMat);
+    
+  }
+
+  @Test(groups = "Functional")
+  public void testStoreAndRestoreIDwidthAndAnnotationHeight() throws IOException
+  {
+    Desktop.instance.closeAll_actionPerformed(null);
+    final String SECONDVIEW = "With Diffferent IDwidth";
+    // create a new tempfile
+    File tempfile = File.createTempFile("jvIdWidthStoreRestore", "jvp");
+
+
+    AlignFrame af = new FileLoader().LoadFileWaitTillLoaded("examples/exampleFile.jvp",
+              DataSourceType.FILE);
+      assertNotNull(af, "Didn't read in the example file correctly.");
+      // FIXME JAL-4281 test made platform dependent to pass, but probably shouldn't be platform dependent
+      assertEquals(af.alignPanel.getAlignViewport().getIdWidth(), Platform.isAMacAndNotJS() ? 144 : 138,
+              "Legacy project import should have fixed ID width");
+      assertTrue(af.alignPanel.getIdPanel().getIdCanvas().isManuallyAdjusted());
+      
+      
+      af.alignPanel.getAlignViewport().setIdWidth(100);
+      af.alignPanel.updateLayout();
+      assertTrue(af.alignPanel.getIdPanel().getIdCanvas().isManuallyAdjusted());
+      
+      Jalview2XML jv2xml = new jalview.project.Jalview2XML(false);
+      tempfile.delete();
+      jv2xml.saveState(tempfile);
+      assertTrue(jv2xml.errorMessage == null,
+              "Failed to save dummy project with PCA: test broken");
+      af = null;
+      // load again.
+      Desktop.instance.closeAll_actionPerformed(null);
+      af = new FileLoader().LoadFileWaitTillLoaded(
+              tempfile.getCanonicalPath(), DataSourceType.FILE);
+      assertTrue(af.alignPanel.getIdPanel().getIdCanvas()
+              .isManuallyAdjusted());
+      assertEquals(af.alignPanel.getAlignViewport().getIdWidth(), 100,
+              "New project exported and import should have adjusted ID width");
+
+      af.alignPanel.getAlignViewport().setIdWidth(100);
+      af.alignPanel.updateLayout();
+      assertTrue(af.alignPanel.getIdPanel().getIdCanvas().isManuallyAdjusted());
+      
+      // now make it autoadjusted
+      af.alignPanel.getAlignViewport().setIdWidth(-1);
+      af.alignPanel.getIdPanel().getIdCanvas().setManuallyAdjusted(false);
+      af.alignPanel.updateLayout();
+      assertFalse(af.alignPanel.getIdPanel().getIdCanvas().isManuallyAdjusted());
+      assertTrue(af.alignPanel.getAlignViewport().getIdWidth()>-1,
+              "New project exported and import should have adjusted ID width");
+      
+      jv2xml = new jalview.project.Jalview2XML(false);
+      tempfile.delete();
+      jv2xml.saveState(tempfile);
+      assertTrue(jv2xml.errorMessage == null,
+              "Failed to save dummy project with PCA: test broken");
+      af = null;
+      // load again.
+      Desktop.instance.closeAll_actionPerformed(null);
+      af = new FileLoader().LoadFileWaitTillLoaded(
+              tempfile.getCanonicalPath(), DataSourceType.FILE);
+      assertFalse(af.alignPanel.getIdPanel().getIdCanvas().isManuallyAdjusted());
+      assertTrue(af.alignPanel.getAlignViewport().getIdWidth()>-1,
+              "New project exported and import should have adjusted ID width");
   }
 
 }
diff --git a/test/jalview/renderer/ContactGeometryTest.java b/test/jalview/renderer/ContactGeometryTest.java
new file mode 100644 (file)
index 0000000..6e38e89
--- /dev/null
@@ -0,0 +1,176 @@
+/*
+ * 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 
+ * 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 
+ * 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 <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
+ */
+package jalview.renderer;
+
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertFalse;
+import static org.testng.Assert.assertNotEquals;
+import static org.testng.Assert.assertNotNull;
+import static org.testng.Assert.assertTrue;
+
+import org.testng.annotations.Test;
+
+import jalview.datamodel.AlignmentAnnotation;
+import jalview.datamodel.ColumnSelection;
+import jalview.datamodel.ContactListI;
+import jalview.datamodel.ContactRange;
+import jalview.datamodel.Mapping;
+import jalview.datamodel.SeqDistanceContactMatrix;
+import jalview.datamodel.Sequence;
+import jalview.datamodel.SequenceI;
+import jalview.util.MapList;
+import jalview.util.StringUtils;
+import jalview.ws.datamodel.MappableContactMatrixI;
+
+public class ContactGeometryTest
+{
+  @Test(groups="Functional")
+  public void testCoverageofRange()
+  {
+    // a really dumb test to make sure we really cover the requested pixel and
+    // contactList range for any dimension of each
+    for (int range = 12; range < 2000; range += 35)
+    {
+      StringBuilder sb = new StringBuilder();
+      while (sb.length() < range)
+      {
+        sb.append("c");
+      }
+      SequenceI sq = new Sequence("a", sb.toString());
+      MappableContactMatrixI cm = new SeqDistanceContactMatrix(range);
+      AlignmentAnnotation cm_aan = sq.addContactList(cm);
+      ContactListI cl = sq.getContactListFor(cm_aan, 10);
+      assertNotNull(cl);
+      for (int ht = range / 2; ht < range * 3; ht++)
+      {
+        ContactGeometry clgeom = new ContactGeometry(cl, ht);
+        assertNotNull(clgeom.allSteps());
+      }
+    }
+  }
+  @Test(groups = "Functional")
+  public void testContactGeometry()
+  {
+    SequenceI sq = new Sequence("a", "SSSQ");
+    MappableContactMatrixI cm = new SeqDistanceContactMatrix(4);
+    AlignmentAnnotation cm_aan = sq.addContactList(cm);
+    checkConsistencyFor(sq,cm_aan);
+    // Also check all is good when there's a sequence mapping involved
+    MappableContactMatrixI newcm=cm.liftOver(sq,
+            new Mapping(sq, new MapList(new int[]
+            { 1, 4 }, new int[] { 1, 4 }, 1, 1)));
+    AlignmentAnnotation mapped_cm = sq.addContactList(newcm);
+    checkConsistencyFor(sq,mapped_cm);    
+  }
+  // Do some asserts for a sequence and a contact matrix
+  private void checkConsistencyFor(SequenceI sq, AlignmentAnnotation cm_aan)
+  {
+    int col=1;
+    ContactListI cl = sq.getContactListFor(cm_aan, col);
+    assertNotNull(cl);
+    assertEquals(cl.getContactHeight(),4);
+    
+    // Map contacts 0 to 3 to a tiny range and check    
+    ContactGeometry  testee = new ContactGeometry(cl,2);
+    assertEquals(testee.contacts_per_pixel,2d);
+    ContactGeometry.contactInterval lastInterval = testee.mapFor(1);
+    assertEquals(lastInterval.cStart,2);
+    assertEquals(lastInterval.cEnd,3);
+    assertEquals(lastInterval.pStart,1);
+    assertEquals(lastInterval.pEnd,1);
+    ContactGeometry.contactInterval another = testee.mapFor(1,2); 
+    assertEquals(lastInterval,another);
+    // Also check for a big pixel range
+    testee = new ContactGeometry(cl, 395);
+    lastInterval = testee.mapFor(390, 395); // 395 is one over limit.
+    assertNotNull(lastInterval);
+    assertEquals(lastInterval.cEnd,3);
+    assertEquals(lastInterval.pEnd,394);
+    // Map contacts 0 to 3 to Pixels 0-9, 10-19, 20-29, 30-39
+    testee = new ContactGeometry(cl, 40);
+
+    // verify mapping from pixel to contacts
+    
+    // renderer thinks base 0 for pixel coordinates
+    // contact coordinates are base 1
+    for (int p = 0; p < 40; p++)
+    {
+      int expectC=(p / 10);
+      int expectP=(expectC)*10;
+      ContactGeometry.contactInterval ci_at = testee.mapFor(p),
+              ci_from = testee.mapFor(p, p);
+      assertNotNull(ci_at);
+      // mapFor and map should locate the same pixel window
+      assertEquals(ci_at.cStart, expectC,"Different cStart at position "+p);
+      assertEquals(ci_at.cEnd, expectC,"Different cEnd at position "+p);
+      assertEquals(ci_at.pStart,expectP, "Different pStart at position "+p);
+      assertEquals(ci_at.pEnd,expectP+9, "Different pEnd at position "+p);
+      
+      assertEquals(ci_from,ci_at, "Different contactIntervals at position "+p);
+      // also test getRangeFor
+      ContactRange cr = cl.getRangeFor(ci_at.cStart, ci_at.cEnd);
+      assertEquals(cr.getFrom_column(),cr.getTo_column());
+      assertEquals((double) cr.getMean(),(double)Math.abs(col-cr.getFrom_column()), "Didn't resolve expected value at position "+p);
+    }
+    
+    ContactGeometry.contactInterval ci_at0 = testee.mapFor(0);
+    ContactGeometry.contactInterval ci_at9 = testee.mapFor(9);
+    assertNotNull(ci_at9);
+    
+    assertEquals(ci_at0,ci_at9);
+
+    // Adjacent cell
+    ContactGeometry.contactInterval ci_at10 = testee.mapFor(10);
+    assertNotNull(ci_at10);
+    ContactGeometry.contactInterval ci_at11 = testee.mapFor(11);
+    assertNotNull(ci_at11);
+
+    assertEquals(ci_at11,ci_at10,"Off-by-one in ContactGeometry mapping.");
+
+    assertNotEquals(ci_at0,ci_at10,"Expected adjacent cells to be not equal.");
+    
+    // verify adjacent window is mapped
+    assertEquals(ci_at11.cStart,ci_at9.cStart+1);
+    
+    assertEquals(ci_at9.cEnd+1,ci_at11.cStart);
+    assertEquals(ci_at9.cEnd+1,ci_at11.cEnd);
+    
+    // verify interval/intersection
+    // column selection is base 0
+    ColumnSelection cs = new ColumnSelection();
+    cs.addElement(2);
+
+    boolean mask = false;
+    do
+    {
+      assertFalse(testee.intersects(ci_at0, cs, null, mask));
+      assertFalse(testee.intersects(ci_at11, cs, null, mask));
+      assertTrue(testee.intersects(testee.mapFor(21), cs, null, mask));
+      assertFalse(testee.intersects(testee.mapFor(31), cs, null, mask));
+      cs.addElement(3);
+      assertTrue(testee.intersects(testee.mapFor(31), cs, null, mask));
+      cs.removeElement(2);
+      assertFalse(testee.intersects(testee.mapFor(21), cs, null, mask));
+      mask = !mask;
+    } while (!mask);    
+    
+  }
+}
index 944f147..0472317 100644 (file)
@@ -625,7 +625,7 @@ public class FeatureRendererTest
   {
     Jalview.main(
             new String[]
-            { "-nonews", "-props", "test/jalview/testProps.jvprops" });
+            { "--nonews", "--props", "test/jalview/testProps.jvprops" });
 
     // codons for MCWHSE
     String cdsSeq = ">cds\nATGtgtTGGcacTCAgaa";
@@ -638,7 +638,7 @@ public class FeatureRendererTest
     /*
      * find the complement frames (ugly)
      */
-    AlignFrame[] frames = Desktop.getAlignFrames();
+    AlignFrame[] frames = Desktop.getDesktopAlignFrames();
     assertEquals(frames.length, 2);
     AlignViewport av1 = frames[0].getViewport();
     AlignViewport av2 = frames[1].getViewport();
index 0184f12..052bb8b 100644 (file)
@@ -186,7 +186,7 @@ public class ColourSchemesTest
      * use read-only test properties file
      */
     Cache.loadProperties("test/jalview/io/testProps.jvprops");
-    Jalview.main(new String[] { "-nonews" });
+    Jalview.main(new String[] { "--nonews" });
   }
 
   @AfterClass(alwaysRun = true)
index 35853b0..666b33b 100644 (file)
@@ -21,7 +21,6 @@
 package jalview.util;
 
 import java.io.File;
-import java.io.IOException;
 import java.util.List;
 
 import org.testng.Assert;
@@ -56,29 +55,26 @@ public class FileUtilsTest
   }
 
   @Test(groups = "Functional", dataProvider = "dirnamesAndBasenames")
-  public void testDirnamesAndBasenames(String filename, int where,
-          String dirname, String basename, String notInDirname)
+  public void testDirnamesAndBasenames(String filename, String dirname,
+          String endsWith, String basename, String notInDirname)
   {
     File file = new File(filename);
     String d = FileUtils.getDirname(file);
     String b = FileUtils.getBasename(file);
     Assert.assertEquals(b, basename);
-    if (where == 0)
-      Assert.assertEquals(d, dirname);
-    else if (where < 0)
-      Assert.assertTrue(d.startsWith(dirname),
-              "getDirname(" + file.getPath() + ")=" + d
-                      + " didn't start with '" + dirname + "'");
-    else if (where > 0)
-      Assert.assertTrue(d.endsWith(dirname), "getDirname(" + file.getPath()
-              + ")=" + d + " didn't end with '" + d + "'");
+    Assert.assertTrue(d.startsWith(dirname), "getDirname(" + file.getPath()
+            + ")=" + d + " didn't start with '" + dirname + "'");
+    Assert.assertTrue(d.endsWith(endsWith), "getDirname(" + file.getPath()
+            + ")=" + d + " didn't end with '" + endsWith + "'");
 
     // ensure dirname doesn't end with basename (which means you can't use same
     // filename as dir in tests!)
-    Assert.assertFalse(d.endsWith(b));
+    Assert.assertFalse(d.endsWith(b), "Processed dirname '" + d
+            + "' ends with '" + b + "' when it shouldn't");
 
     if (notInDirname != null)
-      Assert.assertFalse(d.contains(notInDirname));
+      Assert.assertFalse(d.contains(notInDirname), "Processed directory '"
+              + d + "' contains '" + notInDirname + "' when it shouldn't");
   }
 
   @DataProvider(name = "patternsAndMinNumFiles")
@@ -101,22 +97,64 @@ public class FileUtilsTest
   @DataProvider(name = "dirnamesAndBasenames")
   public Object[][] dirnamesAndBasenames()
   {
-    String homeDir = null;
-    try
-    {
-      homeDir = new File(System.getProperty("user.home"))
-              .getCanonicalPath();
-    } catch (IOException e)
-    {
-      System.err.println("Problem getting canonical home dir");
-      e.printStackTrace();
-    }
+    String homeDir = new File(System.getProperty("user.home")).getPath();
     return new Object[][] { // -1=startsWith, 0=equals, 1=endsWith
-        { "~/hello/sailor", -1, homeDir, "sailor", "~" }, //
-        { "~/hello/sailor", 1, "/hello", "sailor", "~" }, //
-        { "./examples/uniref50.fa", -1, "/", "uniref50", "." }, //
-        { "./examples/uniref50.fa", 1, "/examples", "uniref50", "." }, //
-        { "examples/uniref50.fa", 1, "/examples", "uniref50", ".fa" }, //
+        { "~/hello/sailor", homeDir, "/hello", "sailor", "~" }, //
+        { "./examples/uniref50.fa", "./", "examples", "uniref50", "Users" }, //
+        { "./examples/uniref50.1.fa", "./", "examples", "uniref50.1",
+            "Users" }, //
+        { "examples/uniref50.fa", "examples", "examples", "uniref50",
+            ".fa" }, //
     };
   }
+
+  @Test(groups = "Functional", dataProvider = "convertWildcardsToPathData")
+  public void convertWildcardsToPathTest(String value, String wildcard,
+          String dirname, String basename, String path)
+  {
+
+    Assert.assertEquals(
+            FileUtils.convertWildcardsToPath(value, wildcard, dirname,
+                    basename),
+            path, "Conversion of wildcard output path is not right.");
+
+  }
+
+  @DataProvider(name = "convertWildcardsToPathData")
+  public Object[][] convertWildcardsToPathData()
+  {
+    return new Object[][] {
+        /*
+         * cmdline args
+         * Arg (null if only testing headless)
+         * String value if there is one (null otherwise)
+         * boolean value if String value is null
+         * expected value of isHeadless()
+         */
+        /*
+        */
+        { "*/*", "*", "{dirname}", "{basename}", "{dirname}/{basename}" },
+        { "*/", "*", "{dirname}", "{basename}", "{dirname}/" },
+        { "/*", "*", "{dirname}", "{basename}", "/{basename}" },
+        { "*", "*", "{dirname}", "{basename}", "{basename}" },
+        { "tmp/output/*/file-*.stk", "*", "{dirname}", "{basename}",
+            "tmp/output/{dirname}/file-{basename}.stk" },
+        { "/*.file", "*", "{dirname}", "{basename}", "/{basename}.file" },
+        { "*/file.stk", "*", "{dirname}", "{basename}",
+            "{dirname}/file.stk" },
+        { "tmp/abc*def/file.stk", "*", "{dirname}", "{basename}",
+            "tmp/abc{dirname}def/file.stk" },
+        { "a*b/c*d", "*", "{dirname}", "{basename}",
+            "a{dirname}b/c{basename}d" },
+        { "a*b/c", "*", "{dirname}", "{basename}", "a{dirname}b/c" },
+        { "a/b*c", "*", "{dirname}", "{basename}", "a/b{basename}c" },
+        { "a*b", "*", "{dirname}", "{basename}", "a{basename}b" },
+        { "aSTARb/cSTARd", "STAR", "BEFORE", "AFTER", "aBEFOREb/cAFTERd" },
+        { "aSTARb/c", "STAR", "BEFORE", "AFTER", "aBEFOREb/c" },
+        { "a/bSTARc", "STAR", "BEFORE", "AFTER", "a/bAFTERc" },
+        { "aSTARb", "STAR", "BEFORE", "AFTER", "aAFTERb" },
+        //
+    };
+  }
+
 }
diff --git a/test/jalview/util/ImageMakerTest.java b/test/jalview/util/ImageMakerTest.java
new file mode 100644 (file)
index 0000000..c8f53e1
--- /dev/null
@@ -0,0 +1,112 @@
+package jalview.util;
+
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import jalview.bin.Cache;
+import jalview.util.imagemaker.BitmapImageSizing;
+
+public class ImageMakerTest
+{
+  @Test(groups = { "Functional" })
+  public void testParseScaleWidthHeightStrings()
+  {
+    Cache.setPropsAreReadOnly(true);
+    Cache.loadProperties("test/jalview/bin/testProps.jvprops");
+
+    Cache.removeProperty(BitmapImageSizing.BITMAP_SCALE);
+    Cache.removeProperty(BitmapImageSizing.BITMAP_HEIGHT);
+    Cache.removeProperty(BitmapImageSizing.BITMAP_WIDTH);
+
+    BitmapImageSizing bis = null;
+
+    // No defaults set, 3 values given. Should be the 3 values.
+    bis = ImageMaker.parseScaleWidthHeightStrings("1.2", "3", "4");
+    Assert.assertEquals(bis.scale(), 1.2f,
+            "scale not parsed and set to value given");
+    Assert.assertEquals(bis.width(), 3,
+            "width not parsed and set to value given");
+    Assert.assertEquals(bis.height(), 4,
+            "height not parsed and set to value given");
+
+    // No defaults set, 1 value given. Should be the 1 value and 2 0s.
+    bis = ImageMaker.parseScaleWidthHeightStrings("1.2", null, null);
+    Assert.assertEquals(bis.scale(), 1.2f,
+            "scale not parsed and set to value given");
+    Assert.assertEquals(bis.width(), 0, "width not parsed and set to 0");
+    Assert.assertEquals(bis.height(), 0, "height not parsed and set to 0");
+
+    // No defaults set, 1 value given. Should be the 1 value and 2 0s. (checking
+    // the other value)
+    bis = ImageMaker.parseScaleWidthHeightStrings(null, "1", null);
+    Assert.assertEquals(bis.scale(), 0f, "scale not parsed and set to 0f");
+    Assert.assertEquals(bis.width(), 1,
+            "width not parsed and set to value given");
+    Assert.assertEquals(bis.height(), 0, "height not parsed and set to 0");
+
+    // No defaults set, no values given, these should first look at defaults and
+    // then set all to 0
+    bis = ImageMaker.parseScaleWidthHeightStrings(null, null, null);
+    Assert.assertEquals(bis.scale(), 0f,
+            "scale not parsed and set to undefined default 0f");
+    Assert.assertEquals(bis.width(), 0,
+            "width not parsed and set to undefined default 0");
+    Assert.assertEquals(bis.height(), 0,
+            "height not parsed and set to undefined default 0");
+
+    Cache.setProperty(BitmapImageSizing.BITMAP_HEIGHT, "1");
+    // 1 default set, bis should detect this
+    Assert.assertEquals(bis.scale(), 0f,
+            "scale not parsed and set to undefined default 0f");
+    Assert.assertEquals(bis.width(), 0,
+            "width not parsed and set to undefined default 0");
+    Assert.assertEquals(bis.height(), 1,
+            "height not parsed and set to default 1");
+
+    Cache.setProperty(BitmapImageSizing.BITMAP_SCALE, "3.4");
+    Cache.setProperty(BitmapImageSizing.BITMAP_WIDTH, "2");
+    // Now all 3 defaults set, bis should detect this
+    Assert.assertEquals(bis.scale(), 3.4f,
+            "scale not parsed and set to undefined default 3.2f");
+    Assert.assertEquals(bis.width(), 2,
+            "width not parsed and set to undefined default 2");
+    Assert.assertEquals(bis.height(), 1,
+            "height not parsed and set to default 1");
+
+    // 3 defaults set, and 3 values given, should use the 3 values
+    bis = ImageMaker.parseScaleWidthHeightStrings("1.2", "3", "4");
+    Assert.assertEquals(bis.scale(), 1.2f,
+            "scale not parsed and set to value given");
+    Assert.assertEquals(bis.width(), 3,
+            "width not parsed and set to value given");
+    Assert.assertEquals(bis.height(), 4,
+            "height not parsed and set to value given");
+
+    // 3 defaults set, and 1 value given, should use the 1 value and 2 0s
+    bis = ImageMaker.parseScaleWidthHeightStrings("1.2", null, null);
+    Assert.assertEquals(bis.scale(), 1.2f,
+            "scale not parsed and set to value given");
+    Assert.assertEquals(bis.width(), 0,
+            "width not parsed and set to undefined 0");
+    Assert.assertEquals(bis.height(), 0,
+            "height not parsed and set to undefined 0");
+
+    // 3 defaults set, and 1 value given, should use the 1 value and 2 0s
+    bis = ImageMaker.parseScaleWidthHeightStrings(null, null, "5");
+    Assert.assertEquals(bis.scale(), 0f,
+            "scale not parsed and set to undefined 0f");
+    Assert.assertEquals(bis.width(), 0,
+            "width not parsed and set to undefined 0");
+    Assert.assertEquals(bis.height(), 5,
+            "height not parsed and set to value given");
+
+    // 3 defaults set, and no values given, should use the 3 default values
+    bis = ImageMaker.parseScaleWidthHeightStrings(null, null, null);
+    Assert.assertEquals(bis.scale(), 3.4f,
+            "scale not parsed and set to undefined default 3.4f");
+    Assert.assertEquals(bis.width(), 2,
+            "width not parsed and set to undefined default 2");
+    Assert.assertEquals(bis.height(), 1,
+            "height not parsed and set to default 1");
+  }
+}
diff --git a/test/jalview/util/imagemaker/BitmapImageSizeTest.java b/test/jalview/util/imagemaker/BitmapImageSizeTest.java
new file mode 100644 (file)
index 0000000..016c91f
--- /dev/null
@@ -0,0 +1,46 @@
+package jalview.util.imagemaker;
+
+import static org.testng.Assert.assertEquals;
+
+import org.testng.annotations.Test;
+
+import jalview.bin.Cache;
+
+public class BitmapImageSizeTest
+{
+  @Test(groups = { "Functional" })
+  public void testCacheSettingsRecovery()
+  {
+    Cache.setPropsAreReadOnly(true);
+    Cache.loadProperties("test/jalview/bin/testProps.jvprops");
+
+    Cache.removeProperty(BitmapImageSizing.BITMAP_HEIGHT);
+    Cache.removeProperty(BitmapImageSizing.BITMAP_SCALE);
+    Cache.removeProperty(BitmapImageSizing.BITMAP_WIDTH);
+
+    BitmapImageSizing def = BitmapImageSizing.defaultBitmapImageSizing();
+    BitmapImageSizing zero = BitmapImageSizing.nullBitmapImageSizing();
+
+    assertEquals(def.height(), zero.height());
+    assertEquals(def.width(), zero.width());
+    assertEquals(def.scale(), zero.scale());
+
+    Cache.setProperty(BitmapImageSizing.BITMAP_HEIGHT, "120");
+    Cache.setProperty(BitmapImageSizing.BITMAP_SCALE, "24");
+    Cache.setProperty(BitmapImageSizing.BITMAP_WIDTH, "360");
+
+    // default now updates dynamically
+    // def = BitmapImageSizing.defaultBitmapImageSizing();
+
+    assertEquals(def.height(), 120);
+    assertEquals(def.width(), 360);
+    assertEquals(def.scale(), 24f);
+
+    Cache.removeProperty(BitmapImageSizing.BITMAP_WIDTH);
+
+    // def = BitmapImageSizing.defaultBitmapImageSizing();
+    assertEquals(def.height(), 120);
+    assertEquals(def.width(), zero.width());
+    assertEquals(def.scale(), 24f);
+  }
+}
diff --git a/utils/conda/jalview.sh b/utils/conda/jalview.sh
new file mode 100755 (executable)
index 0000000..995195f
--- /dev/null
@@ -0,0 +1,178 @@
+#!/usr/bin/env bash
+
+###############################
+# Wrapper for Jalview
+#
+# 2023-08-16 Jalview 2.11.3.0 has new command line arguments
+# Old command line arguments are currently detected and actioned
+# but are no longer supported and will be removed at a later date.
+#
+# See
+#   Jalview -> Help -> Documentation -> Command Line -> introduction and reference
+# or
+#   https://www.jalview.org/help/html/features/clarguments.html
+# for details of the new command line arguments.
+#
+# Note, in order to run commandline-only calls use
+#   --headless
+#
+# By default, this wrapper executes java -version to determine the JRE version
+# Set JALVIEW_JRE=j1.8 or JALVIEW_JRE=j11 to skip the version check.
+#
+# By default, this wrapper does NOT restrict the memory consumption of Jalview.
+# Set eg. JALVIEW_MAXMEM=1g to set the maximal memory of Jalview's VM
+#
+# This script is maintained in the Jalview repository in utils/conda/jalview.sh
+###############################
+
+declare -a ARGS=("${@}")
+ARG1=$1
+
+# this function is because there's no readlink -f in Darwin/macOS
+function readlinkf() {
+  FINDFILE="$1"
+  FILE="${FINDFILE}"
+  PREVFILE=""
+  C=0
+  MAX=100 # just in case we end up in a loop
+  FOUND=0
+  while [ "${C}" -lt "${MAX}" -a "${FILE}" != "${PREVFILE}" -a "${FOUND}" -ne 1 ]; do
+    PREVFILE="${FILE}"
+    FILE="$(readlink "${FILE}")"
+    if [ -z "${FILE}" ]; then
+      # the readlink is empty means we've arrived at the script, let's canonicalize with pwd
+      FILE="$(cd "$(dirname "${PREVFILE}")" &> /dev/null && pwd -P)"/"$(basename "${PREVFILE}")"
+      FOUND=1
+    elif [ "${FILE#/}" = "${FILE}" ]; then
+      # FILE is not an absolute path link, we need to add the relative path to the previous dir
+      FILE="$(dirname "${PREVFILE}")/${FILE}"
+    fi
+    C=$((C+1))
+  done
+  if [ "${FOUND}" -ne 1 ]; then
+    echo "Could not determine path to actual file '$(basename "${FINDFILE}")'" >&2
+    exit 1
+  fi
+  echo "${FILE}"
+}
+
+ISMACOS=0
+if [ "$( uname -s )" = "Darwin" ]; then
+  ISMACOS=1
+fi
+
+# check for headless mode
+HEADLESS=0
+GUI=0
+HELP=0
+DEBUG=0
+for RAWARG in "${@}"; do
+  ARG="${RAWARG%%=*}"
+  case "${ARG}" in
+    --headless|--output|--image|--structureimage)
+      HEADLESS=1
+      ;;
+    --help|--help-*|--version)
+      HELP=1
+      ;;
+    --gui)
+      GUI=1
+      ;;
+    --debug)
+      DEBUG=1
+      ;;
+  esac
+  
+  if [ "${HELP}" = 1 ]; then
+    # --help takes precedence
+    HEADLESS=1
+    GUI=0
+  elif [ "${GUI}" = 1 ]; then
+    # --gui takes precedence over --headless
+    HEADLESS=0
+  fi
+done
+
+declare -a JVMARGS=()
+
+# set vars for being inside the macos App Bundle
+if [ "${ISMACOS}" = 1 ]; then
+# MACOS ONLY
+  DIR="$(dirname "$(readlinkf "$0")")"
+  JVMARGS=( "${JVMARGS[@]}" "-Xdock:icon=${DIR}/jalview_logo.png" )
+else
+# NOT MACOS
+  DIR="$(dirname "$(readlink -f "$0")")"
+fi
+
+if [ "${HEADLESS}" = 1 ]; then
+  # this suppresses the Java icon appearing in the macOS Dock and maybe other things in other OSes
+  JVMARGS=( "${JVMARGS[@]}" "-Djava.awt.headless=true" )
+fi
+
+JAVA=java
+
+# decide which jalview jar to launch - either 'j11' or 'j1.8'
+if [[ "$JALVIEW_JRE" != "j11" && "$JALVIEW_JRE" != "j1.8" ]]; then
+  JALVIEW_JRE="j11"
+  # if java 8 is installed we pick the j1.8 build
+  if [[ $( "${JAVA}" -version 2>&1 | grep '"1.8' ) != "" ]]; then
+    JALVIEW_JRE="j1.8"
+  fi
+fi
+
+JARPATH="${DIR}/jalview-all-${JALVIEW_JRE}.jar"
+
+# check if memory maximum is set and if so forward to java-based jalview call
+if [ \! -z "$JALVIEW_MAXMEM" ]; then
+  JVMARGS=( "${JVMARGS[@]}" "-Xmx${JALVIEW_MAXMEM}" )
+fi
+
+# WINDOWS ONLY (Cygwin or WSL)
+# change paths for Cygwin or Windows Subsystem for Linux (WSL)
+if [ "${ISMACOS}" != 1 ]; then # older macos doesn't like uname -o, best to avoid
+  if [ "$(uname -o)" = "Cygwin" ]; then
+  # CYGWIN
+    JARPATH="$(cygpath -pw "${JARPATH}")"
+    # now for some arg paths fun. only translating paths starting with './', '../', '/' or '~'
+    ARGS=()
+    for ARG in "${@}"; do
+      if [ "${ARG}" != "${ARG#@(/|./|../|~)}" ]; then
+        ARGS=( "${ARGS[@]}" "$(cygpath -aw "${ARG}")" )
+      else
+        ARGS=( "${ARGS[@]}" "${ARG}" )
+      fi
+    done
+  elif uname -r | grep -i microsoft | grep -i wsl >/dev/null; then
+  # WSL
+    JARPATH="$(wslpath -aw "${JARPATH}")"
+    ARGS=()
+    for ARG in "${@}"; do
+      if [ "${ARG}" != "${ARG#@(/|./|../|~)}" ]; then
+        # annoyingly wslpath does not work if the file doesn't exist!
+        ARGBASENAME="$(basename "${ARG}")"
+        ARGDIRNAME="$(dirname "${ARG}")"
+        ARGS=( "${ARGS[@]}" "$(wslpath -aw "${ARGDIRNAME}")\\${ARGBASENAME}" )
+      else
+        ARGS=( "${ARGS[@]}" "${ARG}" )
+      fi
+    done
+    JAVA="${JAVA}.exe"
+  fi
+fi
+
+# get console width -- three ways to try, just in case
+if command -v tput 2>&1 >/dev/null; then
+  COLUMNS=$(tput cols) 2>/dev/null
+elif command -v stty 2>&1 >/dev/null; then
+  COLUMNS=$(stty size | cut -d" " -f2) 2>/dev/null
+elif command -v resize 2>&1 >/dev/null; then
+  COLUMNS=$(resize -u | grep COLUMNS= | sed -e 's/.*=//;s/;//') 2>/dev/null
+fi
+JVMARGS=( "${JVMARGS[@]}" "-DCONSOLEWIDTH=${COLUMNS}" )
+
+if [ "${DEBUG}" = 1 ]; then
+ echo Shell running: "${JAVA}" "${JVMARGS[@]}" -jar \""${JARPATH}"\" "${ARGS[@]}"
+fi
+
+"${JAVA}" "${JVMARGS[@]}" -jar "${JARPATH}" "${ARGS[@]}"
index 9e3a8c7..849d71a 100755 (executable)
@@ -36,18 +36,45 @@ if [ "$( uname -s )" = "Darwin" ]; then
   ISMACOS=1
 fi
 
+# check for headless mode
+HEADLESS=0
+GUI=0
+HELP=0
+DEBUG=0
+for RAWARG in "${@}"; do
+  ARG="${RAWARG%%=*}"
+  case "${ARG}" in
+    --headless|--output|--image|--structureimage)
+      HEADLESS=1
+      ;;
+    --help|--help-*|--version|-h)
+      HELP=1
+      ;;
+    --gui)
+      GUI=1
+      ;;
+    --debug)
+      DEBUG=1
+      ;;
+  esac
+  
+  if [ "${HELP}" = 1 ]; then
+    # --help takes precedence
+    HEADLESS=1
+    GUI=0
+  elif [ "${GUI}" = 1 ]; then
+    # --gui takes precedence over --headless
+    HEADLESS=0
+  fi
+done
+
 declare -a JVMARGS=()
 
 # set vars for being inside the macos App Bundle
 if [ "${ISMACOS}" = 1 ]; then
 # MACOS ONLY
   DIR="$(dirname "$(readlinkf "$0")")"
-  APP="${DIR%.app/Contents/*}".app
-  if [ "${APP}" = "${APP%.app}" ]; then
-    echo "Could not find Jalview.app" >&2
-    exit 2
-  fi
-  APPDIR="${APP}/Contents/Resources/app"
+  APPDIR="${DIR%/bin}"
   JAVA="${APPDIR}/jre/Contents/Home/bin/java"
   JVMARGS=( "${JVMARGS[@]}" "-Xdock:icon=${APPDIR}/resource/jalview_logo.png" )
 else
@@ -57,6 +84,11 @@ else
   JAVA="${APPDIR}/jre/bin/java"
 fi
 
+if [ "${HEADLESS}" = 1 ]; then
+  # this suppresses the Java icon appearing in the macOS Dock and maybe other things in other OSes
+  JVMARGS=( "${JVMARGS[@]}" "-Djava.awt.headless=true" )
+fi
+
 SYSJAVA=java
 GETDOWNTXT="${APPDIR}/getdown.txt"
 
@@ -131,4 +163,8 @@ if [ \! -e "${JAVA}" ]; then
   echo "Cannot find bundled java, using system ${JAVA} and hoping for the best!" >&2
 fi
 
+if [ "${DEBUG}" = 1 ]; then
+ echo Shell running: \""${JAVA}"\" \""${JVMARGS[@]}"\" -cp \""${CLASSPATH}"\" jalview.bin.Launcher "${ARGS[@]}"
+fi
+
 "${JAVA}" "${JVMARGS[@]}" -cp "${CLASSPATH}" jalview.bin.Launcher "${ARGS[@]}"