package examples.example5_chat_OO_library; import java.awt.Color; import java.awt.Dimension; import javax.swing.JLabel; import javax.swing.JPanel; import javax.swing.JScrollPane; /** * TODO Put here a description of what this class does. * * @author mutchler. * Created May 12, 2009. */ public class ChatPanel extends JPanel { /** * TODO Put here a description of what this constructor does. * * @param label * @param color * @param dimension */ public ChatPanel(String label, Color color, Dimension dimension) { this.setPreferredSize(dimension); this.setBackground(color); this.add(new JLabel(label)); this.add(new JScrollPane()); } }