AboutPopUp.java 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. package de.tu_darmstadt.tk.SmartHomeNetworkSim.view.popups;
  2. import javax.swing.JFrame;
  3. import javax.swing.JLabel;
  4. import java.awt.Dimension;
  5. import java.awt.Font;
  6. import javax.swing.JTextArea;
  7. import javax.swing.UIManager;
  8. import de.tu_darmstadt.tk.SmartHomeNetworkSim.view.util.Utility;
  9. /**
  10. * PopUp which shows a short description of the program and developers
  11. *
  12. * @author Andreas T. Meyer-Berg
  13. */
  14. public class AboutPopUp extends JFrame {
  15. /**
  16. *
  17. */
  18. private static final long serialVersionUID = -7426102751026092131L;
  19. /**
  20. * Create PopUp
  21. */
  22. public AboutPopUp() {
  23. //Created using Eclipse Window Builder
  24. this.setMinimumSize(new Dimension(500, 400));
  25. this.setPreferredSize(new Dimension(500, 400));
  26. setIconImage(Utility.loadFile("/images/smartHome_icon.png"));
  27. setTitle("SmartHomeNetworkSim: About");
  28. setFont(new Font("Roboto", Font.PLAIN, 42));
  29. getContentPane().setLayout(null);
  30. JLabel lblSmartHomeNetwork = new JLabel("Smart Home Network Sim");
  31. lblSmartHomeNetwork.setFont(new Font("Roboto", Font.PLAIN, 26));
  32. lblSmartHomeNetwork.setBounds(12, 13, 458, 51);
  33. getContentPane().add(lblSmartHomeNetwork);
  34. JTextArea txtrSmarthomenetworksim = new JTextArea();
  35. txtrSmarthomenetworksim.setWrapStyleWord(true);
  36. txtrSmarthomenetworksim.setBackground(UIManager
  37. .getColor("Button.background"));
  38. txtrSmarthomenetworksim.setEditable(false);
  39. txtrSmarthomenetworksim.setLineWrap(true);
  40. txtrSmarthomenetworksim.setFont(new Font("Roboto", Font.PLAIN, 16));
  41. txtrSmarthomenetworksim
  42. .setText("The SmartHomeNetworkSim is a framework for visualization and generation of IoT/SmartHome "
  43. + "network traffic. It allows the user to configure an IoT/SmartHome network and simulate it.");
  44. txtrSmarthomenetworksim.setBounds(12, 81, 458, 103);
  45. getContentPane().add(txtrSmarthomenetworksim);
  46. JLabel lblDevelopers = new JLabel(
  47. "Developer: Andreas T. Meyer-Berg (Bachelor Thesis)");
  48. lblDevelopers.setFont(new Font("Roboto", Font.PLAIN, 16));
  49. lblDevelopers.setBounds(12, 260, 458, 51);
  50. getContentPane().add(lblDevelopers);
  51. // TODO Auto-generated constructor stub
  52. }
  53. }