All Annotations defined after a SEQUENCE_REF command will then be
associated with that sequence, and the first field in the Value field
list will (optionally) be placed at the <em>startIndex</em>'th column.</p>
+<ul><em>New in Jalview 2.4</em>: the tooltip displayed when the mouse is moved over the row
+label for sequence associated annotation gives the associated
+sequence's name followed by the annotation row's description.</ul>
<p>Sequence associations are turned off for subsequent annotation
definitions by:
<pre>SEQUENCE_REF	ALIGNMENT</pre>
if (tooltip == null)
{
tooltip = new Tooltip(ap.av.alignment.
- getAlignmentAnnotation()[row].
- description,
+ getAlignmentAnnotation()[row].getDescription(true),
this);
}
else
{
tooltip.setTip(ap.av.alignment.
- getAlignmentAnnotation()[row].description);
+ getAlignmentAnnotation()[row].getDescription(true));
}
}
else if (tooltip != null)
}
}
}
+
+ /**
+ * format description string for display
+ * @param seqname
+ * @return Get the annotation description string optionally prefixed by associated sequence name (if any)
+ */
+ public String getDescription(boolean seqname)
+ {
+ if (seqname && this.sequenceRef!=null)
+ {
+ return sequenceRef.getName()+" : "+description;
+ }
+ return description;
+ }
}
if (aa.description != null && !aa.description.equals("New description"))
{
- desc.append(aa.description);
+ desc.append(aa.getDescription(true));
if(aa.hasScore)
desc.append("<br>");
}