Applet reads in annotation files
authoramwaterhouse <Andrew Waterhouse>
Fri, 3 Feb 2006 17:38:42 +0000 (17:38 +0000)
committeramwaterhouse <Andrew Waterhouse>
Fri, 3 Feb 2006 17:38:42 +0000 (17:38 +0000)
src/jalview/appletgui/AlignFrame.java
src/jalview/appletgui/AlignViewport.java
src/jalview/appletgui/AlignmentPanel.java

index dfd58b2..496a8bb 100755 (executable)
@@ -992,6 +992,8 @@ public void itemStateChanged(ItemEvent evt)
     resetAllColourSchemes();\r
     if(alignPanel.overviewPanel!=null)\r
       alignPanel.overviewPanel.updateOverviewImage();\r
+\r
+    viewport.alignment.adjustSequenceAnnotations();\r
     alignPanel.repaint();\r
   }\r
 \r
@@ -1872,6 +1874,7 @@ public void itemStateChanged(ItemEvent evt)
         font.addActionListener(this);\r
         scaleAbove.setLabel("Scale Above");\r
         scaleAbove.setState(true);\r
+        scaleAbove.setEnabled(false);\r
         scaleAbove.addItemListener(this);\r
         scaleLeft.setEnabled(false);\r
         scaleLeft.setState(true);\r
index e9078dd..50a90fe 100755 (executable)
@@ -221,7 +221,7 @@ public class AlignViewport
                                              annotations,\r
                                              0f, // cons.qualityRange[0].floatValue(),\r
                                              11f, // cons.qualityRange[1].floatValue()\r
-                                             AlignmentAnnotation.LINE_GRAPH);\r
+                                             AlignmentAnnotation.BAR_GRAPH);\r
       if (showConservation)\r
       {\r
         alignment.addAnnotation(conservation);\r
@@ -231,7 +231,7 @@ public class AlignViewport
                                         qannotations,\r
                                         cons.qualityRange[0].floatValue(),\r
                                         cons.qualityRange[1].floatValue(),\r
-                                        AlignmentAnnotation.LINE_GRAPH);\r
+                                        AlignmentAnnotation.BAR_GRAPH);\r
       if (showQuality)\r
       {\r
         alignment.addAnnotation(quality);\r
@@ -294,7 +294,7 @@ public class AlignViewport
     if (consensus == null)\r
     {\r
       consensus = new AlignmentAnnotation("Consensus",\r
-                                          "PID", annotations, 0f, 100f, AlignmentAnnotation.LINE_GRAPH);\r
+                                          "PID", annotations, 0f, 100f, AlignmentAnnotation.BAR_GRAPH);\r
       if (showConsensus)\r
       {\r
         alignment.addAnnotation(consensus);\r
index d7411fa..0e9a0d8 100755 (executable)
@@ -113,10 +113,11 @@ public class AlignmentPanel extends Panel implements AdjustmentListener
     scalePanel.setSize(new Dimension(10, av.charHeight + fm.getDescent()));\r
     idwidthAdjuster.setSize(new Dimension(10, av.charHeight + fm.getDescent()));\r
 \r
-    annotationPanel.adjustPanelHeight();\r
+    int ap = annotationPanel.adjustPanelHeight();\r
     annotationPanel.repaint();\r
     Dimension d = calculateIdWidth();\r
     d.setSize(d.width + 4, seqPanel.seqCanvas.getSize().height);\r
+    alabels.setSize(d.width+4, ap );\r
     idPanel.idCanvas.setSize(d);\r
     hscrollFillerPanel.setSize(d);\r
 \r