From caa676b5a4f8e864ef3497e5d17d0a37635ef421 Mon Sep 17 00:00:00 2001 From: Paul Kattenborn Date: Fri, 9 Feb 2024 01:58:21 +0100 Subject: [PATCH] =?UTF-8?q?farben=20als=20men=C3=BCpunkte=20hinzugef=C3=BC?= =?UTF-8?q?gt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/ChatGUI.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/main/java/ChatGUI.java b/src/main/java/ChatGUI.java index f6d09d7..0781edc 100644 --- a/src/main/java/ChatGUI.java +++ b/src/main/java/ChatGUI.java @@ -15,6 +15,10 @@ import javax.swing.JTextField; public class ChatGUI implements ActionListener { JMenuItem exit = new JMenuItem("Exit"); + JMenuItem black = new JMenuItem("black"); + JMenuItem red = new JMenuItem("red"); + JMenuItem blue = new JMenuItem("blue"); + JMenuItem green = new JMenuItem("green"); JTextField inputTextField = new JTextField(); JTextArea outputTextArea = new JTextArea(); @@ -33,11 +37,19 @@ public class ChatGUI implements ActionListener { gui.setJMenuBar(bar); JMenu options = new JMenu("options"); + JMenu colors = new JMenu("font-colors"); JMenu menu = new JMenu("File"); menu.add(exit); menu.add(options); bar.add(menu); + options.add(colors); + + colors.add(black); + colors.add(red); + colors.add(blue); + colors.add(green); + exit.addActionListener(this); bar.add(menu);