import java.awt.*;
import javax.swing.*;
import java.awt.event.*;public class LabelTest extends JFrame
{
private JLabel label1,label2,label3;
public LabelTest()
{
super("Testing JLable");//直接访问父类的构造方法 用super关键字
getContentPane();  label1 = new JLabel("Lable with text");
label1.setToolTipText("This is label1");//当鼠标停留在此标签时将显示"This is label1"提示;
add(label1);//将Lable with text添加到窗口中 作为内容 Icon bug = new ImageIcon ("Aqua16.jpg");//用于图象
label2 = new JLabel("Label with text and icon ",bug,SwingConstants.LEFT);
label2.setToolTipText("This is label2");
add(label2); label3 = new JLabel();
label3.setText("Label with icon and text at bottom");//设置标签的显示位置
label3.setIcon(bug);
label3.setHorizontalTextPosition(SwingConstants.CENTER);
label3.setVerticalTextPosition(SwingConstants.BOTTOM);
label3.setToolTipText("This is label3"); 
add(label3); setSize(300,400);
setVisible(true); } public static void main(String[] args) 
{
LabelTest application = new LabelTest();
application.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
}
为什么我运行后就输出了 Label3里的字符....Label1   Label2 里的却没有输出在窗体内..
请指教