freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

第八章面板與布局管理器81-預覽頁

2025-08-25 13:17 上一頁面

下一頁面
 

【正文】 s,int cols,int hgap,int vgap) public GridLayout(int rows,int cols) 構(gòu)造方法創(chuàng)建一個帶指定行數(shù)和列數(shù)的格布局 。 另外 , 水平和垂直間距設置為指定值 。 setLayout(g1)。 button4=new Button(Button 4)。 add(button4)。 它是 windows、 Dialog和 Frame容器的 默認布局管理器 。 hgap水平間距; vgap垂直間距 下列程序使用了 BorderLayout管理器對象并在applet中放置了五個按鈕 。 setLayout(b1)。 button4=new Button(Button 4)。 add(East,button3)。 基本上是有一組面板被添加到一個卡片布局中,但一次只有一個是可見的。 因為每個卡片使用不同的布局管理器 。 垂直間距被放置在頂邊和底邊處 。 使用卡片布局管理器局部代碼 Button button1,button2,button3。 //將 p1添加到 applet中 c1=new CardLayout()。 button3=new Button(Button 3)。 (“Button 1,button1)。 當執(zhí)行這代碼時可在顯示中看見單個按鈕 。 public void actionPerformed(ActionEvent e) { (p1)。 構(gòu)造方法: BoxLayout(Container con, int axis) 使用 BoxLayout的容器 類方法: createHorizontalBox():獲得一個具有行型盒式布局的盒式容器。 (int width): 創(chuàng)建不可見的水平 Struct類型的對象(水平支撐)。 它會幫助組件靠左 /右對齊。 膠水:膠水組件可處理盒式布局容器的剩余空間。 P143 (int height): 創(chuàng)建不可見的垂直 Struct類型的對象(垂直支撐)。 setBounds()的定義: void setBounds(int x, int y, int width, int height)。 對一個容器的布局 /安排通常是先創(chuàng)建一個布局管理器 , 然后再設置它 。 import .*。 Button option=new Button(“選項 ” )。 Button apply1=new Button(“應用 ” )。 Button cancel2=new Button(“取消 ” )。 public void init() { Panel flowPanel=new Panel()。 (cancel)。 Panel gridPanel=new Panel()。 (cancel1)。 Panel borderPanel=new Panel()。 (“East”,cancel2)。 CardLayout appletLayout=new CardLayout ()。 add(borderPanel)。 } }
點擊復制文檔內(nèi)容
規(guī)章制度相關推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1