クラス「ビジュアル」でメソッドを使用してコード行を JTextArea に書き込もうとしていますが、「ビジュアル」から呼び出すと出力されますが、「ログイン」から呼び出すとテキストのみがコンソールに出力されます、TextArea ではありません。
private static Visual Visual;
Visual.WriteLine("I'm sorry, your username or password is incorrect. Please try again.");
また
private static Visual Visual = new Visual();
Visual.WriteLine("I'm sorry, your username or password is incorrect. Please try again.");
「ログイン」フォームを使用しないでください
しかし、
WriteLine("Test");
メソッドが含まれるクラスである「Visual」から機能します。
「ビジュアル」の方法は次のとおりです
public void WriteLine(String Text) {
System.out.println(Text);
SystemFeed.append(Text.toString() + "\n");
SystemFeed.setCaretPosition(SystemFeed.getDocument().getLength());
}