package puzzle.puzzleClasses; import java.awt.Container; import java.awt.Font; import java.awt.GridLayout; import javax.swing.JLabel; import javax.swing.JPanel; import javax.swing.border.TitledBorder; final public class infoFrame extends JPanel { private static final long serialVersionUID = 1L; public repaintLabel file_label; // name of file public repaintLabel status; // what's going on in the program/status bar public repaintLabel orig_time; // time it took for the original ray trace public repaintLabel apx_time; // apx. time for traditional ray tracer public repaintLabel light_num; // current light being edited public infoFrame() { super(); Container con = this; con.setLayout(new GridLayout(5, 2)); JLabel time = new JLabel("Initial Ray Trace Time: ", JLabel.RIGHT); con.add(time); Font jlabel = new Font((time.getFont()).getAttributes()); orig_time = new repaintLabel(" "); orig_time.setFont(jlabel); con.add(orig_time); JLabel atime = new JLabel("Apx. Traditional Ray Trace Time: ", JLabel.RIGHT); con.add(atime); apx_time = new repaintLabel(" "); apx_time.setFont(jlabel); con.add(apx_time); JLabel current = new JLabel("Current file: ", JLabel.RIGHT); con.add(current); file_label = new repaintLabel(" "); file_label.setFont(jlabel); con.add(file_label); JLabel progress = new JLabel("Progress: ", JLabel.RIGHT); con.add(progress); status = new repaintLabel(" "); status.setFont(jlabel); con.add(status); JLabel light = new JLabel("Selected Light Number: ", JLabel.RIGHT); con.add(light); light_num = new repaintLabel(" "); light_num.setFont(jlabel); con.add(light_num); TitledBorder border = new TitledBorder("Status/Info: "); border.setTitleJustification(TitledBorder.CENTER); setBorder(border); } }