about.java

来自「这个软件是一个图书管理系统」· Java 代码 · 共 24 行

JAVA
24
字号
//import the packages for using the classes in them into the program
   import java.awt.*;
   import javax.swing.*;

/**
 *A public class
 */
   public class about extends JPanel {
   //constructor of about
      public about() {
      //for creating the image icon
         ImageIcon icon = new ImageIcon(ClassLoader.getSystemResource("images/java.jpg"));
      //for creating the label and setting the image icon
         JLabel label1  = new JLabel(icon);
      //for adding the label to the panel
         this.add(label1);
      //for creating the label and setting the text
         JLabel label2 = new JLabel("JAVA Library System");
      //for setting the font to the label
         label2.setFont(new Font("Tahom", Font.PLAIN, 11));
      //for adding the lable to the panel
         this.add(label2);
      }
   }

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?