JAL-1497 check to see if tree structure is ready for display, and show a 'tree loadin...
authorJim Procter <jprocter@dundee.ac.uk>
Thu, 1 May 2014 14:12:07 +0000 (15:12 +0100)
committerJim Procter <jprocter@dundee.ac.uk>
Thu, 1 May 2014 14:12:07 +0000 (15:12 +0100)
src/jalview/gui/TreeCanvas.java

index 9e2e582..97cca4b 100755 (executable)
@@ -667,9 +667,12 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
             RenderingHints.VALUE_ANTIALIAS_ON);
     g2.setColor(Color.white);
     g2.fillRect(0, 0, width, height);
-
     g2.setFont(font);
 
+    if (longestName==null || tree ==null)
+    {
+      g2.drawString("Calculating tree.",20,20);
+    }
     offy = font.getSize() + 10;
 
     fm = g2.getFontMetrics(font);