📄 about_version.java~71~
字号:
import com.borland.jbcl.layout.XYLayout;
import com.borland.jbcl.layout.*;
import java.awt.Font;
import javax.swing.border.TitledBorder;
import java.awt.BorderLayout;
import java.awt.Dimension;
import java.awt.Color;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.Icon;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.ImageIcon;
import java.awt.Toolkit;
import java.awt.Image;
public class About_Version extends JFrame
{
JLabel jLabel1 = new JLabel();
Toolkit kit = null;
Icon tubiao = null;
Icon wenzi = null;
Icon pic = null;
Image img = null;
JLabel jLabel2 = new JLabel();
JLabel jLabel3 = new JLabel();
JLabel jLabel4 = new JLabel();
TitledBorder titledBorder1 = new TitledBorder("");
String text = null;
JPanel jPanel1 = new JPanel();
JPanel jPanel3 = new JPanel();
XYLayout xYLayout1 = new XYLayout();
XYLayout xYLayout2 = new XYLayout();
XYLayout xYLayout3 = new XYLayout();
JPanel jPanel2 = new JPanel();
BorderLayout borderLayout1 = new BorderLayout();
JScrollPane jScrollPane1 = new JScrollPane();
JTextArea jTextArea1 = new JTextArea();
public About_Version()
{
kit = Toolkit.getDefaultToolkit();
img= kit.createImage(".\\images\\123.GIF");
this.setIconImage(img);
this.setSize(400,330);
this.setTitle("软件简介");
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
Dimension frameSize = getSize();
if (frameSize.height > screenSize.height) {
frameSize.height = screenSize.height;
}
if (frameSize.width > screenSize.width) {
frameSize.width = screenSize.width;
}
setLocation((screenSize.width - frameSize.width) / 2,
(screenSize.height - frameSize.height) / 2);
try
{
jbInit();
} catch (Exception exception)
{
exception.printStackTrace();
}
this.setVisible(true);
}
private void jbInit() throws Exception
{
tubiao = new ImageIcon(".\\images\\tubiao.jpg");
wenzi = new ImageIcon(".\\images\\about.jpg");
pic = new ImageIcon(".\\images\\TextArea.jpg");
getContentPane().setLayout(xYLayout2);
jLabel1.setOpaque(true);
jLabel1.setPreferredSize(new Dimension(70, 80));
jLabel1.setIcon(tubiao);
jLabel2.setOpaque(true);
jLabel2.setPreferredSize(new Dimension(180, 33));
jLabel2.setIcon(wenzi);
this.getContentPane().setBackground(Color.white);
this.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
jLabel3.setFont(new java.awt.Font("宋体", Font.PLAIN, 14));
jLabel3.setForeground(Color.blue);
jLabel4.setOpaque(true);
jLabel4.setIcon(pic);
jLabel3.setText("版本: V 0.1 完成日期:2008-5-13");
text = " 开发此系统的主要原因是因为老师下达的巨大任务 ~>_<~"+'\n'
+" 开发此系统的资金支持者,幕后老板--AP0506214--快发奖金啊!"+'\n'
+" 为此系统的设计绞尽脑汁的, 思想家--AP0506201--我唔Do啦,炒老板鱿鱼!"+'\n'
+" 由于代码民工紧缺,在此感谢日夜操劳的 代码民工--AP0506221--救命,以后都唔做啦!"+'\n'
+" 对于此系统,有任何的意见,请不要向大老板提出啊! 全体代码民工在此感谢合作!!";
jPanel1.setBackground(Color.white);
jPanel1.setMinimumSize(new Dimension(265, 200));
jPanel1.setPreferredSize(new Dimension(265, 200));
jPanel1.setLayout(xYLayout1);
jPanel3.setBackground(new Color(236, 233, 173));
jPanel3.setOpaque(false);
jPanel3.setLayout(xYLayout3);
jPanel2.setLayout(borderLayout1);
jTextArea1.setBorder(null);
jTextArea1.setText(
" 开发此系统的主要原因是因为老师下达任务的巨大压力 ~>_<~\n 开发此系统的资金支持者,幕后老板--AP0506214--快发奖金啊!\n" +
" 为此系统的设计绞尽脑汁的, 思想家--AP0506201--我唔Do啦,炒老板鱿鱼!\n 由于代码民工紧缺,在此感谢日夜操劳的 " +
"代码民工--AP0506221--救命,以后都唔做啦!\n 对于此系统,有任何的意见,请不要向大老板提出啊! 全体代码民工在此感谢合作!!");
jTextArea1.setColumns(20);
jTextArea1.setLineWrap(true);
jPanel2.setOpaque(false);
jPanel1.add(jLabel1, new XYConstraints(10, 11, -1, -1));
jPanel1.add(jLabel3, new XYConstraints(115, 75, -1, -1));
jPanel1.add(jLabel2, new XYConstraints(147, 11, -1, -1));
jPanel1.validate();
jPanel2.validate();
this.getContentPane().add(jPanel1, new XYConstraints(0, 0, 400, 92));
this.getContentPane().add(jPanel3, new XYConstraints(0, 93, 400, 207));
jPanel3.add(jLabel4, new XYConstraints(0, 0, -1, -1));
jScrollPane1.getViewport().add(jTextArea1);
jPanel2.add(jScrollPane1, java.awt.BorderLayout.CENTER);
jPanel3.add(jPanel2, new XYConstraints(88, 70, 223, 74));
this.validate();
}
public static void main(String[] args)
{
new About_Version();
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -