contentPane.add(jPanel1, BorderLayout.WEST);
jPanel1.add(jButton1, new XYConstraints(0, 0,150, 20));
jPanel1.add(jPanel2, new XYConstraints(0, 230, 150, 120));
jPanel2.add(jButton2, new XYConstraints(0, 0,150, 20));
jPanel2.add(jPanel3, new XYConstraints(0, 20, 150, 100));
jPanel3.add(jButton3, new XYConstraints(0, 0, 150, 20));
jPanel3.add(jButton14, new XYConstraints(10,25,30,30));
jPanel3.add(jButton15, new XYConstraints(10,60,30,30));
jPanel3.add(jPanel4, new XYConstraints(0,20, 150, 80));
jPanel4.add(jButton4, new XYConstraints(0, 0,150, 20));
jPanel4.add(jButton16, new XYConstraints(10,25,30,30));
jPanel4.add(jButton17, new XYConstraints(10,60,30,30));
jPanel4.add(jPanel5, new XYConstraints(0, 20, 150, 60));
jPanel5.add(jButton5, new XYConstraints(0, 0,150, 20));
jPanel5.add(jButton18, new XYConstraints(10,25,30,30));
jPanel5.add(jButton19, new XYConstraints(10,60,30,30));
jPanel5.add(jPanel6, new XYConstraints(0,20, 150, 40));
jPanel6.add(jButton6, new XYConstraints(0, 0,150, 20));
jPanel6.add(jButton20, new XYConstraints(10,25,30,30));
jPanel6.add(jButton21, new XYConstraints(10, 60,30,30));
jPanel6.add(jPanel7, new XYConstraints(0, 20, 150, 20));
jPanel7.add(jButton7, new XYConstraints(0, 0,150, 20));
jPanel7.add(jButton23, new XYConstraints(10,25,30,30));
jPanel7.add(jButton22, new XYConstraints(10, 60,30,30));
jPanel1.add(jButton10, new XYConstraints(10, 25, 30, 30));
jPanel1.add(jButton11, new XYConstraints(10, 60, 30, 30));
jPanel2.add(jButton12, new XYConstraints(10,25,30,30));
jPanel2.add(jButton13, new XYConstraints(10,60,30,30));
contentPane.add(jPanel8, BorderLayout.CENTER);
jPanel8.add(jLabel1, new XYConstraints(34, 55, 147, 35));
jPanel8.add(jLabel2, new XYConstraints(33, 119, 148, 36));
System.out.println(jButton12.getY() );
System.out.println(jButton12.getX() );
System.out.println(jButton12.getHeight() );
}
//File | Exit action performed
public void jMenuFileExit_actionPerformed(ActionEvent e) {
System.exit(0);
}
//Help | About action performed
public void jMenuHelpAbout_actionPerformed(ActionEvent e) {
}
//Overridden so we can exit when window is closed
protected void processWindowEvent(WindowEvent e) {
super.processWindowEvent(e);
if (e.getID() == WindowEvent.WINDOW_CLOSING) {
jMenuFileExit_actionPerformed(null);
}
}
void jButton1_actionPerformed(ActionEvent e) {
public class MainFrame extends JFrame {
JPanel contentPane;
JMenuBar jMenuBar1 = new JMenuBar();
JMenu jMenuFile = new JMenu();
JMenuItem jMenuFileExit = new JMenuItem();
JMenu jMenuHelp = new JMenu();
JMenuItem jMenuHelpAbout = new JMenuItem();
JToolBar jToolBar = new JToolBar();
JButton jButton8 = new JButton();
JButton jButton9 = new JButton();
JPanel jPanel1 = new JPanel();
JButton jButton1 = new JButton();
XYLayout xYLayout1 = new XYLayout();
JPanel jPanel2 = new JPanel();
JButton jButton2 = new JButton();
XYLayout xYLayout2 = new XYLayout();
JPanel jPanel3 = new JPanel();
XYLayout xYLayout3 = new XYLayout();
JButton jButton3 = new JButton();
JPanel jPanel4 = new JPanel();
XYLayout xYLayout4 = new XYLayout();
JButton jButton4 = new JButton();
XYLayout xYLayout8 = new XYLayout();
JPanel jPanel8 = new JPanel();
JLabel jLabel1 = new JLabel();
XYLayout xYLayout9 = new XYLayout();
JLabel jLabel2 = new JLabel();
JButton jButton10 = new JButton();
JButton jButton11 = new JButton();
JButton jButton12 = new JButton();
JButton jButton13 = new JButton();
JButton jButton14 = new JButton();
JButton jButton15 = new JButton();
JButton jButton16 = new JButton();
JButton jButton17 = new JButton();
JButton jButton5 = new JButton();
JPanel jPanel5 = new JPanel();
XYLayout xYLayout5 = new XYLayout();
JButton jButton18 = new JButton();
JButton jButton19 = new JButton();
JButton jButton6 = new JButton();
JPanel jPanel6 = new JPanel();
XYLayout xYLayout6 = new XYLayout();
JButton jButton20 = new JButton();
JButton jButton21 = new JButton();
JButton jButton22 = new JButton();
JButton jButton7 = new JButton();
JPanel jPanel7 = new JPanel();
JButton jButton23 = new JButton();
XYLayout xYLayout7 = new XYLayout();
BorderLayout borderLayout1 = new BorderLayout();
//Construct the frame
public MainFrame() {
enableEvents(AWTEvent.WINDOW_EVENT_MASK);
if(change){
try {
jbInit();
}
catch (Exception e) {
e.printStackTrace();
}
}
change=false;
}
//Component initialization
private void jbInit() throws Exception {
image1 = new ImageIcon(gcss1.MainFrame.class.getResource("openFile.png"));
image2 = new ImageIcon(gcss1.MainFrame.class.getResource("closeFile.png"));
image3 = new ImageIcon(gcss1.MainFrame.class.getResource("help.png"));
public class MainFrame extends JFrame {
JPanel contentPane;
JMenuBar jMenuBar1 = new JMenuBar();
JMenu jMenuFile = new JMenu();
JMenuItem jMenuFileExit = new JMenuItem();
JMenu jMenuHelp = new JMenu();
JMenuItem jMenuHelpAbout = new JMenuItem();
JToolBar jToolBar = new JToolBar();
JButton jButton8 = new JButton();
JButton jButton9 = new JButton();
ImageIcon image1;
ImageIcon image2;
ImageIcon image3;
JLabel statusBar = new JLabel();
BorderLayout borderLayout1 = new BorderLayout();
JPanel jPanel1 = new JPanel();
JButton jButton1 = new JButton();
XYLayout xYLayout1 = new XYLayout();
JPanel jPanel2 = new JPanel();
JButton jButton2 = new JButton();
XYLayout xYLayout2 = new XYLayout();
JPanel jPanel3 = new JPanel();
XYLayout xYLayout3 = new XYLayout();
JButton jButton3 = new JButton();
JPanel jPanel4 = new JPanel();
XYLayout xYLayout4 = new XYLayout();
JButton jButton4 = new JButton();
JPanel jPanel5 = new JPanel();
XYLayout xYLayout5 = new XYLayout();
JButton jButton5 = new JButton();
JPanel jPanel6 = new JPanel();
XYLayout xYLayout6 = new XYLayout();
JButton jButton6 = new JButton();
JPanel jPanel7 = new JPanel();
XYLayout xYLayout7 = new XYLayout();
JButton jButton7 = new JButton();
XYLayout xYLayout8 = new XYLayout();
JPanel jPanel8 = new JPanel();
JLabel jLabel1 = new JLabel();
XYLayout xYLayout9 = new XYLayout();
JLabel jLabel2 = new JLabel();
JButton jButton10 = new JButton();
JButton jButton11 = new JButton();
//Construct the frame
public MainFrame() {
enableEvents(AWTEvent.WINDOW_EVENT_MASK);
if(change){
try {
jbInit();
}
catch (Exception e) {
e.printStackTrace();
}
}
change=false;
}
//Component initialization
private void jbInit() throws Exception {
image1 = new ImageIcon(gcss1.MainFrame.class.getResource("openFile.png"));
image2 = new ImageIcon(gcss1.MainFrame.class.getResource("closeFile.png"));
image3 = new ImageIcon(gcss1.MainFrame.class.getResource("help.png"));
contentPane.add(jPanel1, BorderLayout.WEST);
jPanel1.add(jButton1, new XYConstraints(0, 0,150, 20));
jPanel1.add(jPanel2, new XYConstraints(0, 230, 150, 120));
jPanel2.add(jButton2, new XYConstraints(0, 0,150, 20));
jPanel2.add(jPanel3, new XYConstraints(0, 20, 150, 100));
jPanel3.add(jButton3, new XYConstraints(0, 0, 150, 20));
jPanel3.add(jPanel4, new XYConstraints(0,20, 150, 80));
jPanel4.add(jButton4, new XYConstraints(0, 0,150, 20));
jPanel4.add(jPanel5, new XYConstraints(0, 20, 150, 60));
jPanel5.add(jButton5, new XYConstraints(0, 0,150, 20));
jPanel5.add(jPanel6, new XYConstraints(0,20, 150, 40));
jPanel6.add(jButton6, new XYConstraints(0, 0,150, 20));
jPanel6.add(jPanel7, new XYConstraints(0, 20, 150, 20));
jPanel7.add(jButton7, new XYConstraints(0, 0,150, 20));
jPanel1.add(jButton10, new XYConstraints(14, 31, -1, -1));
jPanel1.add(jButton11, new XYConstraints(17, 62, 85, 26));
contentPane.add(jPanel8, BorderLayout.CENTER);
jPanel8.add(jLabel1, new XYConstraints(34, 55, 147, 35));
jPanel8.add(jLabel2, new XYConstraints(33, 119, 148, 36));
}
//File | Exit action performed
public void jMenuFileExit_actionPerformed(ActionEvent e) {
System.exit(0);
}
//Help | About action performed
public void jMenuHelpAbout_actionPerformed(ActionEvent e) {
}
//Overridden so we can exit when window is closed
protected void processWindowEvent(WindowEvent e) {
super.processWindowEvent(e);
if (e.getID() == WindowEvent.WINDOW_CLOSING) {
jMenuFileExit_actionPerformed(null);
}
}