📄 label.java~22~
字号:
package jlabel;import java.awt.*;import java.awt.event.*;import java.applet.*;import javax.swing.*;import com.borland.jbcl.layout.*;public class label extends Applet { int x,y; boolean isStandalone = false; JLabel jLabel1 = new JLabel(); XYLayout xYLayout1 = new XYLayout(); /**Get a parameter value*/ public String getParameter(String key, String def) { return isStandalone ? System.getProperty(key, def) : (getParameter(key) != null ? getParameter(key) : def); } /**Construct the applet*/ public label() { } /**Initialize the applet*/ public void init() { try { jbInit(); } catch(Exception e) { e.printStackTrace(); } } /**Component initialization*/ private void jbInit() throws Exception { jLabel1.setBackground(Color.pink); jLabel1.setBorder(BorderFactory.createEtchedBorder()); jLabel1.setText("青城山"); this.setLayout(xYLayout1); this.addMouseMotionListener(new java.awt.event.MouseMotionAdapter() { }); Icon icon1=new ImageIcon("qingchengshan1.jpg"); jLabel1.setIcon(icon1); this.add(jLabel1, new XYConstraints(50, 50, -1, -1)); } /**Get Applet information*/ public String getAppletInfo() { return "Applet Information"; } /**Get parameter info*/ public String[][] getParameterInfo() { return null; }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -