paintComponent. not paint
authoramwaterhouse <Andrew Waterhouse>
Mon, 9 May 2005 11:02:57 +0000 (11:02 +0000)
committeramwaterhouse <Andrew Waterhouse>
Mon, 9 May 2005 11:02:57 +0000 (11:02 +0000)
src/jalview/gui/SeqCanvas.java

index 2f02d57..74f6274 100755 (executable)
@@ -173,7 +173,7 @@ public void fastPaint(int horizontal, int vertical)
  * in the adjustment listener in SeqPanel when the scrollbars move.\r
  */\r
 \r
-  public void paint(Graphics g)\r
+  public void paintComponent(Graphics g)\r
   {\r
     g.setColor(Color.white);\r
     g.fillRect(0, 0, getWidth(), getHeight());\r
@@ -188,7 +188,7 @@ public void fastPaint(int horizontal, int vertical)
     // this draws the whole of the alignment\r
       imgWidth  = getWidth();\r
       imgHeight = getHeight();\r
-      if(imgWidth<0 || imgHeight<1)\r
+      if(imgWidth<1 || imgHeight<1)\r
         return;\r
 \r
       imgWidth -= imgWidth%av.charWidth;\r