@@ -0,0 +1,2073 @@
+/*%0A * To change this license header, choose License Headers in Project Properties.%0A * To change this template file, choose Tools %7C Templates%0A * and open the template in the editor.%0A */%0A%0Apackage swing;%0A%0Aimport javax.swing.*;%0Aimport java.awt.*;%0Aimport java.awt.event.*;%0A/**%0A *%0A * @author matthewdelashaw%0A */%0Aclass MadLib implements ActionListener %7B%0A%0A        public String%5B%5D words = new String%5B10%5D;%0A        int num = words.length;%0A%09JTextField input;%0A        %0A        @Override%0A        public void actionPerformed(ActionEvent ae) %7B%0A                for(int x=0;x%3Cnum;x++)%7B%0A                words%5Bx%5D = input.getText();%0A                input.setEditable(false);%0A%09%09%7D%0A        %7D%0A%0A        public static void main(String%5B%5D args) %7B%0A%0A                String%5B%5D labels = %7B%22noun: %22,%22noun: %22,%22noun: %22,%22adj.: %22,%22adj.: %22,%22adj.: %22,%22adj.: %22,%22verb: %22,%22verb: %22,%22verb: %22,%22verb: %22%7D;%0A                int num = labels.length;%0A%0A                JFrame frame = new JFrame(%22Mad Lib%22);%0A                frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);%0A                frame.setSize(400,400);%0A                frame.setLocation(600,400);%0A%0A                JPanel panel = new JPanel();%0A%09%09panel.setBackground(new Color(53,56,64));%0A                Box box1 = Box.createVerticalBox();%0A                Box box2 = Box.createVerticalBox();%0A%09%09Box box3 = Box.createVerticalBox();%0A%0A                for (int i=0;i%3Cnum;i++) %7B%0A                        JLabel label = new JLabel(labels%5Bi%5D, JLabel.TRAILING);%0A                        label.setForeground(Color.white);%0A%09%09%09box1.add(label);%0A                        JTextField input = new JTextField(10);%0A                        input.addActionListener(new MadLib());%0A                        label.setLabelFor(input);%0A                        box2.add(input);%0A                %7D%0A%0A%09%09JTextArea output = new JTextArea();%0A%09%09box3.add(output);%0A%0A                panel.add(box1, BorderLayout.WEST);%0A                panel.add(box2, BorderLayout.CENTER);%0A%09%09panel.add(box3, BorderLayout.EAST);%0A                frame.setContentPane(panel);%0A                frame.setVisible(true);%0A        %7D%0A%7D%0A

Create MadLib.java