JAL-2349 tooltip reports value from contact range
authorJim Procter <j.procter@dundee.ac.uk>
Thu, 20 Oct 2022 09:50:49 +0000 (10:50 +0100)
committerJim Procter <j.procter@dundee.ac.uk>
Thu, 20 Oct 2022 09:50:57 +0000 (10:50 +0100)
src/jalview/gui/AnnotationPanel.java

index ccc086c..7f606c8 100755 (executable)
@@ -1078,7 +1078,9 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
         ContactGeometry cgeom = new ContactGeometry(clist, ann.graphHeight);
         ContactGeometry.contactInterval ci = cgeom.mapFor(rowAndOffset,
                 rowAndOffset);
-        tooltip += "Contact from " + ci.cStart + " to " + ci.cEnd;
+        ContactRange cr = clist.getRangeFor(ci.cStart, ci.cEnd);
+        tooltip = "Contact from " + ci.cStart + " to " + ci.cEnd
+                + "<br/>Mean:" + cr.getMean();
 
         // ap.getStructureSelectionManager().mouseOverSequence(ann.sequenceRef,
         // new int[] {column, ci.cStart,ci.cEnd}, -1, null)