/*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.9)
- * Copyright (C) 2015 The Jalview Authors
+ * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
+ * Copyright (C) $$Year-Rel$$ The Jalview Authors
*
* This file is part of Jalview.
*
seqMap = new IdentityHashMap<SequenceI, Color[]>();
AnnotatedCollectionI alcontext = alignment instanceof AlignmentI ? alignment
: alignment.getContext();
+ if (alcontext == null)
+ {
+ return;
+ }
int w = 0;
for (AlignmentAnnotation al : alcontext
.findAnnotation(TCoffeeScoreFile.TCOFFEE_SCORE))
{
return new TCoffeeColourScheme(sg);
}
+
+ /**
+ * Answers true if the annotated data has TCoffee score annotation
+ */
+ @Override
+ public boolean isApplicableTo(AnnotatedCollectionI ac)
+ {
+ if (ac.getContext() != null)
+ {
+ ac = ac.getContext();
+ }
+ AlignmentAnnotation[] anns = ac.getAlignmentAnnotation();
+ if (anns == null)
+ {
+ return false;
+ }
+ for (AlignmentAnnotation ann : anns)
+ {
+ if (TCoffeeScoreFile.TCOFFEE_SCORE.equals(ann.getCalcId()))
+ {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public String getSchemeName()
+ {
+ return JalviewColourScheme.TCoffee.toString();
+ }
}