From: jprocter Date: Thu, 10 May 2007 08:42:35 +0000 (+0000) Subject: ensure that only annotation referenced in given alignment is duplicated on returned... X-Git-Tag: Release_2_3~1 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=b21c79597152acf723a20743263171f7f566a00f;p=jalview.git ensure that only annotation referenced in given alignment is duplicated on returned sequence selection set --- diff --git a/src/jalview/datamodel/SequenceGroup.java b/src/jalview/datamodel/SequenceGroup.java index 18fb53b..cdc6fed 100755 --- a/src/jalview/datamodel/SequenceGroup.java +++ b/src/jalview/datamodel/SequenceGroup.java @@ -111,8 +111,25 @@ public class SequenceGroup if (seq.getAnnotation() != null) { + AlignmentAnnotation[] alann = align.getAlignmentAnnotation(); + // Only copy annotation that is either a score or referenced by the alignment's annotation vector for (int a = 0; a < seq.getAnnotation().length; a++) { + AlignmentAnnotation tocopy = seq.getAnnotation()[a]; + if (alann!=null) + { + boolean found=false; + for (int pos=0;pos