diff --git a/src/main/java/ChatClient.java b/src/main/java/ChatClient.java index 44a0bc6..2c043b5 100644 --- a/src/main/java/ChatClient.java +++ b/src/main/java/ChatClient.java @@ -56,6 +56,7 @@ public class ChatClient extends JFrame implements KeyListener { while (true) { String message = fromServerReader.readLine(); outputTextArea.append(message + "\n"); + outputScrollPane.getVerticalScrollBar().setValue(outputScrollPane.getVerticalScrollBar().getMaximum()); } } catch (IOException e) { JOptionPane.showMessageDialog(null, "Verbindung zum Server \"" + address + "\" fehlgeschlagen.");