⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gridbaglayout.java~3~

📁 java GUI用户界面程序
💻 JAVA~3~
字号:
package chapter7.layout;

import java.awt.*;
import com.borland.jbcl.layout.XYLayout;
import com.borland.jbcl.layout.*;
import javax.swing.JButton;

public class GridBagLayout
    extends Frame
{
    public GridBagLayout()
    {
        try
        {
            jbInit();
        }
        catch (Exception exception)
        {
            exception.printStackTrace();
        }
    }

    private void jbInit()
        throws Exception
    {
        this.setLayout(gridBagLayout1);
        jButton1.setText("jButton1");
        jButton2.setText("jButton2");
        jButton3.setText("jButton3");
        jButton4.setText("jButton4");
        jButton5.setText("jButton5");
        jButton6.setText("jButton6");
        jButton7.setText("jButton7");
        this.add(jButton1, null);
        this.add(jButton2, null);
        this.add(jButton3, null);
        this.add(jButton4, null);
        this.add(jButton5, null);
        this.add(jButton6, null);
        this.add(jButton7, null);
    }

    public static void main(String[] args)
    {
        GridBagLayout gridbaglayout = new GridBagLayout();
    }

    JButton jButton1 = new JButton();
    JButton jButton2 = new JButton();
    JButton jButton3 = new JButton();
    JButton jButton4 = new JButton();
    JButton jButton5 = new JButton();
    JButton jButton6 = new JButton();
    JButton jButton7 = new JButton();
    GridBagLayout gridBagLayout1 = new GridBagLayout();
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -