JAL-3676 improvement for visual selection of console text - fg color change if required
[jalview.git] / src / jalview / gui / Console.java
index dc5968d..89e0134 100644 (file)
@@ -144,14 +144,18 @@ public class Console extends WindowAdapter
     {
       private Color bg = textArea.getBackground();
 
+      private Color fg = textArea.getForeground();
+
       public void mousePressed(MouseEvent e)
       {
         textArea.setBackground(textArea.getSelectionColor());
+        textArea.setForeground(textArea.getSelectedTextColor());
       }
 
       public void mouseReleased(MouseEvent e)
       {
         textArea.setBackground(bg);
+        textArea.setForeground(fg);
       }
 
     });