?? chap11-7.txt
字號(hào):
// 程序11-7
import java.awt.*;
import javax.swing.*;
public class testTabbedPane{
JFrame frame;
Container contentPane;
JTabbedPane jtp;
public testTabbedPane( ){ // testTabbedPane的構(gòu)造函數(shù)
frame=new subJFrame("testTabbedPane");
contentPane=frame.getContentPane( );
jtp= new JTabbedPane( );
contentPane.add(jtp , BorderLayout.CENTER);
for(int i=0;i<5;i++){
JButton button=new JButton("按鈕 "+i);
jtp.add(" "+i,button);
}
frame.setSize(300,200);
frame.show( );
}
public static void main(String args[ ]){
testTabbedPane obj=new testTabbedPane( );
}
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -