1 2 package org.netbeans.modules.form.layoutdesign; 3 4 public class ALT_ParallelPosition12 extends javax.swing.JFrame { 5 6 7 public ALT_ParallelPosition12() { 8 initComponents(); 9 } 10 11 16 private void initComponents() { 18 jToggleButton1 = new javax.swing.JToggleButton (); 19 jButton1 = new javax.swing.JButton (); 20 jButton2 = new javax.swing.JButton (); 21 22 setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); 23 jToggleButton1.setText("jToggleButton1jToggleButton1"); 24 25 jButton1.setText("jButton1"); 26 27 jButton2.setText("jButton2"); 28 29 org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane()); 30 getContentPane().setLayout(layout); 31 layout.setHorizontalGroup( 32 layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) 33 .add(org.jdesktop.layout.GroupLayout.LEADING, layout.createSequentialGroup() 34 .addContainerGap() 35 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false) 36 .add(org.jdesktop.layout.GroupLayout.LEADING, layout.createSequentialGroup() 37 .add(jButton1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 85, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) 38 .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) 39 .add(jButton2, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) 40 .add(jToggleButton1)) 41 .addContainerGap(211, Short.MAX_VALUE)) 42 ); 43 layout.setVerticalGroup( 44 layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) 45 .add(org.jdesktop.layout.GroupLayout.LEADING, layout.createSequentialGroup() 46 .addContainerGap() 47 .add(jToggleButton1) 48 .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) 49 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) 50 .add(jButton2) 51 .add(jButton1)) 52 .addContainerGap(237, Short.MAX_VALUE)) 53 ); 54 pack(); 55 } 57 60 public static void main(String args[]) { 61 java.awt.EventQueue.invokeLater(new Runnable () { 62 public void run() { 63 new ALT_ParallelPosition12().setVisible(true); 64 } 65 }); 66 } 67 68 private javax.swing.JButton jButton1; 70 private javax.swing.JButton jButton2; 71 private javax.swing.JToggleButton jToggleButton1; 72 74 } 75 | Popular Tags |