X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fio%2FHtmlFile.java;h=e31e78dcc2551fcf2c80df2059c05d0d10834b07;hb=e60cacff9260c47c12cf34a7e191678cfc97d265;hp=dc14cc03916cf551c25bef3d03ad183a57c17aab;hpb=73d2eb017ebcaff4453d676c0d728f61015d102c;p=jalview.git diff --git a/src/jalview/io/HtmlFile.java b/src/jalview/io/HtmlFile.java index dc14cc0..e31e78d 100644 --- a/src/jalview/io/HtmlFile.java +++ b/src/jalview/io/HtmlFile.java @@ -22,10 +22,10 @@ package jalview.io; import jalview.api.ComplexAlignFile; +import jalview.api.FeatureSettingsModelI; import jalview.api.FeaturesDisplayedI; import jalview.datamodel.ColumnSelection; import jalview.datamodel.SequenceI; -import jalview.schemes.ColourSchemeI; import java.io.IOException; import java.io.StringReader; @@ -40,7 +40,7 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile public static final String FILE_DESC = "HTML"; - private ColourSchemeI colourScheme; + private String globalColourScheme; private boolean showSeqFeatures; @@ -103,13 +103,12 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile throw new IOException(errormessage); } JSONFile jsonFile = new JSONFile().parse(new StringReader( - contentFromDiv ? content.text() : content - .val())); + contentFromDiv ? content.text() : content.val())); this.seqs = jsonFile.getSeqs(); this.seqGroups = jsonFile.getSeqGroups(); this.annotations = jsonFile.getAnnotations(); this.showSeqFeatures = jsonFile.isShowSeqFeatures(); - this.colourScheme = jsonFile.getColourScheme(); + this.globalColourScheme = jsonFile.getGlobalColourScheme(); this.hiddenSequences = jsonFile.getHiddenSequences(); this.columnSelection = jsonFile.getColumnSelection(); this.displayedFeatures = jsonFile.getDisplayedFeatures(); @@ -119,7 +118,6 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile } } - @Override public String print() { @@ -127,6 +125,7 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile "Print method of HtmlFile is not supported!"); } + @Override public boolean isShowSeqFeatures() { return showSeqFeatures; @@ -137,16 +136,18 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile this.showSeqFeatures = showSeqFeatures; } - public ColourSchemeI getColourScheme() + @Override + public String getGlobalColourScheme() { - return colourScheme; + return globalColourScheme; } - public void setColourScheme(ColourSchemeI colourScheme) + public void setColourScheme(String globalColourScheme) { - this.colourScheme = colourScheme; + this.globalColourScheme = globalColourScheme; } + @Override public ColumnSelection getColumnSelection() { return columnSelection; @@ -157,6 +158,7 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile this.columnSelection = columnSelection; } + @Override public SequenceI[] getHiddenSequences() { return hiddenSequences; @@ -173,4 +175,19 @@ public class HtmlFile extends AlignFile implements ComplexAlignFile return displayedFeatures; } + /** + * Returns a descriptor for suitable feature display settings with + * + */ + @Override + public FeatureSettingsModelI getFeatureColourScheme() + { + return new PDBFeatureSettings(); + } + }