JAL-961 allow calcId to be specified independently of alignment annotation row label
[jalview.git] / src / jalview / io / TCoffeeScoreFile.java
index 0da4628..9c75878 100644 (file)
@@ -482,7 +482,7 @@ public class TCoffeeScoreFile extends AlignFile {
              }
            }
            // this will overwrite any existing t-coffee scores for the alignment
-           AlignmentAnnotation aa=al.findOrCreateAnnotation(TCOFFEE_SCORE,false,s,null);
+           AlignmentAnnotation aa=al.findOrCreateAnnotation(TCOFFEE_SCORE,TCOFFEE_SCORE,false,s, null);
            if (s!=null)
            {
              aa.label="T-COFFEE";
@@ -490,6 +490,7 @@ public class TCoffeeScoreFile extends AlignFile {
              aa.annotations=annotations;
              aa.visible=false;
              aa.belowAlignment=false;
+             aa.setScore(header.getScoreFor(id.getKey()));
               aa.createSequenceMapping(s, s.getStart(),true);
               s.addAlignmentAnnotation(aa);
               aa.adjustForAlignment();
@@ -500,11 +501,13 @@ public class TCoffeeScoreFile extends AlignFile {
              aa.annotations=annotations;
               aa.belowAlignment=true;
              aa.visible=true;
+             aa.setScore(header.getScoreAvg());
            }
            aa.showAllColLabels=true;
            aa.validateRangeAndDisplay();
            added=true;
          }
+         
          return added;
        }