Merge branch 'develop' into spike/JAL-4047/JAL-4048_columns_in_sequenceID
[jalview.git] / src / jalview / util / AWTConsole.java
index 9286794..f6145c2 100644 (file)
@@ -48,6 +48,8 @@ import java.io.PipedInputStream;
 import java.io.PipedOutputStream;
 import java.io.PrintStream;
 
+import jalview.bin.Jalview;
+
 public class AWTConsole extends WindowAdapter
         implements WindowListener, ActionListener, Runnable
 {
@@ -136,20 +138,20 @@ public class AWTConsole extends WindowAdapter
     // testing part
     // you may omit this part for your application
     //
-    System.out.println("Hello World 2");
-    System.out.println("All fonts available to Graphic2D:\n");
+    jalview.bin.Console.outPrintln("Hello World 2");
+    jalview.bin.Console.outPrintln("All fonts available to Graphic2D:\n");
     GraphicsEnvironment ge = GraphicsEnvironment
             .getLocalGraphicsEnvironment();
     String[] fontNames = ge.getAvailableFontFamilyNames();
     for (int n = 0; n < fontNames.length; n++)
     {
-      System.out.println(fontNames[n]);
+      jalview.bin.Console.outPrintln(fontNames[n]);
     }
     // Testing part: simple an error thrown anywhere in this JVM will be printed
     // on the Console
     // We do it with a seperate Thread becasue we don't wan't to break a Thread
     // used by the Console.
-    System.out.println("\nLets throw an error on this console");
+    jalview.bin.Console.outPrintln("\nLets throw an error on this console");
     errorThrower = new Thread(this);
     errorThrower.setDaemon(true);
     errorThrower.start();
@@ -174,7 +176,7 @@ public class AWTConsole extends WindowAdapter
     } catch (Exception e)
     {
     }
-    System.exit(0);
+    Jalview.exit("Window closing. Bye!", 0);
   }
 
   @Override