javatips.net counter

Java Examples for javax.swing.DefaultComboBoxModel

The following java examples will help you to understand the usage of javax.swing.DefaultComboBoxModel. These source code samples are taken from different open source projects.

Example 1
Project: MatrixMover-master  File: GeneratorSetupPanel.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    java.awt.GridBagConstraints gridBagConstraints;
    cbGenerator = new javax.swing.JComboBox();
    bConfigGenerator = new javax.swing.JButton();
    cbEffect = new javax.swing.JComboBox();
    bConfigEffect = new javax.swing.JButton();
    sIntensity = new javax.swing.JSlider();
    jLabel = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    cbMixer = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    setMaximumSize(new java.awt.Dimension(32767, 160));
    setMinimumSize(new java.awt.Dimension(10, 160));
    setPreferredSize(new java.awt.Dimension(300, 160));
    setRequestFocusEnabled(false);
    setLayout(new java.awt.GridBagLayout());
    cbGenerator.setFont(new java.awt.Font("Dialog", 0, 12));
    cbGenerator.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbGenerator.setMinimumSize(new java.awt.Dimension(80, 20));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(0, 10, 0, 5);
    add(cbGenerator, gridBagConstraints);
    // NOI18N
    bConfigGenerator.setFont(new java.awt.Font("Dialog", 0, 12));
    bConfigGenerator.setText("Config Generator");
    bConfigGenerator.setMaximumSize(new java.awt.Dimension(140, 25));
    bConfigGenerator.setMinimumSize(new java.awt.Dimension(140, 25));
    bConfigGenerator.setPreferredSize(new java.awt.Dimension(140, 25));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(5, 10, 5, 5);
    add(bConfigGenerator, gridBagConstraints);
    cbEffect.setFont(new java.awt.Font("Dialog", 0, 12));
    cbEffect.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbEffect.setMinimumSize(new java.awt.Dimension(80, 20));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(0, 10, 0, 5);
    add(cbEffect, gridBagConstraints);
    bConfigEffect.setFont(new java.awt.Font("Dialog", 0, 12));
    bConfigEffect.setText("Config Effect");
    bConfigEffect.setMaximumSize(new java.awt.Dimension(140, 25));
    bConfigEffect.setMinimumSize(new java.awt.Dimension(140, 25));
    bConfigEffect.setPreferredSize(new java.awt.Dimension(140, 25));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(5, 10, 5, 5);
    add(bConfigEffect, gridBagConstraints);
    sIntensity.setFont(new java.awt.Font("Dialog", 0, 12));
    sIntensity.setMaximum(255);
    sIntensity.setValue(255);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.gridheight = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 10, 0, 5);
    add(sIntensity, gridBagConstraints);
    jLabel.setFont(new java.awt.Font("Dialog", 0, 12));
    jLabel.setText("Effect Generator:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(5, 5, 5, 5);
    add(jLabel, gridBagConstraints);
    jLabel2.setFont(new java.awt.Font("Dialog", 0, 12));
    jLabel2.setText("Mixer");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(5, 5, 5, 5);
    add(jLabel2, gridBagConstraints);
    cbMixer.setFont(new java.awt.Font("Dialog", 0, 12));
    cbMixer.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbMixer.setMinimumSize(new java.awt.Dimension(80, 20));
    cbMixer.setOpaque(false);
    cbMixer.setPreferredSize(new java.awt.Dimension(155, 20));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(5, 10, 5, 5);
    add(cbMixer, gridBagConstraints);
    jLabel3.setFont(new java.awt.Font("Dialog", 0, 12));
    jLabel3.setText("Effect");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(5, 5, 5, 5);
    add(jLabel3, gridBagConstraints);
}
Example 2
Project: goworks-master  File: FormatWrapping.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    java.awt.GridBagConstraints gridBagConstraints;
    scrollPane = new javax.swing.JScrollPane();
    panel1 = new javax.swing.JPanel();
    lblMethodParameters = new javax.swing.JLabel();
    cmbMethodParameters = new javax.swing.JComboBox();
    lblMethodCallArguments = new javax.swing.JLabel();
    cmbMethodCallArguments = new javax.swing.JComboBox();
    lblChainedMethodCalls = new javax.swing.JLabel();
    cmbChainedMethodCalls = new javax.swing.JComboBox();
    lblArrayInitializer = new javax.swing.JLabel();
    cmbArrayInitializer = new javax.swing.JComboBox();
    lblFor = new javax.swing.JLabel();
    cmbFor = new javax.swing.JComboBox();
    lblForStatement = new javax.swing.JLabel();
    cmbForStatement = new javax.swing.JComboBox();
    lblIfStatement = new javax.swing.JLabel();
    cmbIfStatement = new javax.swing.JComboBox();
    lblWhileStatement = new javax.swing.JLabel();
    cmbWhileStatement = new javax.swing.JComboBox();
    lblDoWhileStatement = new javax.swing.JLabel();
    cmbDoWhileStatement = new javax.swing.JComboBox();
    lblEnumConstants = new javax.swing.JLabel();
    cmbEnumConstants = new javax.swing.JComboBox();
    lblBinaryOperators = new javax.swing.JLabel();
    cmbBinaryOperators = new javax.swing.JComboBox();
    lblTernaryOperators = new javax.swing.JLabel();
    cmbTernaryOperators = new javax.swing.JComboBox();
    lblAssignmentOperators = new javax.swing.JLabel();
    cmbAssignmentOperators = new javax.swing.JComboBox();
    // NOI18N
    setName(org.openide.util.NbBundle.getMessage(FormatWrapping.class, "LBL_Wrapping"));
    setOpaque(false);
    setLayout(new java.awt.BorderLayout());
    scrollPane.setMinimumSize(new java.awt.Dimension(212, 300));
    scrollPane.setPreferredSize(new java.awt.Dimension(240, 500));
    panel1.setOpaque(false);
    panel1.setLayout(new java.awt.GridBagLayout());
    lblMethodParameters.setText("Method Parameters:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(8, 8, 4, 0);
    panel1.add(lblMethodParameters, gridBagConstraints);
    cmbMethodParameters.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(8, 6, 4, 8);
    panel1.add(cmbMethodParameters, gridBagConstraints);
    lblMethodCallArguments.setText("Method Call Arguments:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblMethodCallArguments, gridBagConstraints);
    cmbMethodCallArguments.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbMethodCallArguments, gridBagConstraints);
    lblChainedMethodCalls.setText("Chained Method Calls:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblChainedMethodCalls, gridBagConstraints);
    cmbChainedMethodCalls.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbChainedMethodCalls, gridBagConstraints);
    lblArrayInitializer.setText("Array Initializer:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblArrayInitializer, gridBagConstraints);
    cmbArrayInitializer.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbArrayInitializer, gridBagConstraints);
    lblFor.setText("For:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblFor, gridBagConstraints);
    cmbFor.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbFor, gridBagConstraints);
    lblForStatement.setText("For Statement:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblForStatement, gridBagConstraints);
    cmbForStatement.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbForStatement, gridBagConstraints);
    lblIfStatement.setText("If Statement:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblIfStatement, gridBagConstraints);
    cmbIfStatement.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbIfStatement, gridBagConstraints);
    lblWhileStatement.setText("While Statement:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblWhileStatement, gridBagConstraints);
    cmbWhileStatement.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbWhileStatement, gridBagConstraints);
    lblDoWhileStatement.setText("Do ... While Statement:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblDoWhileStatement, gridBagConstraints);
    cmbDoWhileStatement.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbDoWhileStatement, gridBagConstraints);
    lblEnumConstants.setText("Enum Constants:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblEnumConstants, gridBagConstraints);
    cmbEnumConstants.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbEnumConstants, gridBagConstraints);
    lblBinaryOperators.setText("Binary Operators:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblBinaryOperators, gridBagConstraints);
    cmbBinaryOperators.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbBinaryOperators, gridBagConstraints);
    lblTernaryOperators.setText("Ternary Operators:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblTernaryOperators, gridBagConstraints);
    cmbTernaryOperators.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbTernaryOperators, gridBagConstraints);
    lblAssignmentOperators.setText("Assignment Operators:");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 8, 4, 0);
    panel1.add(lblAssignmentOperators, gridBagConstraints);
    cmbAssignmentOperators.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.insets = new java.awt.Insets(0, 6, 4, 8);
    panel1.add(cmbAssignmentOperators, gridBagConstraints);
    scrollPane.setViewportView(panel1);
    add(scrollPane, java.awt.BorderLayout.CENTER);
}
Example 3
Project: QuaquaOld-master  File: AlignmentTest.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc=" Generated Code ">//GEN-BEGIN:initComponents
private void initComponents() {
    java.awt.GridBagConstraints gridBagConstraints;
    jPanel1 = new javax.swing.JPanel();
    jLabel1 = new javax.swing.JLabel();
    jButton1 = new javax.swing.JButton();
    jCheckBox1 = new javax.swing.JCheckBox();
    jRadioButton1 = new javax.swing.JRadioButton();
    jComboBox1 = new javax.swing.JComboBox();
    jComboBox2 = new javax.swing.JComboBox();
    jTextField1 = new javax.swing.JTextField();
    jButton2 = new javax.swing.JButton();
    jCheckBox2 = new javax.swing.JCheckBox();
    jRadioButton2 = new javax.swing.JRadioButton();
    jComboBox3 = new javax.swing.JComboBox();
    jComboBox4 = new javax.swing.JComboBox();
    jTextField2 = new javax.swing.JTextField();
    jButton3 = new javax.swing.JButton();
    jLabel3 = new javax.swing.JLabel();
    jLabel4 = new javax.swing.JLabel();
    jLabel5 = new javax.swing.JLabel();
    jLabel6 = new javax.swing.JLabel();
    jLabel7 = new javax.swing.JLabel();
    jLabel8 = new javax.swing.JLabel();
    jLabel9 = new javax.swing.JLabel();
    jPanel2 = new javax.swing.JPanel();
    jLabel2 = new javax.swing.JLabel();
    jButton4 = new javax.swing.JButton();
    jCheckBox3 = new javax.swing.JCheckBox();
    jRadioButton3 = new javax.swing.JRadioButton();
    jComboBox5 = new javax.swing.JComboBox();
    jComboBox6 = new javax.swing.JComboBox();
    jTextField3 = new javax.swing.JTextField();
    jButton5 = new javax.swing.JButton();
    jCheckBox4 = new javax.swing.JCheckBox();
    jRadioButton4 = new javax.swing.JRadioButton();
    jComboBox7 = new javax.swing.JComboBox();
    jComboBox8 = new javax.swing.JComboBox();
    jTextField4 = new javax.swing.JTextField();
    jButton6 = new javax.swing.JButton();
    jLabel10 = new javax.swing.JLabel();
    jLabel11 = new javax.swing.JLabel();
    jLabel12 = new javax.swing.JLabel();
    jLabel13 = new javax.swing.JLabel();
    jLabel14 = new javax.swing.JLabel();
    jLabel15 = new javax.swing.JLabel();
    jLabel16 = new javax.swing.JLabel();
    setLayout(new java.awt.GridLayout(0, 1));
    jPanel1.setLayout(new java.awt.GridBagLayout());
    jLabel1.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel1, gridBagConstraints);
    jButton1.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jButton1, gridBagConstraints);
    jCheckBox1.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jCheckBox1, gridBagConstraints);
    jRadioButton1.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jRadioButton1, gridBagConstraints);
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jComboBox1, gridBagConstraints);
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jComboBox2, gridBagConstraints);
    jTextField1.setColumns(10);
    jTextField1.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jTextField1, gridBagConstraints);
    jButton2.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jButton2, gridBagConstraints);
    jCheckBox2.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jCheckBox2, gridBagConstraints);
    jRadioButton2.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jRadioButton2, gridBagConstraints);
    jComboBox3.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jComboBox3, gridBagConstraints);
    jComboBox4.setEditable(true);
    jComboBox4.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jComboBox4, gridBagConstraints);
    jTextField2.setColumns(10);
    jTextField2.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jTextField2, gridBagConstraints);
    jButton3.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jButton3, gridBagConstraints);
    jLabel3.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel3, gridBagConstraints);
    jLabel4.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel4, gridBagConstraints);
    jLabel5.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel5, gridBagConstraints);
    jLabel6.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel6, gridBagConstraints);
    jLabel7.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel7, gridBagConstraints);
    jLabel8.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel8, gridBagConstraints);
    jLabel9.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel1.add(jLabel9, gridBagConstraints);
    add(jPanel1);
    jPanel2.setLayout(new java.awt.GridBagLayout());
    jLabel2.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel2.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel2, gridBagConstraints);
    jButton4.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jButton4.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jButton4, gridBagConstraints);
    jCheckBox3.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jCheckBox3.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jCheckBox3, gridBagConstraints);
    jRadioButton3.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jRadioButton3.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jRadioButton3, gridBagConstraints);
    jComboBox5.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jComboBox5.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jComboBox5, gridBagConstraints);
    jComboBox6.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jComboBox6.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jComboBox6, gridBagConstraints);
    jTextField3.setColumns(10);
    jTextField3.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jTextField3.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jTextField3, gridBagConstraints);
    jButton5.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jButton5.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jButton5, gridBagConstraints);
    jCheckBox4.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jCheckBox4.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jCheckBox4, gridBagConstraints);
    jRadioButton4.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jRadioButton4.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jRadioButton4, gridBagConstraints);
    jComboBox7.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jComboBox7.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jComboBox7, gridBagConstraints);
    jComboBox8.setEditable(true);
    jComboBox8.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jComboBox8.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Ångström H" }));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jComboBox8, gridBagConstraints);
    jTextField4.setColumns(10);
    jTextField4.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jTextField4.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jTextField4, gridBagConstraints);
    jButton6.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jButton6.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jButton6, gridBagConstraints);
    jLabel10.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel10.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel10, gridBagConstraints);
    jLabel11.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel11.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel11, gridBagConstraints);
    jLabel12.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel12.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel12, gridBagConstraints);
    jLabel13.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel13.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel13, gridBagConstraints);
    jLabel14.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel14.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel14, gridBagConstraints);
    jLabel15.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel15.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel15, gridBagConstraints);
    jLabel16.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    jLabel16.setText("Ångström H");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    jPanel2.add(jLabel16, gridBagConstraints);
    add(jPanel2);
}
Example 4
Project: gephi-master  File: EdgeTypePanel.java View source code
public void setup(final EdgeTypeBuilder.EdgeTypeFilter filter) {
    this.filter = filter;
    DefaultComboBoxModel comboBoxModel = new DefaultComboBoxModel();
    for (Object o : filter.getEdgeTypeLabels()) {
        comboBoxModel.addElement(o);
    }
    comboBox.setModel(comboBoxModel);
    if (comboBoxModel.getSize() > 0) {
        filter.setEdgeTypeLabel(comboBoxModel.getSelectedItem());
    }
}
Example 5
Project: javabuilders-master  File: DefaultComboBoxModelHandler.java View source code
/* (non-Javadoc)
	 * @see org.javabuilders.handler.ITypeHandlerAfterCreationProcessor#afterCreation(org.javabuilders.BuilderConfig, org.javabuilders.BuildProcess, org.javabuilders.Node, java.lang.String, java.util.Map)
	 */
public void afterCreation(BuilderConfig config, BuildProcess process, Node current, String key, Map<String, Object> typeDefinition) throws BuildException {
    @SuppressWarnings("unused") DefaultComboBoxModel model = (DefaultComboBoxModel) current.getMainObject();
    if (current.getContentNode() != null) {
        for (@SuppressWarnings("unused") String value : current.getContentNode().getChildValues().keySet()) {
        //TODO
        }
    }
}
Example 6
Project: korsakow-editor-master  File: MaxLinksCellEditor.java View source code
@Override
public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) {
    if (value == null)
        value = SnuResourceView.INFINITE;
    super.getTableCellEditorComponent(table, value, isSelected, row, column);
    //    	editor.setModel(new KComboboxModel(SnuResourceView.MAXLINKS_CHOICES, value));
    editor.setModel(new DefaultComboBoxModel(SnuResourceView.MAXLINKS_CHOICES));
    editor.setSelectedItem(value);
    editor.setForeground(Color.white);
    editor.setBackground(CodeCellEditor.SELECTION_BACKGROUND);
    editor.putClientProperty("ui.background2", null);
    ((JTextField) editor.getEditor().getEditorComponent()).setCaretColor(Color.white);
    return editor;
}
Example 7
Project: OTCAnalyser-master  File: SaveWindow.java View source code
static void updateLoad() {
    Object[] strings;
    try {
        LinkedHashMap<String, Search> savedSearches = (LinkedHashMap<String, Search>) Database.getSavedSearches();
        strings = (savedSearches.keySet()).toArray();
        MutableComboBoxModel<String> model = (MutableComboBoxModel<String>) Loadbox.getModel();
        ((DefaultComboBoxModel<String>) model).removeAllElements();
        for (Object i : strings) {
            model.addElement((String) i);
        }
    } catch (NullPointerException e) {
    }
}
Example 8
Project: swingx-master  File: SortControllerIssues.java View source code
/**
     * Issue #1156-swingx: sorter must use comparable if available
     * ListSortController
     */
@Test
public void testComparableComparatorList() {
    ListModel model = new DefaultComboBoxModel(new Integer[] { 10, 2 });
    ListSortController<ListModel> sorter = new ListSortController<ListModel>(model);
    List<SortKey> keys = new ArrayList<SortKey>();
    keys.add(new SortKey(0, SortOrder.ASCENDING));
    sorter.setSortKeys(keys);
    assertEquals(0, sorter.convertRowIndexToModel(1));
}
Example 9
Project: Viz-master  File: EdgeTypePanel.java View source code
public void setup(final EdgeTypeBuilder.EdgeTypeFilter filter) {
    this.filter = filter;
    DefaultComboBoxModel comboBoxModel = new DefaultComboBoxModel();
    for (Object o : filter.getEdgeTypeLabels()) {
        comboBoxModel.addElement(o);
    }
    comboBox.setModel(comboBoxModel);
    if (comboBoxModel.getSize() > 0) {
        filter.setEdgeTypeLabel(comboBoxModel.getSelectedItem());
    }
}
Example 10
Project: Joustick-master  File: JoySettings.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jComboBox1 = new javax.swing.JComboBox();
    jComboBox2 = new javax.swing.JComboBox();
    jComboBox3 = new javax.swing.JComboBox();
    jComboBox4 = new javax.swing.JComboBox();
    jComboBox5 = new javax.swing.JComboBox();
    jComboBox6 = new javax.swing.JComboBox();
    jComboBox7 = new javax.swing.JComboBox();
    jComboBox8 = new javax.swing.JComboBox();
    jComboBox9 = new javax.swing.JComboBox();
    jComboBox10 = new javax.swing.JComboBox();
    jComboBox11 = new javax.swing.JComboBox();
    jComboBox12 = new javax.swing.JComboBox();
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    jLabel4 = new javax.swing.JLabel();
    jLabel5 = new javax.swing.JLabel();
    jLabel6 = new javax.swing.JLabel();
    jLabel7 = new javax.swing.JLabel();
    jLabel8 = new javax.swing.JLabel();
    jLabel9 = new javax.swing.JLabel();
    jLabel10 = new javax.swing.JLabel();
    jLabel11 = new javax.swing.JLabel();
    jLabel12 = new javax.swing.JLabel();
    jSlider1 = new javax.swing.JSlider();
    jLabel13 = new javax.swing.JLabel();
    jComboBox13 = new javax.swing.JComboBox();
    jComboBox14 = new javax.swing.JComboBox();
    jComboBox15 = new javax.swing.JComboBox();
    jComboBox16 = new javax.swing.JComboBox();
    jComboBox17 = new javax.swing.JComboBox();
    jComboBox18 = new javax.swing.JComboBox();
    jComboBox19 = new javax.swing.JComboBox();
    jComboBox20 = new javax.swing.JComboBox();
    jComboBox21 = new javax.swing.JComboBox();
    jComboBox22 = new javax.swing.JComboBox();
    jComboBox23 = new javax.swing.JComboBox();
    jComboBox24 = new javax.swing.JComboBox();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    jButton3 = new javax.swing.JButton();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle("Ayarlar");
    setAlwaysOnTop(true);
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox1.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jComboBox1ActionPerformed(evt);
        }
    });
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox3.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox4.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox4.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jComboBox4ActionPerformed(evt);
        }
    });
    jComboBox5.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox6.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox7.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox8.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox9.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox10.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox11.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox12.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jLabel1.setText("Üçgen :");
    jLabel2.setText("Yuvarlak : ");
    jLabel3.setText("Çarpı : ");
    jLabel4.setText("Kare : ");
    jLabel5.setText("Sol Ãœst : ");
    jLabel6.setText("SaÄŸ Ãœst : ");
    jLabel7.setText("Sol Alt : ");
    jLabel8.setText("SaÄŸ Alt : ");
    jLabel9.setText("Select : ");
    jLabel10.setText("Start : ");
    jLabel11.setText("Sol joystick : ");
    jLabel12.setText("SaÄŸ Joystick : ");
    jSlider1.setMaximum(10);
    jSlider1.setPaintLabels(true);
    jSlider1.setPaintTicks(true);
    jLabel13.setText("İmleç Hızı : ");
    jComboBox13.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox14.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox14.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jComboBox14ActionPerformed(evt);
        }
    });
    jComboBox15.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox16.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox17.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox18.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox19.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox20.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox21.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox22.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox23.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jComboBox24.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Nothing", "Left Click", "Right Click", "Enter", "Back Space", "Tab", "Space", "Escape", "Pause", "Alt", "Ctrl", "Shift", "Home", "Page Up", "Page Down", "Caps Lock", "Num Lock", "Start Menu", "Task Manager", "Print Screen", "A", "B", "C", "Ç", "D", "E", "F", "G", "H", "I", "İ", "J", "K", "L", "M", "N", "O", "Ö", "P", "Q", "R", "S", "Ş", "T", "U", "Ü", "V", "W", "Y", "X", "Z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" }));
    jButton1.setText("Kaydet");
    jButton1.setVerifyInputWhenFocusTarget(false);
    jButton2.setText("Ä°ptal");
    jButton3.setText("Varsayılanlara dön");
    jButton3.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton3ActionPerformed(evt);
        }
    });
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jLabel1).addComponent(jLabel2).addComponent(jLabel3).addComponent(jLabel4).addComponent(jLabel5).addComponent(jLabel6).addComponent(jLabel7).addComponent(jLabel8).addComponent(jLabel9).addComponent(jLabel10).addComponent(jLabel11).addComponent(jLabel12).addComponent(jLabel13)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addComponent(jButton3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 73, Short.MAX_VALUE).addComponent(jButton2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton1)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(jComboBox12, 0, 158, Short.MAX_VALUE).addComponent(jComboBox9, 0, 158, Short.MAX_VALUE).addComponent(jComboBox5, 0, 158, Short.MAX_VALUE).addComponent(jComboBox6, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox7, 0, 158, Short.MAX_VALUE).addComponent(jComboBox8, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox3, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox4, 0, 158, Short.MAX_VALUE).addComponent(jComboBox2, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox1, 0, 158, Short.MAX_VALUE).addComponent(jComboBox10, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox11, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(jComboBox17, 0, 158, Short.MAX_VALUE).addComponent(jComboBox24, 0, 158, Short.MAX_VALUE).addComponent(jComboBox20, 0, 158, Short.MAX_VALUE).addComponent(jComboBox21, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox22, 0, 158, Short.MAX_VALUE).addComponent(jComboBox23, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox18, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox19, 0, 158, Short.MAX_VALUE).addComponent(jComboBox13, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox14, 0, 158, Short.MAX_VALUE).addComponent(jComboBox16, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBox15, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))).addComponent(jSlider1, javax.swing.GroupLayout.Alignment.TRAILING, 0, 0, Short.MAX_VALUE)).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel1).addComponent(jComboBox14, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel2).addComponent(jComboBox13, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel3).addComponent(jComboBox19, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel4).addComponent(jComboBox18, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel5).addComponent(jComboBox22, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel6).addComponent(jComboBox23, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel7).addComponent(jComboBox20, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel8).addComponent(jComboBox21, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel9).addComponent(jComboBox24, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel10).addComponent(jComboBox16, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox12, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel11).addComponent(jComboBox17, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox11, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel12).addComponent(jComboBox15, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel13).addComponent(jSlider1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1).addComponent(jButton2)).addComponent(jButton3)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    pack();
}
Example 11
Project: oobd-master  File: SKDSSwingPortConfiguration.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    jComboBoxParity = new javax.swing.JComboBox();
    jComboBoxBaudrate = new javax.swing.JComboBox();
    jComboBoxPortname = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    jComboBoxstopbits = new javax.swing.JComboBox();
    jLabel4 = new javax.swing.JLabel();
    jComboBoxDatabits = new javax.swing.JComboBox();
    jLabel5 = new javax.swing.JLabel();
    jComboBoxHandshake = new javax.swing.JComboBox();
    jLabel6 = new javax.swing.JLabel();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    jButton3 = new javax.swing.JButton();
    jScrollPane1 = new javax.swing.JScrollPane();
    jTextAreaPortConf = new javax.swing.JTextArea();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    // NOI18N
    setName("Form");
    setResizable(false);
    // NOI18N
    jLabel1.setName("jLabel1");
    // NOI18N
    jLabel2.setName("jLabel2");
    jComboBoxParity.setModel(new javax.swing.DefaultComboBoxModel(parity));
    // NOI18N
    jComboBoxParity.setName("jComboBoxParity");
    jComboBoxBaudrate.setModel(new javax.swing.DefaultComboBoxModel(baudrate));
    jComboBoxBaudrate.setName("jComboBoxBaudrate");
    jComboBoxPortname.setModel(new javax.swing.DefaultComboBoxModel(portname));
    jComboBoxPortname.setName("jComboBoxPortname");
    // NOI18N
    jLabel3.setName("jLabel3");
    jComboBoxstopbits.setModel(new javax.swing.DefaultComboBoxModel(stopbits));
    jComboBoxstopbits.setName("jComboBoxstopbits");
    // NOI18N
    jLabel4.setName("jLabel4");
    jComboBoxDatabits.setModel(new javax.swing.DefaultComboBoxModel(databits));
    jComboBoxDatabits.setName("jComboBoxDatabits");
    // NOI18N
    jLabel5.setName("jLabel5");
    jComboBoxHandshake.setModel(new javax.swing.DefaultComboBoxModel(handshake));
    jComboBoxHandshake.setName("jComboBoxHandshake");
    // NOI18N
    jLabel6.setName("jLabel6");
    javax.swing.ActionMap actionMap = org.jdesktop.application.Application.getInstance(skdsswing.SKDSSwingApp.class).getContext().getActionMap(SKDSSwingPortConfiguration.class, this);
    // NOI18N
    jButton1.setAction(actionMap.get("OkPortConfigurationDialog"));
    org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(skdsswing.SKDSSwingApp.class).getContext().getResourceMap(SKDSSwingPortConfiguration.class);
    // NOI18N
    jButton1.setText(resourceMap.getString("jButton1.text"));
    jButton1.setMaximumSize(new java.awt.Dimension(53, 23));
    jButton1.setMinimumSize(new java.awt.Dimension(53, 23));
    // NOI18N
    jButton1.setName("jButton1");
    // NOI18N
    jButton2.setAction(actionMap.get("closePortConfigurationDialog"));
    // NOI18N
    jButton2.setText(resourceMap.getString("jButton2.text"));
    // NOI18N
    jButton2.setName("jButton2");
    // NOI18N
    jButton3.setAction(actionMap.get("TestPortConfigurationButton"));
    // NOI18N
    jButton3.setText(resourceMap.getString("jButton3.text"));
    jButton3.setMaximumSize(new java.awt.Dimension(53, 23));
    jButton3.setMinimumSize(new java.awt.Dimension(53, 23));
    // NOI18N
    jButton3.setName("jButton3");
    // NOI18N
    jScrollPane1.setName("jScrollPane1");
    jTextAreaPortConf.setColumns(20);
    jTextAreaPortConf.setEditable(false);
    jTextAreaPortConf.setRows(5);
    // NOI18N
    jTextAreaPortConf.setName("jTextAreaPortConf");
    jScrollPane1.setViewportView(jTextAreaPortConf);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel1).addComponent(jLabel2).addComponent(jLabel3).addComponent(jLabel4).addComponent(jLabel6)).addGap(24, 24, 24).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(jComboBoxDatabits, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBoxstopbits, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBoxBaudrate, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBoxParity, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jComboBoxPortname, 0, 90, Short.MAX_VALUE))).addGroup(layout.createSequentialGroup().addComponent(jLabel5).addGap(18, 18, 18).addComponent(jComboBoxHandshake, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))).addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup().addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 55, Short.MAX_VALUE).addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 336, Short.MAX_VALUE)).addGroup(layout.createSequentialGroup().addGap(102, 102, 102).addComponent(jButton3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 177, Short.MAX_VALUE).addComponent(jButton2))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBoxPortname, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel6)).addGap(27, 27, 27).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel1).addComponent(jComboBoxBaudrate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(26, 26, 26).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel2).addComponent(jComboBoxParity, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(29, 29, 29).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel3).addComponent(jComboBoxstopbits, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(28, 28, 28).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBoxDatabits, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel4)).addGap(28, 28, 28).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel5).addComponent(jComboBoxHandshake, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))).addComponent(jScrollPane1)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 52, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jButton2).addComponent(jButton3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(23, 23, 23)));
    pack();
}
Example 12
Project: FreeRoute-master  File: ComboBoxClearance.java View source code
/**
     * Adjusts this combo box to p_new_clearance_matrix.
     */
public void adjust(ClearanceMatrix p_new_clearance_matrix) {
    int old_index = this.get_selected_class_index();
    this.class_arr = new ClearanceClass[p_new_clearance_matrix.get_class_count()];
    for (int i = 0; i < this.class_arr.length; ++i) {
        this.class_arr[i] = new ClearanceClass(p_new_clearance_matrix.get_name(i), i);
    }
    this.setModel(new javax.swing.DefaultComboBoxModel(this.class_arr));
    this.setSelectedIndex(Math.min(old_index, this.class_arr.length - 1));
}
Example 13
Project: Freerouting-master  File: ComboBoxClearance.java View source code
/**
     * Adjusts this combo box to p_new_clearance_matrix.
     */
public void adjust(ClearanceMatrix p_new_clearance_matrix) {
    int old_index = this.get_selected_class_index();
    this.class_arr = new ClearanceClass[p_new_clearance_matrix.get_class_count()];
    for (int i = 0; i < this.class_arr.length; ++i) {
        this.class_arr[i] = new ClearanceClass(p_new_clearance_matrix.get_name(i), i);
    }
    this.setModel(new javax.swing.DefaultComboBoxModel(this.class_arr));
    this.setSelectedIndex(Math.min(old_index, this.class_arr.length - 1));
}
Example 14
Project: GhostGrader-master  File: RemoveAssignmentPanel.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    assignmentList = new javax.swing.JComboBox();
    removeButton = new javax.swing.JButton();
    cancelButton = new javax.swing.JButton();
    jLabel1 = new javax.swing.JLabel();
    assignmentList.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    removeButton.setText("Remove");
    cancelButton.setText("Cancel");
    // NOI18N
    jLabel1.setFont(new java.awt.Font("Georgia", 0, 14));
    jLabel1.setText("Assignment Name:");
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(assignmentList, 0, 268, Short.MAX_VALUE).addContainerGap()).addGroup(layout.createSequentialGroup().addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(removeButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(cancelButton).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(assignmentList, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel1)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(removeButton).addComponent(cancelButton)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
}
Example 15
Project: Amon-master  File: FilterComboBox.java View source code
@SuppressWarnings({ "unchecked", "rawtypes" })
public void comboFilter(String enteredText) {
    List<String> filterArray = new ArrayList<String>();
    for (int i = 0; i < array.size(); i++) {
        if (array.get(i).toLowerCase().contains(enteredText.toLowerCase())) {
            filterArray.add(array.get(i));
        }
    }
    if (filterArray.size() > 0) {
        this.setModel(new DefaultComboBoxModel(filterArray.toArray()));
        this.setSelectedItem(enteredText);
        this.showPopup();
    } else {
        this.hidePopup();
    }
}
Example 16
Project: assertj-swing-master  File: JComboBoxes.java View source code
@RunsInEDT
public JComboBox createNew() {
    return execute(new GuiQuery<JComboBox>() {

        @Override
        protected JComboBox executeInEDT() {
            JComboBox comboBox = new JComboBox();
            comboBox.setEditable(editable);
            if (!isNullOrEmpty(items)) {
                comboBox.setModel(new DefaultComboBoxModel(items));
            }
            comboBox.setName(name);
            comboBox.setSelectedIndex(selectedIndex);
            return comboBox;
        }
    });
}
Example 17
Project: chromecastplayer-master  File: ChromecastServiceDiscovery.java View source code
public static void start() throws IOException {
    final DefaultComboBoxModel<CombolistEntry> comboBoxModel = ComboBoxFactory.instance();
    JmDNS jmDns = JmDNS.create();
    jmDns.addServiceListener(serviceType, new ServiceListener() {

        @Override
        public void serviceAdded(ServiceEvent event) {
            final String mDNSName = buildmDNSName(event.getInfo());
            LOGGER.log(Level.INFO, "found chromecast device {0} -> adding to list", mDNSName);
            comboBoxModel.addElement(new CombolistEntry(mDNSName, ChromecastPlayer.instance()));
        }

        @Override
        public void serviceRemoved(ServiceEvent event) {
            final String mDNSName = buildmDNSName(event.getInfo());
            LOGGER.log(Level.INFO, "removing chromecast device {0} from list", mDNSName);
            System.out.println("Service removed " + event.getInfo());
        }

        @Override
        public void serviceResolved(ServiceEvent event) {
            System.out.println("Service resolved" + event.getInfo());
        }

        private String buildmDNSName(ServiceInfo serviceInfo) {
            return serviceInfo.getName() + "." + serviceInfo.getDomain();
        }
    });
}
Example 18
Project: codjo-data-process-master  File: FamilyComboBox.java View source code
private DefaultComboBoxModel getFamilyComboBoxModel(int repositoryId) throws RequestException {
    Map<String, String> familiesMap = FamilyClientHelper.getFamilyByRepositoryId(ctxt, repositoryId, showVisibleFamilyOnly);
    GenericRenderer rendererCombo = new GenericRenderer(familiesMap);
    setRenderer(rendererCombo);
    String[] familyIdTab = familiesMap.keySet().toArray(new String[familiesMap.keySet().size()]);
    Arrays.sort(familyIdTab, new FamilyComparator(familiesMap));
    return new DefaultComboBoxModel(familyIdTab);
}
Example 19
Project: codjo-standalone-common-master  File: TableComboBox.java View source code
/**
     * Reconstruit le contenu de la comboBox.
     */
private void init() {
    try {
        renderer = new TableNameRenderer(tableHome);
        if (listId != null) {
            model = new DefaultComboBoxModel(listId);
        } else {
            Object[] idList = renderer.getTableIdList(step, extraTableRef);
            model = new DefaultComboBoxModel(idList);
        }
        setRenderer(renderer);
        setModel(model);
    } catch (PersistenceException ex) {
        ex.printStackTrace();
    }
}
Example 20
Project: dependency-parsing-toolbox-master  File: CreatePSGPanel.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    pnlDependencyRelation = new javax.swing.JPanel();
    lblHead = new javax.swing.JLabel();
    cboHead = new javax.swing.JComboBox();
    lblModifier = new javax.swing.JLabel();
    cboModifier = new javax.swing.JComboBox();
    lblLabel = new javax.swing.JLabel();
    cboLabel = new javax.swing.JComboBox();
    btnAddEdge = new javax.swing.JToggleButton();
    pnlDependencyNode = new javax.swing.JPanel();
    lblWordForm = new javax.swing.JLabel();
    lblPOSTag = new javax.swing.JLabel();
    txtWordForm = new javax.swing.JTextField();
    btnAddNode = new javax.swing.JButton();
    cboPOSTag = new javax.swing.JComboBox();
    jLabel1 = new javax.swing.JLabel();
    cboCategory = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    jPanel1 = new javax.swing.JPanel();
    pnlDependencyRelation.setBorder(javax.swing.BorderFactory.createTitledBorder("Dependency Relation (Edge)"));
    lblHead.setText("Head");
    cboHead.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "ROOT" }));
    lblModifier.setText("Modifier");
    cboModifier.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "ROOT" }));
    lblLabel.setText("Label");
    cboLabel.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "PRED", "SUB", "OBJ", "HD" }));
    btnAddEdge.setText("Add");
    btnAddEdge.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            btnAddEdge_Click(evt);
        }
    });
    javax.swing.GroupLayout pnlDependencyRelationLayout = new javax.swing.GroupLayout(pnlDependencyRelation);
    pnlDependencyRelation.setLayout(pnlDependencyRelationLayout);
    pnlDependencyRelationLayout.setHorizontalGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(pnlDependencyRelationLayout.createSequentialGroup().addGap(22, 22, 22).addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addGroup(pnlDependencyRelationLayout.createSequentialGroup().addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 233, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btnAddEdge)).addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(pnlDependencyRelationLayout.createSequentialGroup().addComponent(lblHead).addGap(30, 30, 30).addComponent(cboHead, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addGroup(pnlDependencyRelationLayout.createSequentialGroup().addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(lblModifier).addComponent(lblLabel)).addGap(18, 18, 18).addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(cboModifier, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(cboLabel, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))).addGap(31, 31, 31)));
    pnlDependencyRelationLayout.setVerticalGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(pnlDependencyRelationLayout.createSequentialGroup().addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(lblHead).addComponent(cboHead, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(lblModifier).addComponent(cboModifier, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(pnlDependencyRelationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(lblLabel).addComponent(cboLabel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(btnAddEdge).addGap(0, 6, Short.MAX_VALUE)));
    pnlDependencyNode.setBorder(javax.swing.BorderFactory.createTitledBorder("Dependency Node"));
    lblWordForm.setText("Word Form");
    lblPOSTag.setText("POS Tag");
    btnAddNode.setText("Add");
    btnAddNode.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            btnAddNode_Click(evt);
        }
    });
    cboPOSTag.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "N", "V" }));
    jLabel1.setText("Category");
    cboCategory.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "S", "NP", "VP" }));
    javax.swing.GroupLayout pnlDependencyNodeLayout = new javax.swing.GroupLayout(pnlDependencyNode);
    pnlDependencyNode.setLayout(pnlDependencyNodeLayout);
    pnlDependencyNodeLayout.setHorizontalGroup(pnlDependencyNodeLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(pnlDependencyNodeLayout.createSequentialGroup().addGap(23, 23, 23).addGroup(pnlDependencyNodeLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addGroup(pnlDependencyNodeLayout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(cboCategory, javax.swing.GroupLayout.PREFERRED_SIZE, 234, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(pnlDependencyNodeLayout.createSequentialGroup().addGap(0, 0, Short.MAX_VALUE).addComponent(btnAddNode)).addGroup(javax.swing.GroupLayout.Alignment.LEADING, pnlDependencyNodeLayout.createSequentialGroup().addComponent(lblPOSTag).addGap(18, 18, 18).addComponent(cboPOSTag, javax.swing.GroupLayout.PREFERRED_SIZE, 230, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(javax.swing.GroupLayout.Alignment.LEADING, pnlDependencyNodeLayout.createSequentialGroup().addComponent(lblWordForm).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(txtWordForm, javax.swing.GroupLayout.PREFERRED_SIZE, 236, javax.swing.GroupLayout.PREFERRED_SIZE))).addGap(25, 25, 25)));
    pnlDependencyNodeLayout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] { cboCategory, cboPOSTag });
    pnlDependencyNodeLayout.setVerticalGroup(pnlDependencyNodeLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(pnlDependencyNodeLayout.createSequentialGroup().addGroup(pnlDependencyNodeLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(lblWordForm).addComponent(txtWordForm, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(pnlDependencyNodeLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(lblPOSTag).addComponent(cboPOSTag, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(pnlDependencyNodeLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(cboCategory, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel1)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(btnAddNode).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    // NOI18N
    jLabel2.setFont(new java.awt.Font("Tahoma", 1, 18));
    jLabel2.setText("Create Phrase-Structure Graph");
    jPanel1.setBorder(javax.swing.BorderFactory.createEtchedBorder());
    jPanel1.setPreferredSize(new java.awt.Dimension(380, 2));
    javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 0, Short.MAX_VALUE));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 0, Short.MAX_VALUE));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(pnlDependencyNode, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(18, 18, Short.MAX_VALUE).addComponent(pnlDependencyRelation, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, 720, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addComponent(jLabel2).addGap(0, 0, Short.MAX_VALUE))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jLabel2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(pnlDependencyNode, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(pnlDependencyRelation, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap(199, Short.MAX_VALUE)));
}
Example 21
Project: dotalys-cli-master  File: HistogramComponent.java View source code
public JComboBox<String> getAttributeBox() {
    if (attributeBox == null) {
        attributeBox = new JComboBox<String>(new DefaultComboBoxModel<String>()) {

            /**
                 *
                 */
            private static final long serialVersionUID = 7315048556938443236L;

            /**
                 * @inherited <p>
                 */
            @Override
            public Dimension getMaximumSize() {
                final Dimension max = super.getMaximumSize();
                max.height = getPreferredSize().height;
                return max;
            }
        };
        //First add the known values
        attributeBox.addItem(Statics.EXPERIENCE);
        attributeBox.addItem(Statics.GOLD);
        attributeBox.addItem(Statics.DEATHS);
        attributeBox.addItem(DEBUG_DIVIDER);
        attributeBox.setEnabled(false);
        attributeBox.setAlignmentX(Component.CENTER_ALIGNMENT);
        attributeBox.addActionListener(new ActionListener() {

            @Override
            public void actionPerformed(ActionEvent e) {
                if (!attributeBox.getSelectedItem().equals(DEBUG_DIVIDER)) {
                    final JFreeChart data = ChartCreator.createPlayerHistogram((String) attributeBox.getSelectedItem(), playerBox.getSelectedValuesList(), appState);
                    getChartPanel().setChart(data);
                }
            }
        });
    }
    return attributeBox;
}
Example 22
Project: eXist-1.4.x-master  File: AbstractPolicyEditor.java View source code
protected ComboBoxModel getComboModel() {
    boolean isPolicy = node instanceof PolicyNode;
    DefaultComboBoxModel model = new DefaultComboBoxModel();
    Set algorithms = StandardCombiningAlgFactory.getFactory().getStandardAlgorithms();
    for (Iterator it = algorithms.iterator(); it.hasNext(); ) {
        CombiningAlgorithm algorithm = (CombiningAlgorithm) it.next();
        if (isPolicy) {
            if (algorithm instanceof RuleCombiningAlgorithm) {
                String abbreviatedID = abbrev.getAbbreviatedCombiningID(algorithm.getIdentifier());
                model.addElement(abbreviatedID);
            }
        } else if (algorithm instanceof PolicyCombiningAlgorithm) {
            String abbreviatedID = abbrev.getAbbreviatedCombiningID(algorithm.getIdentifier());
            model.addElement(abbreviatedID);
        }
    }
    return model;
}
Example 23
Project: fest-swing-1.x-master  File: JComboBoxes.java View source code
@RunsInEDT
public JComboBox createNew() {
    return execute(new GuiQuery<JComboBox>() {

        @Override
        protected JComboBox executeInEDT() {
            JComboBox comboBox = new JComboBox();
            comboBox.setEditable(editable);
            if (!isNullOrEmpty(items)) {
                comboBox.setModel(new DefaultComboBoxModel(items));
            }
            comboBox.setName(name);
            comboBox.setSelectedIndex(selectedIndex);
            return comboBox;
        }
    });
}
Example 24
Project: Icy-Kernel-master  File: SequenceResizePanel.java View source code
@Override
protected void initialize() {
    super.initialize();
    lblFilterType = new JLabel("Filter type");
    GridBagConstraints gbc_lblFilterType = new GridBagConstraints();
    gbc_lblFilterType.fill = GridBagConstraints.BOTH;
    gbc_lblFilterType.insets = new Insets(0, 0, 5, 5);
    gbc_lblFilterType.gridx = 5;
    gbc_lblFilterType.gridy = 0;
    settingPanel.add(lblFilterType, gbc_lblFilterType);
    filterComboBox = new JComboBox();
    filterComboBox.setModel(new DefaultComboBoxModel(new String[] { "Nearest", "Bilinear", "Bicubic" }));
    filterComboBox.setSelectedIndex(1);
    GridBagConstraints gbc_filterComboBox = new GridBagConstraints();
    gbc_filterComboBox.insets = new Insets(0, 0, 5, 5);
    gbc_filterComboBox.fill = GridBagConstraints.HORIZONTAL;
    gbc_filterComboBox.gridx = 5;
    gbc_filterComboBox.gridy = 1;
    settingPanel.add(filterComboBox, gbc_filterComboBox);
}
Example 25
Project: jdal-master  File: ComboLinker.java View source code
/**
	 * [email protected]}
	 * @see java.awt.event.ActionListener#actionPerformed(java.awt.event.ActionEvent)
	 */
@SuppressWarnings("unchecked")
public void actionPerformed(ActionEvent e) {
    Object selected = primary.getSelectedItem();
    if (selected != null) {
        BeanWrapper wrapper = PropertyAccessorFactory.forBeanPropertyAccess(selected);
        Collection<Object> collection = (Collection<Object>) wrapper.getPropertyValue(propertyName);
        DefaultComboBoxModel model = new DefaultComboBoxModel(new Vector<Object>(collection));
        dependent.setModel(model);
    }
}
Example 26
Project: jhotdraw-master  File: CharacterSetAccessory.java View source code
public void fetchAvailableCharSets() {
    if (availableCharSets == null) {
        new BackgroundTask() {

            @Override
            public void construct() {
                SortedMap<String, Charset> sm = Charset.availableCharsets();
                LinkedList<String> list = new LinkedList<String>();
                for (String key : sm.keySet()) {
                    if (!key.startsWith("x-")) {
                        list.add(key);
                    }
                }
                availableCharSets = list.toArray();
                Arrays.sort(availableCharSets);
            }

            @Override
            public void finished() {
                Object selectedItem = charSetCombo.getSelectedItem();
                charSetCombo.setModel(new DefaultComboBoxModel(availableCharSets));
                charSetCombo.setSelectedItem(selectedItem);
                charSetCombo.setEnabled(true);
            }
        }.start();
    } else {
        Object selectedItem = charSetCombo.getSelectedItem();
        charSetCombo.setModel(new DefaultComboBoxModel(availableCharSets));
        charSetCombo.setSelectedItem(selectedItem);
        charSetCombo.setEnabled(true);
    }
}
Example 27
Project: LIMO-master  File: NewOrDuplicatedLegTypePanel.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
private void initComponents() {
    buttonGroup1 = new javax.swing.ButtonGroup();
    rbFromScratch = new javax.swing.JRadioButton();
    rbCopyFrom = new javax.swing.JRadioButton();
    cmbLegType = new javax.swing.JComboBox();
    setLayout(new GridBagLayout());
    GridBagConstraints c = new GridBagConstraints();
    c.fill = GridBagConstraints.HORIZONTAL;
    c.weightx = 1;
    c.gridx = 0;
    c.gridy = 0;
    buttonGroup1.add(rbFromScratch);
    rbFromScratch.setText(LIMOResourceBundle.getString("FROM_SCRATCH"));
    add(rbFromScratch, c);
    rbFromScratch.setSelected(true);
    buttonGroup1.add(rbCopyFrom);
    rbCopyFrom.setText(LIMOResourceBundle.getString("COPY_EXISTING"));
    c.weightx = 1;
    c.gridx = 0;
    c.gridy = 1;
    add(rbCopyFrom, c);
    addActionListener();
    LegTypeService legTypeService = Lookup.getDefault().lookup(LegTypeService.class);
    lt = legTypeService.findAll();
    List<String> legTypeList = new ArrayList<>();
    lt.stream().forEach(( lt2) -> {
        legTypeList.add(lt2.getName());
    });
    cmbLegType.setModel(new javax.swing.DefaultComboBoxModel(legTypeList.toArray()));
    c.weightx = 1;
    c.gridx = 0;
    c.gridy = 2;
    add(cmbLegType, c);
    cmbLegType.setEnabled(false);
    if (lt.isEmpty()) {
        rbCopyFrom.setEnabled(false);
        cmbLegType.setEditable(false);
    }
}
Example 28
Project: niftyeditor-master  File: ImageModeComponent.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jPanel1 = new javax.swing.JPanel();
    jLabel1 = new javax.swing.JLabel();
    jComboBox1 = new javax.swing.JComboBox();
    setLayout(new java.awt.BorderLayout());
    jPanel1.setPreferredSize(new java.awt.Dimension(400, 25));
    jLabel1.setText("Select ImageMode");
    jPanel1.add(jLabel1);
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Normal", "SubImage", "Resize", "Sprite", "Sprite-Resize", "SubImage-Direct", "SubImage-Resize", "Repeat" }));
    jPanel1.add(jComboBox1);
    add(jPanel1, java.awt.BorderLayout.PAGE_START);
}
Example 29
Project: nmonvisualizer-master  File: VerboseGCPreParser.java View source code
@Override
protected void beforeDispose() {
    boolean existing = false;
    DefaultComboBoxModel<String> model = (DefaultComboBoxModel<String>) jvmNames.getModel();
    for (int i = 0; i < model.getSize(); i++) {
        if (model.getElementAt(i).equals(jvmNames.getSelectedItem())) {
            existing = true;
            break;
        }
    }
    if (!existing) {
        model.addElement((String) jvmNames.getSelectedItem());
    }
}
Example 30
Project: ocelot-master  File: CategoryCellEditor.java View source code
/*
	 * (non-Javadoc)
	 * @see javax.swing.DefaultCellEditor#getTableCellEditorComponent(javax.swing.JTable, java.lang.Object, boolean, int, int)
	 */
@Override
public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) {
    JComboBox<String> comboBox = (JComboBox<String>) super.getTableCellEditorComponent(table, value, isSelected, row, column);
    Vector<String> comboModel = new Vector<String>(Arrays.asList(LQIConstants.LQI_CATEGORIES_LIST));
    String currCat = "";
    if (value != null) {
        currCat = (String) value;
    }
    List<String> existingCat = ((LQIGridTableModel) table.getModel()).getUsedCategoryName();
    existingCat.remove(currCat);
    comboModel.removeAll(existingCat);
    comboBox.setModel(new DefaultComboBoxModel<>(comboModel));
    comboBox.setBackground(table.getCellRenderer(row, column).getTableCellRendererComponent(table, value, isSelected, true, row, column).getBackground());
    comboBox.setSelectedItem(currCat);
    return comboBox;
}
Example 31
Project: Pail-master  File: ServerTaskOptions.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new JLabel();
    action = new JComboBox();
    jLabel1.setText("Action");
    action.setModel(new DefaultComboBoxModel());
    GroupLayout layout = new GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jLabel1).addPreferredGap(ComponentPlacement.UNRELATED).addComponent(action, 0, 393, Short.MAX_VALUE).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(Alignment.BASELINE).addComponent(jLabel1).addComponent(action, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)).addContainerGap(212, Short.MAX_VALUE)));
}
Example 32
Project: triple-master  File: SetMapClientAction.java View source code
@Override
public void actionPerformed(final ActionEvent e) {
    final INode serverNode = m_clientMessenger.getServerNode();
    final DefaultComboBoxModel<String> model = new DefaultComboBoxModel<>();
    final JComboBox<String> combo = new JComboBox<>(model);
    model.addElement("");
    for (final String game : m_availableGames) {
        model.addElement(game);
    }
    if (serverNode == null || model.getSize() <= 1) {
        JOptionPane.showMessageDialog(m_parent, "No available games", "No available games", JOptionPane.ERROR_MESSAGE);
        return;
    }
    final int rVal = JOptionPane.showConfirmDialog(m_parent, combo, "Change Game To: ", JOptionPane.OK_CANCEL_OPTION);
    if (rVal != JOptionPane.OK_OPTION) {
        return;
    }
    final String name = (String) combo.getSelectedItem();
    if (name == null || name.length() <= 1) {
        return;
    }
    m_clientMessenger.changeServerGameTo(name);
}
Example 33
Project: lesk-wsd-dsm-master  File: CommandLineGUI.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jPanel1 = new javax.swing.JPanel();
    jButton1 = new javax.swing.JButton();
    jLabel1 = new javax.swing.JLabel();
    jPanel3 = new javax.swing.JPanel();
    jLabel3 = new javax.swing.JLabel();
    jComboBox1 = new javax.swing.JComboBox();
    jSeparator5 = new javax.swing.JSeparator();
    jLabel5 = new javax.swing.JLabel();
    jComboBox3 = new javax.swing.JComboBox();
    jPanel2 = new javax.swing.JPanel();
    jButton2 = new javax.swing.JButton();
    jLabel2 = new javax.swing.JLabel();
    jPanel4 = new javax.swing.JPanel();
    jLabel4 = new javax.swing.JLabel();
    jComboBox2 = new javax.swing.JComboBox();
    jSeparator6 = new javax.swing.JSeparator();
    jLabel13 = new javax.swing.JLabel();
    jComboBox7 = new javax.swing.JComboBox();
    jPanel6 = new javax.swing.JPanel();
    jButton3 = new javax.swing.JButton();
    jLabel6 = new javax.swing.JLabel();
    jSeparator1 = new javax.swing.JSeparator();
    jLabel7 = new javax.swing.JLabel();
    jComboBox4 = new javax.swing.JComboBox();
    jPanel7 = new javax.swing.JPanel();
    jButton4 = new javax.swing.JButton();
    jLabel8 = new javax.swing.JLabel();
    jPanel8 = new javax.swing.JPanel();
    jLabel9 = new javax.swing.JLabel();
    jComboBox5 = new javax.swing.JComboBox();
    jSeparator2 = new javax.swing.JSeparator();
    jLabel10 = new javax.swing.JLabel();
    jComboBox6 = new javax.swing.JComboBox();
    jPanel9 = new javax.swing.JPanel();
    jCheckBox1 = new javax.swing.JCheckBox();
    jSeparator3 = new javax.swing.JSeparator();
    jCheckBox2 = new javax.swing.JCheckBox();
    jPanel10 = new javax.swing.JPanel();
    jLabel11 = new javax.swing.JLabel();
    jSpinner1 = new javax.swing.JSpinner();
    jSeparator4 = new javax.swing.JSeparator();
    jLabel12 = new javax.swing.JLabel();
    jSpinner2 = new javax.swing.JSpinner();
    jCheckBox3 = new javax.swing.JCheckBox();
    jPanel5 = new javax.swing.JPanel();
    jButton5 = new javax.swing.JButton();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle("WSD-DSM-Lesk command line GUI");
    getContentPane().setLayout(new javax.swing.BoxLayout(getContentPane(), javax.swing.BoxLayout.PAGE_AXIS));
    jPanel1.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jButton1.setText("Select Input File");
    jButton1.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton1ActionPerformed(evt);
        }
    });
    jPanel1.add(jButton1);
    jLabel1.setText("no input file");
    jLabel1.setPreferredSize(new java.awt.Dimension(180, 17));
    jPanel1.add(jLabel1);
    getContentPane().add(jPanel1);
    jPanel3.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jLabel3.setText("Input type");
    jPanel3.add(jLabel3);
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "xml", "plain", "oldxml" }));
    jPanel3.add(jComboBox1);
    jPanel3.add(jSeparator5);
    jLabel5.setText("Reader type");
    jPanel3.add(jLabel5);
    jComboBox3.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "text", "sent", "doc" }));
    jPanel3.add(jComboBox3);
    getContentPane().add(jPanel3);
    jPanel2.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jButton2.setText("Select Output File");
    jButton2.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton2ActionPerformed(evt);
        }
    });
    jPanel2.add(jButton2);
    jLabel2.setText("no output file");
    jLabel2.setPreferredSize(new java.awt.Dimension(180, 17));
    jPanel2.add(jLabel2);
    getContentPane().add(jPanel2);
    jPanel4.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jLabel4.setText("Output type");
    jPanel4.add(jLabel4);
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "task:bn", "plain:bn", "task:wn", "task:bn" }));
    jPanel4.add(jComboBox2);
    jPanel4.add(jSeparator6);
    jLabel13.setText("Language");
    jPanel4.add(jLabel13);
    jComboBox7.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "en", "it", "es", "fr", "de" }));
    jPanel4.add(jComboBox7);
    getContentPane().add(jPanel4);
    jPanel6.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jButton3.setText("Select DSM File");
    jButton3.setActionCommand("Select DSM File");
    jButton3.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton3ActionPerformed(evt);
        }
    });
    jPanel6.add(jButton3);
    jLabel6.setText("no dsm file");
    jLabel6.setPreferredSize(new java.awt.Dimension(180, 17));
    jPanel6.add(jLabel6);
    jPanel6.add(jSeparator1);
    jLabel7.setText("DSM type");
    jPanel6.add(jLabel7);
    jComboBox4.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "lucene", "java" }));
    jPanel6.add(jComboBox4);
    getContentPane().add(jPanel6);
    jPanel7.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jButton4.setText("Select Sense Distribution Dir");
    jButton4.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton4ActionPerformed(evt);
        }
    });
    jPanel7.add(jButton4);
    jLabel8.setText("no SD dir");
    jLabel8.setPreferredSize(new java.awt.Dimension(180, 17));
    jPanel7.add(jLabel8);
    getContentPane().add(jPanel7);
    jPanel8.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jLabel9.setText("SD type");
    jPanel8.add(jLabel9);
    jComboBox5.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "prob", "occ", "prob_cross" }));
    jPanel8.add(jComboBox5);
    jPanel8.add(jSeparator2);
    jLabel10.setText("Wiki SD");
    jPanel8.add(jLabel10);
    jComboBox6.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "lev", "uni" }));
    jPanel8.add(jComboBox6);
    getContentPane().add(jPanel8);
    jPanel9.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jCheckBox1.setText("Stemming");
    jPanel9.add(jCheckBox1);
    jPanel9.add(jSeparator3);
    jCheckBox2.setSelected(true);
    jCheckBox2.setText("Gloss scoring");
    jPanel9.add(jCheckBox2);
    getContentPane().add(jPanel9);
    jPanel10.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));
    jLabel11.setText("Depth");
    jPanel10.add(jLabel11);
    jPanel10.add(jSpinner1);
    jPanel10.add(jSeparator4);
    jLabel12.setText("Context");
    jPanel10.add(jLabel12);
    jPanel10.add(jSpinner2);
    jCheckBox3.setText("max");
    jCheckBox3.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jCheckBox3ActionPerformed(evt);
        }
    });
    jPanel10.add(jCheckBox3);
    getContentPane().add(jPanel10);
    jPanel5.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.RIGHT));
    jButton5.setText("Generate CMD");
    jPanel5.add(jButton5);
    getContentPane().add(jPanel5);
    pack();
}
Example 34
Project: eurocarbdb-master  File: ProfilerOptionsDialog.java View source code
private void setData(ProfilerOptions opt) {
    java.util.Vector<String> dict_names = new Union<String>(thePlugin.getDictionaryNames());
    field_dictionaries.setListData(dict_names);
    for (int i = 0; i < opt.DICTIONARIES.length; i++) {
        int ind = dict_names.indexOf(opt.DICTIONARIES[i]);
        field_dictionaries.addSelectionInterval(ind, ind);
    }
    field_derivatization.setModel(new javax.swing.DefaultComboBoxModel(new String[] { MassOptions.NO_DERIVATIZATION, MassOptions.PERMETHYLATED, MassOptions.PERDMETHYLATED, MassOptions.PERACETYLATED, MassOptions.PERDACETYLATED }));
    field_derivatization.setSelectedItem(opt.DERIVATIZATION);
    field_reducingend.setModel(new javax.swing.DefaultComboBoxModel(new Union<String>().and("---").and(ResidueDictionary.getReducingEndsString()).and("Other...").toArray(new String[0])));
    field_reducingend.setSelectedItem(opt.REDUCING_END);
    if (opt.REDUCING_END.equals("XXX")) {
        field_reducingend.setSelectedItem("Other...");
        field_other_redend_name.setText(opt.OTHER_REDEND_NAME);
        field_other_redend_mass.setText("" + opt.OTHER_REDEND_MASS);
    } else {
        field_reducingend.setSelectedItem(opt.REDUCING_END);
        field_other_redend_name.setText("");
        field_other_redend_mass.setText("0");
    }
}
Example 35
Project: jmeld-master  File: PanelDialogForm.java View source code
/** This method is called from within the constructor to
   * initialize the form.
   * WARNING: Do NOT modify this code. The content of this method is
   * always regenerated by the Form Editor.
   */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    jTabbedPane1 = new javax.swing.JTabbedPane();
    jPanel1 = new javax.swing.JPanel();
    fileLeftLabel = new javax.swing.JLabel();
    fileRightLabel = new javax.swing.JLabel();
    fileBrowseLeftButton = new javax.swing.JButton();
    fileBrowseRightButton = new javax.swing.JButton();
    fileLeftComboBox = new javax.swing.JComboBox();
    fileRightComboBox = new javax.swing.JComboBox();
    fileFilterComboBox = new javax.swing.JComboBox();
    fileLeftReadonlyCheckBox = new javax.swing.JCheckBox();
    fileRightReadonlyCheckBox = new javax.swing.JCheckBox();
    filterLabel = new javax.swing.JLabel();
    jPanel2 = new javax.swing.JPanel();
    jLabel3 = new javax.swing.JLabel();
    jLabel4 = new javax.swing.JLabel();
    jComboBox3 = new javax.swing.JComboBox();
    jComboBox4 = new javax.swing.JComboBox();
    jButton5 = new javax.swing.JButton();
    jButton6 = new javax.swing.JButton();
    jCheckBox1 = new javax.swing.JCheckBox();
    jCheckBox2 = new javax.swing.JCheckBox();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    fileLeftLabel.setFont(new java.awt.Font("Dialog", 1, 11));
    fileLeftLabel.setText("Left");
    fileRightLabel.setFont(new java.awt.Font("Dialog", 1, 11));
    fileRightLabel.setText("Right");
    fileBrowseLeftButton.setText("Browse");
    fileBrowseRightButton.setText("Browse");
    fileLeftComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    fileRightComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    fileFilterComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    fileLeftReadonlyCheckBox.setText("Left readonly");
    fileRightReadonlyCheckBox.setText("Right readonly");
    filterLabel.setFont(new java.awt.Font("Dialog", 1, 11));
    filterLabel.setText("Filter");
    org.jdesktop.layout.GroupLayout jPanel1Layout = new org.jdesktop.layout.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jPanel1Layout.createSequentialGroup().addContainerGap().add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jPanel1Layout.createSequentialGroup().add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(fileRightLabel).add(fileLeftLabel)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(fileRightComboBox, 0, 261, Short.MAX_VALUE).add(fileLeftComboBox, 0, 261, Short.MAX_VALUE))).add(jPanel1Layout.createSequentialGroup().add(filterLabel).add(11, 11, 11).add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(fileLeftReadonlyCheckBox).add(fileFilterComboBox, 0, 263, Short.MAX_VALUE).add(fileRightReadonlyCheckBox)))).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(fileBrowseRightButton).add(fileBrowseLeftButton)).addContainerGap()));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jPanel1Layout.createSequentialGroup().addContainerGap().add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(fileLeftLabel).add(fileLeftComboBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(fileBrowseLeftButton)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(fileRightComboBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(fileRightLabel).add(fileBrowseRightButton)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(fileFilterComboBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(filterLabel)).add(18, 18, 18).add(fileLeftReadonlyCheckBox).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(fileRightReadonlyCheckBox).addContainerGap(57, Short.MAX_VALUE)));
    jPanel1Layout.linkSize(new java.awt.Component[] { fileFilterComboBox, fileLeftComboBox, fileRightComboBox }, org.jdesktop.layout.GroupLayout.VERTICAL);
    jTabbedPane1.addTab("File comparison", jPanel1);
    jLabel3.setText("Left");
    jLabel4.setText("Right");
    jComboBox3.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    jComboBox4.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    jButton5.setText("Browse");
    jButton6.setText("Browse");
    jCheckBox1.setText("Left readonly");
    jCheckBox2.setText("Right readonly");
    org.jdesktop.layout.GroupLayout jPanel2Layout = new org.jdesktop.layout.GroupLayout(jPanel2);
    jPanel2.setLayout(jPanel2Layout);
    jPanel2Layout.setHorizontalGroup(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jPanel2Layout.createSequentialGroup().addContainerGap().add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jLabel3).add(jLabel4)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jCheckBox2).add(jCheckBox1).add(jPanel2Layout.createSequentialGroup().add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(org.jdesktop.layout.GroupLayout.TRAILING, jComboBox4, 0, 263, Short.MAX_VALUE).add(org.jdesktop.layout.GroupLayout.TRAILING, jComboBox3, 0, 263, Short.MAX_VALUE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(org.jdesktop.layout.GroupLayout.TRAILING, jButton5).add(org.jdesktop.layout.GroupLayout.TRAILING, jButton6)))).addContainerGap()));
    jPanel2Layout.setVerticalGroup(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jPanel2Layout.createSequentialGroup().addContainerGap().add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel3).add(jButton5).add(jComboBox3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel4).add(jButton6).add(jComboBox4, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).add(18, 18, 18).add(jCheckBox1).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jCheckBox2).addContainerGap(86, Short.MAX_VALUE)));
    jTabbedPane1.addTab("Directory comparison", jPanel2);
    jButton1.setText("Cancel");
    jButton2.setText("OK");
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().add(124, 124, 124).add(jButton2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 70, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jButton1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 70, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).add(layout.createSequentialGroup().addContainerGap().add(jTabbedPane1))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup().addContainerGap().add(jTabbedPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 240, Short.MAX_VALUE).add(12, 12, 12).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jButton1).add(jButton2)).addContainerGap()));
}
Example 36
Project: CodenameOne-master  File: LayoutEditor.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    layoutCombo = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    rows = new javax.swing.JSpinner();
    jLabel3 = new javax.swing.JLabel();
    columns = new javax.swing.JSpinner();
    jLabel4 = new javax.swing.JLabel();
    valign = new javax.swing.JComboBox();
    jLabel5 = new javax.swing.JLabel();
    fillRows = new javax.swing.JCheckBox();
    jLabel6 = new javax.swing.JLabel();
    swapNorth = new javax.swing.JComboBox();
    swapSouth = new javax.swing.JComboBox();
    jLabel7 = new javax.swing.JLabel();
    swapCenter = new javax.swing.JComboBox();
    jLabel8 = new javax.swing.JLabel();
    jLabel9 = new javax.swing.JLabel();
    swapEast = new javax.swing.JComboBox();
    jLabel10 = new javax.swing.JLabel();
    swapWest = new javax.swing.JComboBox();
    jLabel11 = new javax.swing.JLabel();
    align = new javax.swing.JComboBox();
    jLabel12 = new javax.swing.JLabel();
    absoluteCenter = new javax.swing.JCheckBox();
    jScrollPane1 = new javax.swing.JScrollPane();
    help = new javax.swing.JTextPane();
    FormListener formListener = new FormListener();
    jLabel1.setText("Layout");
    // NOI18N
    jLabel1.setName("jLabel1");
    layoutCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Flow Layout", "Box Layout X", "Box Layout Y", "Grid Layout", "Table Layout", "LayeredLayout", "Border Layout" }));
    // NOI18N
    layoutCombo.setName("layoutCombo");
    layoutCombo.addActionListener(formListener);
    jLabel2.setText("Rows");
    // NOI18N
    jLabel2.setName("jLabel2");
    rows.setEnabled(false);
    // NOI18N
    rows.setName("rows");
    jLabel3.setText("Columns");
    // NOI18N
    jLabel3.setName("jLabel3");
    columns.setEnabled(false);
    // NOI18N
    columns.setName("columns");
    jLabel4.setText("Valign");
    // NOI18N
    jLabel4.setName("jLabel4");
    valign.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Top", "Center", "Bottom" }));
    // NOI18N
    valign.setName("valign");
    jLabel5.setText("Fill Rows");
    // NOI18N
    jLabel5.setName("jLabel5");
    // NOI18N
    fillRows.setName("fillRows");
    jLabel6.setText("Landscape North");
    // NOI18N
    jLabel6.setName("jLabel6");
    swapNorth.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "South", "Center", "West", "East" }));
    swapNorth.setEnabled(false);
    // NOI18N
    swapNorth.setName("swapNorth");
    swapSouth.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "Center", "West", "East" }));
    swapSouth.setEnabled(false);
    // NOI18N
    swapSouth.setName("swapSouth");
    jLabel7.setText("Landscape South");
    // NOI18N
    jLabel7.setName("jLabel7");
    swapCenter.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "South", "West", "East" }));
    swapCenter.setEnabled(false);
    // NOI18N
    swapCenter.setName("swapCenter");
    jLabel8.setText("Landscape Center");
    // NOI18N
    jLabel8.setName("jLabel8");
    jLabel9.setText("Landscape East");
    // NOI18N
    jLabel9.setName("jLabel9");
    swapEast.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "Center", "West", "South" }));
    swapEast.setEnabled(false);
    // NOI18N
    swapEast.setName("swapEast");
    jLabel10.setText("Landscape West");
    // NOI18N
    jLabel10.setName("jLabel10");
    swapWest.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "Center", "South", "East" }));
    swapWest.setEnabled(false);
    // NOI18N
    swapWest.setName("swapWest");
    jLabel11.setText("Align");
    // NOI18N
    jLabel11.setName("jLabel11");
    align.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Left", "Center", "Right" }));
    // NOI18N
    align.setName("align");
    jLabel12.setText("Absolute Center");
    // NOI18N
    jLabel12.setName("jLabel12");
    absoluteCenter.setEnabled(false);
    // NOI18N
    absoluteCenter.setName("absoluteCenter");
    // NOI18N
    jScrollPane1.setName("jScrollPane1");
    help.setContentType("text/html");
    help.setEditable(false);
    // NOI18N
    help.setName("help");
    jScrollPane1.setViewportView(help);
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().addContainerGap().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jLabel1).add(jLabel2).add(jLabel3).add(jLabel11)).add(51, 51, 51).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(rows, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(layoutCombo, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(columns, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(align, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jLabel6).add(jLabel7).add(jLabel8).add(jLabel9).add(jLabel10).add(jLabel5).add(jLabel4).add(jLabel12)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(layout.createSequentialGroup().add(absoluteCenter).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 178, Short.MAX_VALUE)).add(valign, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(layout.createSequentialGroup().add(fillRows).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 178, Short.MAX_VALUE)).add(swapNorth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapSouth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapCenter, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapEast, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapWest, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))).add(0, 0, 0).add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 475, Short.MAX_VALUE).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().addContainerGap().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(org.jdesktop.layout.GroupLayout.TRAILING, jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 315, Short.MAX_VALUE).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel1).add(layoutCombo, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).add(12, 12, 12).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel2).add(rows, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel3).add(columns, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel11).add(align, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING).add(fillRows).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(valign, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(jLabel4)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jLabel5))).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel6).add(swapNorth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel7).add(swapSouth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel8).add(swapCenter, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel9).add(swapEast, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel10).add(swapWest, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel12).add(absoluteCenter)))).addContainerGap()));
}
Example 37
Project: lwuit-master  File: LayoutEditor.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    layoutCombo = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    rows = new javax.swing.JSpinner();
    jLabel3 = new javax.swing.JLabel();
    columns = new javax.swing.JSpinner();
    jLabel4 = new javax.swing.JLabel();
    valign = new javax.swing.JComboBox();
    jLabel5 = new javax.swing.JLabel();
    fillRows = new javax.swing.JCheckBox();
    jLabel6 = new javax.swing.JLabel();
    swapNorth = new javax.swing.JComboBox();
    swapSouth = new javax.swing.JComboBox();
    jLabel7 = new javax.swing.JLabel();
    swapCenter = new javax.swing.JComboBox();
    jLabel8 = new javax.swing.JLabel();
    jLabel9 = new javax.swing.JLabel();
    swapEast = new javax.swing.JComboBox();
    jLabel10 = new javax.swing.JLabel();
    swapWest = new javax.swing.JComboBox();
    jLabel11 = new javax.swing.JLabel();
    align = new javax.swing.JComboBox();
    jLabel12 = new javax.swing.JLabel();
    absoluteCenter = new javax.swing.JCheckBox();
    jScrollPane1 = new javax.swing.JScrollPane();
    help = new javax.swing.JTextPane();
    FormListener formListener = new FormListener();
    jLabel1.setText("Layout");
    // NOI18N
    jLabel1.setName("jLabel1");
    layoutCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Flow Layout", "Box Layout X", "Box Layout Y", "Grid Layout", "Table Layout", "LayeredLayout", "Border Layout" }));
    // NOI18N
    layoutCombo.setName("layoutCombo");
    layoutCombo.addActionListener(formListener);
    jLabel2.setText("Rows");
    // NOI18N
    jLabel2.setName("jLabel2");
    rows.setEnabled(false);
    // NOI18N
    rows.setName("rows");
    jLabel3.setText("Columns");
    // NOI18N
    jLabel3.setName("jLabel3");
    columns.setEnabled(false);
    // NOI18N
    columns.setName("columns");
    jLabel4.setText("Valign");
    // NOI18N
    jLabel4.setName("jLabel4");
    valign.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Top", "Center", "Bottom" }));
    // NOI18N
    valign.setName("valign");
    jLabel5.setText("Fill Rows");
    // NOI18N
    jLabel5.setName("jLabel5");
    // NOI18N
    fillRows.setName("fillRows");
    jLabel6.setText("Landscape North");
    // NOI18N
    jLabel6.setName("jLabel6");
    swapNorth.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "South", "Center", "West", "East" }));
    swapNorth.setEnabled(false);
    // NOI18N
    swapNorth.setName("swapNorth");
    swapSouth.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "Center", "West", "East" }));
    swapSouth.setEnabled(false);
    // NOI18N
    swapSouth.setName("swapSouth");
    jLabel7.setText("Landscape South");
    // NOI18N
    jLabel7.setName("jLabel7");
    swapCenter.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "South", "West", "East" }));
    swapCenter.setEnabled(false);
    // NOI18N
    swapCenter.setName("swapCenter");
    jLabel8.setText("Landscape Center");
    // NOI18N
    jLabel8.setName("jLabel8");
    jLabel9.setText("Landscape East");
    // NOI18N
    jLabel9.setName("jLabel9");
    swapEast.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "Center", "West", "South" }));
    swapEast.setEnabled(false);
    // NOI18N
    swapEast.setName("swapEast");
    jLabel10.setText("Landscape West");
    // NOI18N
    jLabel10.setName("jLabel10");
    swapWest.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Don't Swap", "North", "Center", "South", "East" }));
    swapWest.setEnabled(false);
    // NOI18N
    swapWest.setName("swapWest");
    jLabel11.setText("Align");
    // NOI18N
    jLabel11.setName("jLabel11");
    align.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Left", "Center", "Right" }));
    // NOI18N
    align.setName("align");
    jLabel12.setText("Absolute Center");
    // NOI18N
    jLabel12.setName("jLabel12");
    absoluteCenter.setEnabled(false);
    // NOI18N
    absoluteCenter.setName("absoluteCenter");
    // NOI18N
    jScrollPane1.setName("jScrollPane1");
    help.setContentType("text/html");
    help.setEditable(false);
    // NOI18N
    help.setName("help");
    jScrollPane1.setViewportView(help);
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().addContainerGap().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jLabel1).add(jLabel2).add(jLabel3).add(jLabel11)).add(51, 51, 51).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(rows, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(layoutCombo, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(columns, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(align, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(jLabel6).add(jLabel7).add(jLabel8).add(jLabel9).add(jLabel10).add(jLabel5).add(jLabel4).add(jLabel12)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(layout.createSequentialGroup().add(absoluteCenter).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 178, Short.MAX_VALUE)).add(valign, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(layout.createSequentialGroup().add(fillRows).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 178, Short.MAX_VALUE)).add(swapNorth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapSouth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapCenter, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapEast, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(swapWest, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 199, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))).add(0, 0, 0).add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 475, Short.MAX_VALUE).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().addContainerGap().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(org.jdesktop.layout.GroupLayout.TRAILING, jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 315, Short.MAX_VALUE).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel1).add(layoutCombo, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).add(12, 12, 12).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel2).add(rows, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel3).add(columns, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel11).add(align, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING).add(fillRows).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(valign, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(jLabel4)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(jLabel5))).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel6).add(swapNorth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel7).add(swapSouth, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel8).add(swapCenter, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel9).add(swapEast, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel10).add(swapWest, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(jLabel12).add(absoluteCenter)))).addContainerGap()));
}
Example 38
Project: AndrOBD-master  File: SerialConfigPanel.java View source code
/**
	 * This method is called from within the constructor to
	 * initialize the form.
	 * WARNING: Do NOT modify this code. The content of this method is
	 * always regenerated by the Form Editor.
	 */
// <editor-fold defaultstate="collapsed" desc=" Generated Code ">//GEN-BEGIN:initComponents
private void initComponents() {
    java.awt.GridBagConstraints gridBagConstraints;
    panData = new javax.swing.JPanel();
    lblPort = new javax.swing.JLabel();
    cbPort = new javax.swing.JComboBox();
    lblBaudrate = new javax.swing.JLabel();
    cbBaudrate = new javax.swing.JComboBox();
    lblDataBits = new javax.swing.JLabel();
    cbDataBits = new javax.swing.JComboBox();
    lblStopBits = new javax.swing.JLabel();
    cbStopBits = new javax.swing.JComboBox();
    lblParity = new javax.swing.JLabel();
    cbParity = new javax.swing.JComboBox();
    lblHsRx = new javax.swing.JLabel();
    lblHsTx = new javax.swing.JLabel();
    cbProtocolRx = new javax.swing.JComboBox();
    cbProtocolTx = new javax.swing.JComboBox();
    jPanel1 = new javax.swing.JPanel();
    btnDSR = new javax.swing.JToggleButton();
    btnCTS = new javax.swing.JToggleButton();
    btnCD = new javax.swing.JToggleButton();
    btnDTR = new javax.swing.JToggleButton();
    btnRTS = new javax.swing.JToggleButton();
    setLayout(new java.awt.BorderLayout());
    panData.setLayout(new java.awt.GridBagLayout());
    lblPort.setFont(new java.awt.Font("Dialog", 0, 10));
    lblPort.setLabelFor(cbPort);
    lblPort.setText("Port");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblPort, gridBagConstraints);
    cbPort.setFont(new java.awt.Font("Dialog", 0, 10));
    cbPort.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            cbPortItemStateChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.weightx = 1.0;
    panData.add(cbPort, gridBagConstraints);
    lblBaudrate.setFont(new java.awt.Font("Dialog", 0, 10));
    lblBaudrate.setLabelFor(cbBaudrate);
    lblBaudrate.setText("Baudrate");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblBaudrate, gridBagConstraints);
    cbBaudrate.setEditable(true);
    cbBaudrate.setFont(new java.awt.Font("Dialog", 0, 10));
    cbBaudrate.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "300", "600", "1200", "2400", "4800", "9600", "19200", "38400", "57600", "115200" }));
    cbBaudrate.setSelectedIndex(5);
    cbBaudrate.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            SelectionChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.weightx = 1.0;
    panData.add(cbBaudrate, gridBagConstraints);
    lblDataBits.setFont(new java.awt.Font("Dialog", 0, 10));
    lblDataBits.setLabelFor(cbDataBits);
    lblDataBits.setText("Data Bits");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblDataBits, gridBagConstraints);
    cbDataBits.setFont(new java.awt.Font("Dialog", 0, 10));
    cbDataBits.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "5", "6", "7", "8" }));
    cbDataBits.setSelectedIndex(3);
    cbDataBits.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            SelectionChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.weightx = 1.0;
    panData.add(cbDataBits, gridBagConstraints);
    lblStopBits.setFont(new java.awt.Font("Dialog", 0, 10));
    lblStopBits.setLabelFor(cbStopBits);
    lblStopBits.setText("Stop Bits");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblStopBits, gridBagConstraints);
    cbStopBits.setFont(new java.awt.Font("Dialog", 0, 10));
    cbStopBits.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "1", "2", "1.5" }));
    cbStopBits.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            SelectionChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.weightx = 1.0;
    panData.add(cbStopBits, gridBagConstraints);
    lblParity.setFont(new java.awt.Font("Dialog", 0, 10));
    lblParity.setLabelFor(cbParity);
    lblParity.setText("Parity");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblParity, gridBagConstraints);
    cbParity.setFont(new java.awt.Font("Dialog", 0, 10));
    cbParity.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "None", "Odd", "Even", "Mark", "Space" }));
    cbParity.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            SelectionChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.weightx = 1.0;
    panData.add(cbParity, gridBagConstraints);
    lblHsRx.setFont(new java.awt.Font("Dialog", 0, 10));
    lblHsRx.setText("Handshake Rx");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblHsRx, gridBagConstraints);
    lblHsTx.setFont(new java.awt.Font("Dialog", 0, 10));
    lblHsTx.setText("Handshake Tx");
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 5);
    panData.add(lblHsTx, gridBagConstraints);
    cbProtocolRx.setFont(new java.awt.Font("Dialog", 0, 10));
    cbProtocolRx.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "None", "RTS/CTS", "XON/XOFF" }));
    cbProtocolRx.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            SelectionChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    panData.add(cbProtocolRx, gridBagConstraints);
    cbProtocolTx.setFont(new java.awt.Font("Dialog", 0, 10));
    cbProtocolTx.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "None", "RTS/CTS", "XON/XOFF" }));
    cbProtocolTx.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            SelectionChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    panData.add(cbProtocolTx, gridBagConstraints);
    add(panData, java.awt.BorderLayout.CENTER);
    jPanel1.setLayout(new java.awt.GridLayout(1, 0, 1, 0));
    btnDSR.setFont(new java.awt.Font("Dialog", 0, 8));
    btnDSR.setText("DSR");
    btnDSR.setEnabled(false);
    btnDSR.setOpaque(false);
    jPanel1.add(btnDSR);
    btnCTS.setFont(new java.awt.Font("Dialog", 0, 8));
    btnCTS.setText("CTS");
    btnCTS.setEnabled(false);
    btnCTS.setOpaque(false);
    jPanel1.add(btnCTS);
    btnCD.setFont(new java.awt.Font("Dialog", 0, 8));
    btnCD.setText("CD");
    btnCD.setEnabled(false);
    btnCD.setOpaque(false);
    jPanel1.add(btnCD);
    btnDTR.setFont(new java.awt.Font("Dialog", 0, 8));
    btnDTR.setText("DTR");
    btnDTR.setEnabled(false);
    btnDTR.setOpaque(false);
    jPanel1.add(btnDTR);
    btnRTS.setFont(new java.awt.Font("Dialog", 0, 8));
    btnRTS.setText("RTS");
    btnRTS.setEnabled(false);
    btnRTS.setOpaque(false);
    jPanel1.add(btnRTS);
    add(jPanel1, java.awt.BorderLayout.SOUTH);
}
Example 39
Project: ClothoBiofabEdition-master  File: spreadsheet.java View source code
private void initComponents() {
    cancelButton = new javax.swing.JButton();
    tableScroll = new javax.swing.JScrollPane();
    jScrollPane1 = new javax.swing.JScrollPane();
    theTable = new JXTable();
    jComboBox1 = new javax.swing.JComboBox();
    submitButton = new javax.swing.JButton();
    comboLabel1 = new javax.swing.JLabel();
    jComboBox2 = new javax.swing.JComboBox();
    jComboBox3 = new javax.swing.JComboBox();
    jComboBox4 = new javax.swing.JComboBox();
    jComboBox5 = new javax.swing.JComboBox();
    comboLabel2 = new javax.swing.JLabel();
    comboLabel3 = new javax.swing.JLabel();
    comboLabel4 = new javax.swing.JLabel();
    comboLabel5 = new javax.swing.JLabel();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    jButton3 = new javax.swing.JButton();
    clearButton = new javax.swing.JButton();
    jScrollPane3 = new javax.swing.JScrollPane();
    titleArea = new javax.swing.JEditorPane();
    jScrollPane4 = new javax.swing.JScrollPane();
    logArea = new javax.swing.JTextArea();
    jButton4 = new javax.swing.JButton();
    theTable.setSortable(false);
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    cancelButton.setText("cancel");
    cancelButton.addActionListener(new java.awt.event.ActionListener() {

        @Override
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            cancelPerformed();
        }
    });
    clearButton.addActionListener(new java.awt.event.ActionListener() {

        @Override
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            int numcols = theTable.getColumnCount();
            int numrow = theTable.getRowCount();
            for (int i = 0; i < numrow; i++) {
                for (int j = 0; j < numcols; j++) {
                    theTable.setValueAt("", i, j);
                }
            }
        }
    });
    theTable.setModel(new javax.swing.table.DefaultTableModel(_data, _title));
    jScrollPane1.setViewportView(theTable);
    tableScroll.setViewportView(jScrollPane1);
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    submitButton.setText("submit");
    submitButton.addActionListener(new java.awt.event.ActionListener() {

        @Override
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            returnData();
        }
    });
    jButton1.setText("jButton1");
    jButton2.setText("jButton2");
    jButton3.setText("jButton3");
    clearButton.setText("clear");
    jScrollPane3.setViewportView(titleArea);
    jScrollPane4.setViewportView(logArea);
    jButton4.setText("jButton4");
    titleArea.setOpaque(false);
    titleArea.setBorder(null);
    titleArea.setEditable(false);
    titleArea.setContentType("text/html; charset=EUC-JP");
    jScrollPane3.setOpaque(false);
    jScrollPane3.setBorder(null);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(tableScroll, javax.swing.GroupLayout.DEFAULT_SIZE, 758, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addComponent(jScrollPane3, javax.swing.GroupLayout.DEFAULT_SIZE, 448, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 300, Short.MAX_VALUE)).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(comboLabel1)).addGap(56, 56, 56).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(comboLabel2)).addGap(63, 63, 63).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jComboBox3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(comboLabel3)).addGap(58, 58, 58).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jComboBox4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(comboLabel4)).addGap(56, 56, 56).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(comboLabel5).addComponent(jComboBox5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))).addContainerGap()).addGroup(layout.createSequentialGroup().addComponent(jButton1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton4).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 163, Short.MAX_VALUE).addComponent(clearButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(submitButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(cancelButton).addGap(102, 102, 102)))));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 66, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 66, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(comboLabel1).addComponent(comboLabel2).addComponent(comboLabel3).addComponent(comboLabel4).addComponent(comboLabel5)).addGap(7, 7, 7).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jComboBox3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jComboBox4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jComboBox5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(tableScroll, javax.swing.GroupLayout.DEFAULT_SIZE, 374, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1).addComponent(jButton2).addComponent(jButton3).addComponent(jButton4).addComponent(cancelButton).addComponent(submitButton).addComponent(clearButton))));
    pack();
}
Example 40
Project: josm-older-master  File: AbstractMergeAction.java View source code
protected Layer askTargetLayer(List<Layer> targetLayers) {
    JComboBox layerList = new JComboBox();
    layerList.setRenderer(new LayerListCellRenderer());
    layerList.setModel(new DefaultComboBoxModel(targetLayers.toArray()));
    layerList.setSelectedIndex(0);
    JPanel pnl = new JPanel();
    pnl.setLayout(new GridBagLayout());
    pnl.add(new JLabel(tr("Please select the target layer.")), GBC.eol());
    pnl.add(layerList, GBC.eol());
    ExtendedDialog ed = new ExtendedDialog(Main.parent, tr("Select target layer"), new String[] { tr("Merge"), tr("Cancel") });
    ed.setButtonIcons(new String[] { "dialogs/mergedown", "cancel" });
    ed.setContent(pnl);
    ed.showDialog();
    if (ed.getValue() != 1)
        return null;
    Layer targetLayer = (Layer) layerList.getSelectedItem();
    return targetLayer;
}
Example 41
Project: dwoss-master  File: DisplayPanel.java View source code
/**
     * This method is called DisplayPanel.java:82from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this
     * method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    displayTypeGroup = new javax.swing.ButtonGroup();
    jPanel1 = new javax.swing.JPanel();
    displayMatButton = new javax.swing.JRadioButton();
    displayCrystalBrightButton = new javax.swing.JRadioButton();
    displayRatioBox = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    displaySizeBox = new javax.swing.JComboBox();
    jLabel1 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    displayLedCheck = new javax.swing.JCheckBox();
    displayMaxResBox = new javax.swing.JComboBox();
    // NOI18N
    jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(new java.awt.Color(204, 204, 255), new java.awt.Color(1, 1, 1)), "Display Daten", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Dialog", 1, 12)));
    displayTypeGroup.add(displayMatButton);
    displayMatButton.setText("Matt");
    displayMatButton.setNextFocusableComponent(displayCrystalBrightButton);
    displayTypeGroup.add(displayCrystalBrightButton);
    displayCrystalBrightButton.setText("Crystal Bright");
    displayCrystalBrightButton.setNextFocusableComponent(displayLedCheck);
    displayRatioBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    displayRatioBox.setNextFocusableComponent(displaySizeBox);
    displayRatioBox.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            displayRatioBoxActionPerformed(evt);
        }
    });
    jLabel2.setText("Max. Auflösung:");
    displaySizeBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    displaySizeBox.setNextFocusableComponent(displayMaxResBox);
    displaySizeBox.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            displaySizeBoxActionPerformed(evt);
        }
    });
    jLabel1.setText("Display Größe:");
    jLabel3.setText("Bildverhältniss:");
    displayLedCheck.setText("LED");
    displayMaxResBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    displayMaxResBox.setNextFocusableComponent(displayMatButton);
    javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addComponent(displayMatButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(displayCrystalBrightButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(displayLedCheck)).addGroup(jPanel1Layout.createSequentialGroup().addComponent(jLabel3).addGap(17, 17, 17).addComponent(displayRatioBox, 0, 183, Short.MAX_VALUE)).addGroup(jPanel1Layout.createSequentialGroup().addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel2).addComponent(jLabel1)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(displaySizeBox, 0, 183, Short.MAX_VALUE).addComponent(displayMaxResBox, 0, 183, Short.MAX_VALUE)))).addContainerGap()));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel3).addComponent(displayRatioBox, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel1).addComponent(displaySizeBox, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel2).addComponent(displayMaxResBox, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(displayMatButton).addComponent(displayCrystalBrightButton).addComponent(displayLedCheck)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE));
}
Example 42
Project: Feuille-master  File: XKCStep3.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    lblMode = new javax.swing.JLabel();
    cbMode = new javax.swing.JComboBox();
    btnNext = new javax.swing.JButton();
    jLabel3 = new javax.swing.JLabel();
    lblTreatment = new javax.swing.JLabel();
    cbTreatment = new javax.swing.JComboBox();
    jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
    jLabel1.setText("<html><h1>Choose a mode :");
    lblMode.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
    lblMode.setText("Summary");
    cbMode.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbMode.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            cbModeItemStateChanged(evt);
        }
    });
    btnNext.setText("Next >>");
    jLabel3.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
    jLabel3.setText("<html><h1>Choose a treatment :");
    lblTreatment.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
    lblTreatment.setText("Summary");
    cbTreatment.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbTreatment.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            cbTreatmentItemStateChanged(evt);
        }
    });
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jLabel1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 420, Short.MAX_VALUE).addComponent(lblMode, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(cbMode, javax.swing.GroupLayout.Alignment.LEADING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addGap(0, 0, Short.MAX_VALUE).addComponent(btnNext, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(jLabel3, javax.swing.GroupLayout.Alignment.LEADING).addComponent(lblTreatment, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(cbTreatment, javax.swing.GroupLayout.Alignment.LEADING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(lblMode, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(cbMode, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(lblTreatment, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(cbTreatment, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(btnNext).addContainerGap()));
}
Example 43
Project: Ganymede-master  File: InterruptExample.java View source code
private void onButtonClick(final String label) {
    if (!running) {
        running = true;
        // We will execute a long operation, change the text signaling
        // that the user can interrupt the operation
        button.setText("Interrupt");
        try {
            // getData() will block until the heavy operation is finished
            ArrayList list = getData();
            // If was interrupted we get back a null list
            if (list == null) {
                // Task was interrupted, return quietly, we already cleaned up
                return;
            } else {
                // Task completed successfully, do whatever useful with the list
                // For example, populate a JComboBox
                javax.swing.DefaultComboBoxModel model = new javax.swing.DefaultComboBoxModel(list.toArray());
            // The reader will finish this part :)
            }
        } catch (Exception x) {
            x.printStackTrace();
        } finally {
            // Restore anyway the button's text
            button.setText(label);
            // Restore anyway the interrupt status for another call
            setTaskInterrupted(false);
            // We're not running anymore
            running = false;
        }
    } else {
        // Here if we want to interrupt the Task
        // Restore the button text to the previous value
        button.setText(label);
        // Interrupt the task
        setTaskInterrupted(true);
    }
}
Example 44
Project: javaforce-master  File: EditProjectProperties.java View source code
/**
   * This method is called from within the constructor to initialize the form.
   * WARNING: Do NOT modify this code. The content of this method is always
   * regenerated by the Form Editor.
   */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    videoRate = new javax.swing.JSpinner();
    jLabel2 = new javax.swing.JLabel();
    audioRate = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    audioChannels = new javax.swing.JSpinner();
    accept = new javax.swing.JButton();
    cancel = new javax.swing.JButton();
    jLabel4 = new javax.swing.JLabel();
    width = new javax.swing.JTextField();
    jLabel5 = new javax.swing.JLabel();
    height = new javax.swing.JTextField();
    preview = new javax.swing.JCheckBox();
    jLabel6 = new javax.swing.JLabel();
    vBitRate = new javax.swing.JComboBox();
    jLabel7 = new javax.swing.JLabel();
    aBitRate = new javax.swing.JComboBox();
    v1001 = new javax.swing.JCheckBox();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle("Project Properties");
    setResizable(false);
    jLabel1.setText("Frame Rate:");
    videoRate.setModel(new javax.swing.SpinnerNumberModel(24, 1, 120, 1));
    jLabel2.setText("Audio Rate:");
    audioRate.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "48000", "44100", "22050", "11025", "64000", "32000", "16000", "8000", "96000", " " }));
    audioRate.setSelectedIndex(1);
    jLabel3.setText("Audio Channels:");
    audioChannels.setModel(new javax.swing.SpinnerNumberModel(2, 1, 2, 1));
    accept.setText("Accept");
    accept.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            acceptActionPerformed(evt);
        }
    });
    cancel.setText("Cancel");
    cancel.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            cancelActionPerformed(evt);
        }
    });
    jLabel4.setText("Video Size:");
    width.setText("640");
    jLabel5.setText("x");
    height.setText("480");
    preview.setText("Generate Previews");
    preview.setToolTipText("Generates Media Previews");
    jLabel6.setText("Video BitRate:");
    vBitRate.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "8M", "6M", "4M", "2M", "1M", "800k", "400k", "200k" }));
    vBitRate.setSelectedIndex(4);
    vBitRate.setToolTipText("");
    jLabel7.setText("Audio BitRate:");
    aBitRate.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "256k", "192k", "128k", "64k", "32k" }));
    aBitRate.setSelectedIndex(2);
    aBitRate.setToolTipText("");
    v1001.setText("X 1000 / 1001");
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel1).addComponent(jLabel2)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(audioRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGroup(layout.createSequentialGroup().addComponent(videoRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(v1001)))).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(jLabel3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(audioChannels, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createSequentialGroup().addComponent(jLabel4).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(width, javax.swing.GroupLayout.PREFERRED_SIZE, 57, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jLabel5))).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(height, javax.swing.GroupLayout.PREFERRED_SIZE, 60, javax.swing.GroupLayout.PREFERRED_SIZE))).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addGap(0, 0, Short.MAX_VALUE).addComponent(cancel).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(accept).addGap(12, 12, 12)).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(preview).addGap(0, 0, Short.MAX_VALUE)).addGroup(layout.createSequentialGroup().addComponent(jLabel6).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(vBitRate, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))).addGap(10, 10, 10)).addGroup(layout.createSequentialGroup().addComponent(jLabel7).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(aBitRate, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addContainerGap()))));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel1).addComponent(videoRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(v1001)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel2).addComponent(audioRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel3).addComponent(audioChannels, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel4).addComponent(width, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel5).addComponent(height, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel6).addComponent(vBitRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel7).addComponent(aBitRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(preview).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(accept).addComponent(cancel)).addContainerGap()));
    pack();
}
Example 45
Project: laravel-netbeans-master  File: NewProjectConfigurationPanel.java View source code
@NbBundle.Messages({ "NetworkError.CannotGetGithubTags=Network errors: cannot get tags from Github", "GettingTagsFromGithub=Getting tags from Github", "AllTagsFetched=All tags was fetched successfully, ready to create a new Laravel project" })
private void _initUnzipGitHubTag() {
    lblProgress.setText(Bundle.GettingTagsFromGithub());
    LaravelGithubTags githubTags = LaravelGithubTags.getInstance();
    String names[] = githubTags.getNames();
    Arrays.sort(names, new LaravelVersionComparator());
    cbbGithubVersions.setEnabled(true);
    cbbGithubVersions.setModel(new DefaultComboBoxModel<String>(names));
    if (githubTags.isNetworkError()) {
        lblProgress.setText(Bundle.NetworkError_CannotGetGithubTags());
    } else {
        lblProgress.setText(Bundle.AllTagsFetched());
    }
}
Example 46
Project: oceano-master  File: JChooseOrchestratorAgent.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jPanel1 = new javax.swing.JPanel();
    btnScheduling = new javax.swing.JButton();
    btnCancel = new javax.swing.JButton();
    jComboAgents = new javax.swing.JComboBox();
    setTitle("Choose the Orchestrator Agent");
    jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Action"));
    btnScheduling.setText("OK");
    btnScheduling.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            btnSchedulingActionPerformed(evt);
        }
    });
    btnCancel.setText("Cancel");
    btnCancel.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            btnCancelActionPerformed(evt);
        }
    });
    javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addContainerGap().addComponent(btnScheduling).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 145, Short.MAX_VALUE).addComponent(btnCancel).addContainerGap()));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addContainerGap().addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(btnScheduling).addComponent(btnCancel)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    jComboAgents.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Choose the Orchestrator Agent" }));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(10, 10, 10).addComponent(jComboAgents, 0, 279, Short.MAX_VALUE)).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(27, 27, 27).addComponent(jComboAgents, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(18, 18, 18).addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(27, Short.MAX_VALUE)));
    pack();
}
Example 47
Project: PoCoTo-master  File: NewProjectVisualPanel1.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    jButton1 = new javax.swing.JButton();
    jTextField1 = new javax.swing.JTextField();
    jComboBox1 = new javax.swing.JComboBox();
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    jComboBox2 = new javax.swing.JComboBox();
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jButton1, org.openide.util.NbBundle.getMessage(NewProjectVisualPanel1.class, "NewProjectVisualPanel1.jButton1.text_1"));
    jTextField1.setEditable(false);
    // NOI18N
    jTextField1.setText(org.openide.util.NbBundle.getMessage(NewProjectVisualPanel1.class, "NewProjectVisualPanel1.jTextField1.text_1"));
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel1, org.openide.util.NbBundle.getMessage(NewProjectVisualPanel1.class, "NewProjectVisualPanel1.jLabel1.text"));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel2, org.openide.util.NbBundle.getMessage(NewProjectVisualPanel1.class, "NewProjectVisualPanel1.jLabel2.text"));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel3, org.openide.util.NbBundle.getMessage(NewProjectVisualPanel1.class, "NewProjectVisualPanel1.jLabel3.text"));
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(25, 25, 25).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jLabel1).addComponent(jLabel2).addComponent(jLabel3)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(jTextField1, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton1)).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, Short.MAX_VALUE))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(48, 48, 48).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel1).addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jButton1)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel2).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel3).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
}
Example 48
Project: Weasis-master  File: PrintDialog.java View source code
private void initComponents(boolean layout) {
    GridBagLayout gridBagLayout = new GridBagLayout();
    getContentPane().setLayout(gridBagLayout);
    positionLabel = new javax.swing.JLabel();
    //$NON-NLS-1$
    positionLabel.setText(Messages.getString("PrintDialog.pos") + StringUtil.COLON);
    GridBagConstraints gbcPositionLabel = new GridBagConstraints();
    gbcPositionLabel.anchor = GridBagConstraints.EAST;
    gbcPositionLabel.insets = new Insets(15, 20, 10, 5);
    gbcPositionLabel.gridx = 0;
    gbcPositionLabel.gridy = 0;
    getContentPane().add(positionLabel, gbcPositionLabel);
    positionComboBox = new javax.swing.JComboBox<>();
    positionComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(//$NON-NLS-1$ //$NON-NLS-2$
    new String[] { Messages.getString("PrintDialog.center"), Messages.getString("PrintDialog.top") }));
    GridBagConstraints gbcPositionComboBox = new GridBagConstraints();
    gbcPositionComboBox.anchor = GridBagConstraints.WEST;
    gbcPositionComboBox.insets = new Insets(15, 0, 10, 5);
    gbcPositionComboBox.gridx = 1;
    gbcPositionComboBox.gridy = 0;
    getContentPane().add(positionComboBox, gbcPositionComboBox);
    label = new JLabel();
    //$NON-NLS-1$
    label.setText(Messages.getString("PrintDialog.dpi") + StringUtil.COLON);
    GridBagConstraints gbcLabel = new GridBagConstraints();
    gbcLabel.anchor = GridBagConstraints.EAST;
    gbcLabel.insets = new Insets(0, 20, 10, 5);
    gbcLabel.gridx = 0;
    gbcLabel.gridy = 1;
    getContentPane().add(label, gbcLabel);
    comboBoxDPI = new JComboBox<>();
    GridBagConstraints gbcComboBoxDPI = new GridBagConstraints();
    gbcComboBoxDPI.anchor = GridBagConstraints.NORTHWEST;
    gbcComboBoxDPI.insets = new Insets(0, 0, 10, 5);
    gbcComboBoxDPI.gridx = 1;
    gbcComboBoxDPI.gridy = 1;
    comboBoxDPI.setModel(new DefaultComboBoxModel<>(PrintOptions.DotPerInches.values()));
    comboBoxDPI.setSelectedItem(PrintOptions.DotPerInches.DPI_150);
    getContentPane().add(comboBoxDPI, gbcComboBoxDPI);
    annotationsCheckBox = new javax.swing.JCheckBox();
    //$NON-NLS-1$
    annotationsCheckBox.setText(Messages.getString("PrintDialog.annotate"));
    annotationsCheckBox.setSelected(true);
    GridBagConstraints gbcAnnotationsCheckBox = new GridBagConstraints();
    gbcAnnotationsCheckBox.anchor = GridBagConstraints.WEST;
    gbcAnnotationsCheckBox.insets = new Insets(0, 17, 10, 0);
    gbcAnnotationsCheckBox.gridwidth = 3;
    gbcAnnotationsCheckBox.gridx = 0;
    gbcAnnotationsCheckBox.gridy = 2;
    getContentPane().add(annotationsCheckBox, gbcAnnotationsCheckBox);
    cancelButton = new javax.swing.JButton();
    //$NON-NLS-1$
    cancelButton.setText(Messages.getString("PrintDialog.cancel"));
    cancelButton.addActionListener( e -> dispose());
    printButton = new javax.swing.JButton();
    //$NON-NLS-1$
    printButton.setText(Messages.getString("PrintDialog.print"));
    printButton.addActionListener( e -> printAction());
    if (layout) {
        //$NON-NLS-1$
        chckbxSelectedView = new JCheckBox(Messages.getString("PrintDialog.selected_view"));
        GridBagConstraints gbcChckbxNewCheckBox = new GridBagConstraints();
        gbcChckbxNewCheckBox.anchor = GridBagConstraints.WEST;
        gbcChckbxNewCheckBox.gridwidth = 3;
        gbcChckbxNewCheckBox.insets = new Insets(0, 15, 10, 5);
        gbcChckbxNewCheckBox.gridx = 0;
        gbcChckbxNewCheckBox.gridy = 3;
        getContentPane().add(chckbxSelectedView, gbcChckbxNewCheckBox);
    }
    getRootPane().setDefaultButton(printButton);
    GridBagConstraints gbcPrintButton = new GridBagConstraints();
    gbcPrintButton.anchor = GridBagConstraints.EAST;
    gbcPrintButton.insets = new Insets(25, 0, 15, 5);
    gbcPrintButton.gridx = 1;
    gbcPrintButton.gridy = 4;
    getContentPane().add(printButton, gbcPrintButton);
    GridBagConstraints gbcCancelButton = new GridBagConstraints();
    gbcCancelButton.insets = new Insets(25, 10, 15, 15);
    gbcCancelButton.anchor = GridBagConstraints.NORTHWEST;
    gbcCancelButton.gridx = 2;
    gbcCancelButton.gridy = 4;
    getContentPane().add(cancelButton, gbcCancelButton);
    pack();
}
Example 49
Project: WebCams-master  File: ShapesControl.java View source code
@SuppressWarnings("unchecked")
private void initShapes() {
    try {
        shapes.load(getClass().getResourceAsStream("/webcamstudio/resources/shapes/Shapes.properties"));
        DefaultComboBoxModel model = new DefaultComboBoxModel();
        for (Object o : shapes.keySet()) {
            model.addElement(o);
        }
        cboShapes.setModel(model);
    } catch (IOException ex) {
        Logger.getLogger(WebcamStudio.class.getName()).log(Level.SEVERE, null, ex);
    }
    String shapeL = effect.getShape();
    cboShapes.setSelectedItem(shapeL);
    tglReverse.setSelected(effect.getReverse());
}
Example 50
Project: cayenne-master  File: DBConnectionInfoEditor.java View source code
protected void initBindings() {
    this.view.setEnabled(false);
    DefaultComboBoxModel adapterModel = new DefaultComboBoxModel(DbAdapterInfo.getStandardAdapters());
    view.getAdapters().setModel(adapterModel);
    view.getAdapters().setSelectedIndex(0);
    BindingBuilder builder = new BindingBuilder(getApplication().getBindingFactory(), this);
    bindings = new ObjectBinding[5];
    bindings[0] = builder.bindToTextField(view.getUserName(), "connectionInfo.userName");
    bindings[1] = builder.bindToTextField(view.getPassword(), "connectionInfo.password");
    bindings[2] = builder.bindToTextField(view.getDriver(), "connectionInfo.jdbcDriver");
    bindings[3] = builder.bindToTextField(view.getUrl(), "connectionInfo.url");
    bindings[4] = builder.bindToComboSelection(view.getAdapters(), "connectionInfo.dbAdapter", "Automatic");
}
Example 51
Project: cids-custom-switchon-master  File: QueryComboBox.java View source code
//~ Methods ----------------------------------------------------------------
/**
     * DOCUMENT ME!
     *
     * @param  query  DOCUMENT ME!
     */
public final void executeQueryAndSetModel(final String query) {
    final DefaultComboBoxModel<MetaObject> model = new DefaultComboBoxModel<MetaObject>();
    try {
        final MetaClass mc = ClassCacheMultiple.getMetaClass("SWITCHON", metaClassName);
        final MetaObject[] lwmos = SessionManager.getProxy().getLightweightMetaObjectsByQuery(mc.getID(), SessionManager.getSession().getUser(), query, new String[] { "NAME" }, "%1$2s");
        if (nullable) {
            model.addElement(null);
        }
        if (LOG.isDebugEnabled()) {
            LOG.debug(lwmos + "tags found for '" + metaClassName + "'");
        }
        for (final MetaObject mo : lwmos) {
            model.addElement(mo);
        }
    } catch (Exception ex) {
        LOG.warn("Problem while loading the LightWeightMetaObjects.", ex);
    }
    this.setModel(model);
    if (model.getSize() > 0) {
        this.setSelectedIndex(0);
    }
}
Example 52
Project: codjo-broadcast-master  File: BroadcastSelectorLogic.java View source code
private void fillFamilyCombobox() {
    final JComboBox familyCombo = gui.getSelectorFamily();
    familyCombo.addItemListener(new ItemListener() {

        public void itemStateChanged(ItemEvent evt) {
            if (evt.getStateChange() == ItemEvent.SELECTED) {
                setFamilySelectorDescription((String) familyCombo.getSelectedItem());
            }
        }
    });
    Set<String> familySet = selectorPreferences.keySet();
    String[] selectorFamilies = familySet.toArray(new String[familySet.size()]);
    familyCombo.setModel(new DefaultComboBoxModel(selectorFamilies));
    setFamilySelectorDescription((String) familyCombo.getItemAt(0));
}
Example 53
Project: Desktop-master  File: ConditionalStyleTable.java View source code
@Override
public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) {
    final Collection<IStyle> styles = ConditionalStyleTable.this.styleModel.getStyles();
    final DefaultComboBoxModel boxContent = new DefaultComboBoxModel(styles.toArray());
    styleBox.setModel(boxContent);
    return super.getTableCellEditorComponent(table, value, isSelected, row, column);
}
Example 54
Project: Docear-master  File: ConditionalStyleTable.java View source code
@Override
public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) {
    final Collection<IStyle> styles = ConditionalStyleTable.this.styleModel.getStyles();
    final DefaultComboBoxModel boxContent = new DefaultComboBoxModel(styles.toArray());
    styleBox.setModel(boxContent);
    return super.getTableCellEditorComponent(table, value, isSelected, row, column);
}
Example 55
Project: f3270-master  File: Ide.java View source code
private JComboBox getComboBoxCommand() {
    if (comboBoxCommand == null) {
        comboBoxCommand = new JComboBox();
        comboBoxCommand.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Write", "Verify", "Enter", "PF", "PA", "SysReq", "Clear" }));
        comboBoxCommand.addActionListener(new java.awt.event.ActionListener() {

            public void actionPerformed(java.awt.event.ActionEvent e) {
                comboBoxCommandActionPerformed(e);
            }
        });
    }
    return comboBoxCommand;
}
Example 56
Project: FloreantPos-master  File: SelectCookongInstructionDialog.java View source code
@Override
protected void initUI() {
    setLayout(new MigLayout());
    CookingInstructionDAO dao = new CookingInstructionDAO();
    List<CookingInstruction> cookingInstructions = dao.findAll();
    DefaultComboBoxModel cbModel = new DefaultComboBoxModel(cookingInstructions.toArray());
    cbCookingInstructions = new JComboBox(cbModel);
    cbCookingInstructions.setFont(cbCookingInstructions.getFont().deriveFont(16));
    btnNew = new PosButton("NEW");
    btnOk = new PosButton("OK");
    btnCancel = new PosButton("CANCEL");
    add(cbCookingInstructions, "wrap, span, grow, h 30");
    add(new JSeparator(), "wrap, span, grow");
    add(btnNew, "al right,width 120, height 30");
    add(btnOk, "al right,width 120, height 30");
    add(btnCancel, "width 120, height 30");
    btnNew.addActionListener(this);
    btnOk.addActionListener(this);
    btnCancel.addActionListener(this);
}
Example 57
Project: Folding-Map-master  File: CreatePolygonPanel.java View source code
/**
     * Initiate Components
     */
private void init() {
    comboModelName = new DefaultComboBoxModel();
    comboModelCoordinates = new DefaultComboBoxModel();
    comboCoordinates = new JComboBox(comboModelCoordinates);
    comboName = new JComboBox(comboModelName);
    labelCoordinates = new JLabel("Coordinates:");
    labelName = new JLabel("Name:");
}
Example 58
Project: gitools-master  File: ModulesPage.java View source code
/**
     * This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    minSizeEnableChk = new javax.swing.JCheckBox();
    minSizeValueCb = new javax.swing.JComboBox();
    jLabel1 = new javax.swing.JLabel();
    fileFormatCb = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    filePath = new javax.swing.JTextField();
    fileBrowseBtn = new javax.swing.JButton();
    maxSizeEnableChk = new javax.swing.JCheckBox();
    maxSizeValueCb = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    minSizeEnableChk.setSelected(true);
    minSizeEnableChk.setText("Omit modules having less annotated rows than");
    minSizeEnableChk.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            minSizeEnableChkItemStateChanged(evt);
        }
    });
    minSizeValueCb.setEditable(true);
    minSizeValueCb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "0", "1", "20", "30", "50", "100" }));
    minSizeValueCb.setSelectedIndex(2);
    jLabel1.setText("File format");
    fileFormatCb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Two columns mappings", "Binary data matrix" }));
    jLabel2.setText("File");
    fileBrowseBtn.setText("Browse...");
    fileBrowseBtn.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            fileBrowseBtnActionPerformed(evt);
        }
    });
    maxSizeEnableChk.setText("Omit modules having more annotated rows than");
    maxSizeValueCb.setEditable(true);
    maxSizeValueCb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "20", "30", "50", "100" }));
    maxSizeValueCb.setEnabled(false);
    jLabel3.setText("Filtering options:");
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(fileFormatCb, 0, 455, Short.MAX_VALUE).addGap(26, 26, 26)).addGroup(layout.createSequentialGroup().addComponent(jLabel3).addContainerGap(456, Short.MAX_VALUE)).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false).addComponent(minSizeEnableChk, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(maxSizeEnableChk)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(minSizeValueCb, 0, 209, Short.MAX_VALUE).addComponent(maxSizeValueCb, 0, 209, Short.MAX_VALUE)).addContainerGap()).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addComponent(jLabel2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(filePath, javax.swing.GroupLayout.DEFAULT_SIZE, 454, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(fileBrowseBtn).addContainerGap()))));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(23, 23, 23).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel2).addComponent(fileBrowseBtn).addComponent(filePath, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(fileFormatCb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel1)).addGap(18, 18, 18).addComponent(jLabel3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(minSizeEnableChk).addComponent(minSizeValueCb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(maxSizeValueCb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(maxSizeEnableChk)).addContainerGap(114, Short.MAX_VALUE)));
}
Example 59
Project: mjdj-master  File: ClockSourceCombo.java View source code
public void setList(List<TransmitterDeviceWrapper> wrappers) {
    this.wrappers = wrappers;
    String[] items = new String[wrappers.size()];
    for (int i = 0; i < wrappers.size(); i++) {
        items[i] = wrappers.get(i).getName();
    }
    setModel(new DefaultComboBoxModel(items));
    String value = Settings.getInstance().clockSourceCombo;
    setSelectedItem(value);
    onAfterSelectedItemChanged();
}
Example 60
Project: snap-desktop-master  File: CollocationFormTest.java View source code
@Test
public void testAdaptResamplingComboBoxModel() {
    final Product product = new Product("name", "type", 10, 10);
    final Band band1 = product.addBand("band1", ProductData.TYPE_INT32);
    final Band band2 = product.addBand("band2", ProductData.TYPE_INT32);
    DefaultComboBoxModel<ResamplingType> resamplingComboBoxModel = new DefaultComboBoxModel<>(ResamplingType.values());
    boolean validPixelExpressionUsed = CollocationForm.isValidPixelExpressionUsed(product);
    assertFalse(validPixelExpressionUsed);
    CollocationForm.adaptResamplingComboBoxModel(resamplingComboBoxModel, validPixelExpressionUsed);
    assertEquals(5, resamplingComboBoxModel.getSize());
    band1.setValidPixelExpression("true");
    validPixelExpressionUsed = CollocationForm.isValidPixelExpressionUsed(product);
    assertTrue(validPixelExpressionUsed);
    CollocationForm.adaptResamplingComboBoxModel(resamplingComboBoxModel, validPixelExpressionUsed);
    assertEquals(1, resamplingComboBoxModel.getSize());
    assertEquals(ResamplingType.NEAREST_NEIGHBOUR, resamplingComboBoxModel.getSelectedItem());
    band1.setValidPixelExpression(null);
    band2.setValidPixelExpression("  ");
    validPixelExpressionUsed = CollocationForm.isValidPixelExpressionUsed(product);
    assertFalse(validPixelExpressionUsed);
    CollocationForm.adaptResamplingComboBoxModel(resamplingComboBoxModel, validPixelExpressionUsed);
    assertEquals(5, resamplingComboBoxModel.getSize());
    assertEquals(ResamplingType.NEAREST_NEIGHBOUR, resamplingComboBoxModel.getSelectedItem());
}
Example 61
Project: SOAP-master  File: JComboBoxFormField.java View source code
public void setOptions(Object[] values) {
    String selectedItem = getValue();
    DefaultComboBoxModel model = new DefaultComboBoxModel(values);
    if (values.length > 0 && values[0] == null) {
        model.removeElementAt(0);
        getComponent().setEditable(true);
    } else {
        getComponent().setEditable(false);
    }
    getComponent().setModel(model);
    if (selectedItem != null) {
        getComponent().setSelectedItem(selectedItem);
    } else if (getComponent().isEditable()) {
        getComponent().setSelectedItem("");
    }
}
Example 62
Project: soapui-master  File: JComboBoxFormField.java View source code
public void setOptions(Object[] values) {
    String selectedItem = getValue();
    DefaultComboBoxModel model = new DefaultComboBoxModel(values);
    if (values.length > 0 && values[0] == null) {
        model.removeElementAt(0);
        getComponent().setEditable(true);
    } else {
        getComponent().setEditable(false);
    }
    getComponent().setModel(model);
    if (selectedItem != null) {
        getComponent().setSelectedItem(selectedItem);
    } else if (getComponent().isEditable()) {
        getComponent().setSelectedItem("");
    }
}
Example 63
Project: svarog-master  File: SynchronizeTagsWithTriggerParametersPanel.java View source code
public void fillPanelFromModel(SynchronizeTagsWithTriggerParameters model) {
    List<String> channelLabels = model.getChannelLabels();
    getChannelComboBox().setModel(new DefaultComboBoxModel(channelLabels.toArray(new String[0])));
    Pattern pattern = Pattern.compile("trig");
    for (int i = 0; i < channelLabels.size(); i++) {
        Matcher matcher = pattern.matcher(channelLabels.get(i));
        if (matcher.find()) {
            getChannelComboBox().setSelectedIndex(i);
            break;
        }
    }
}
Example 64
Project: swingsane-master  File: RotateTransformSettingsPanel.java View source code
private void initComponents() {
    GridBagLayout gridBagLayout = new GridBagLayout();
    gridBagLayout.columnWidths = new int[] { 32, 0 };
    gridBagLayout.rowHeights = new int[] { 24, 0 };
    gridBagLayout.columnWeights = new double[] { 1.0, Double.MIN_VALUE };
    gridBagLayout.rowWeights = new double[] { 0.0, Double.MIN_VALUE };
    setLayout(gridBagLayout);
    JPanel containerPanel = new JPanel();
    containerPanel.setBorder(new CompoundBorder(new TitledBorder(Localizer.localize("RotationSettingsBorderTitle")), new EmptyBorder(5, 5, 5, 5)));
    GridBagConstraints gbc_containerPanel = new GridBagConstraints();
    gbc_containerPanel.fill = GridBagConstraints.HORIZONTAL;
    gbc_containerPanel.anchor = GridBagConstraints.NORTH;
    gbc_containerPanel.gridx = 0;
    gbc_containerPanel.gridy = 0;
    add(containerPanel, gbc_containerPanel);
    GridBagLayout gbl_containerPanel = new GridBagLayout();
    gbl_containerPanel.columnWidths = new int[] { 0, 0 };
    gbl_containerPanel.rowHeights = new int[] { 24, 0 };
    gbl_containerPanel.columnWeights = new double[] { 1.0, Double.MIN_VALUE };
    gbl_containerPanel.rowWeights = new double[] { 0.0, Double.MIN_VALUE };
    containerPanel.setLayout(gbl_containerPanel);
    rotationComboBox = new JComboBox<Rotation>();
    rotationComboBox.addActionListener(new ActionListener() {

        @Override
        public void actionPerformed(ActionEvent e) {
            rotationSelectionActionPerformed(e);
        }
    });
    rotationComboBox.setFont(UIManager.getFont("ComboBox.font"));
    rotationComboBox.setModel(new DefaultComboBoxModel<Rotation>(new Rotation[] { Rotation.CW_90, Rotation.CW_180, Rotation.CW_270 }));
    GridBagConstraints gbc_rotationComboBox = new GridBagConstraints();
    gbc_rotationComboBox.anchor = GridBagConstraints.NORTH;
    gbc_rotationComboBox.gridx = 0;
    gbc_rotationComboBox.gridy = 0;
    containerPanel.add(rotationComboBox, gbc_rotationComboBox);
}
Example 65
Project: Tank-master  File: FilterComboBox.java View source code
public void comboFilter(String enteredText) {
    List<String> filterArray = new ArrayList<String>();
    for (int i = 0; i < array.size(); i++) {
        if (array.get(i).toLowerCase().contains(enteredText.toLowerCase())) {
            filterArray.add(array.get(i));
        }
    }
    if (filterArray.size() > 0) {
        this.setModel(new DefaultComboBoxModel(filterArray.toArray()));
        this.setSelectedItem(enteredText);
        this.showPopup();
    } else {
        this.hidePopup();
    }
}
Example 66
Project: zaproxy-master  File: ContextSelectComboBox.java View source code
/**
	 * Reloads/refreshes the list of [email protected] Context Contexts} from the [email protected] Session}.
	 * 
	 * @param keepSelected whether the previously selected context is tried to be restored. If
	 *            [email protected] false}, defaults to no selection.
	 */
public void reloadContexts(boolean keepSelected) {
    Context selected = null;
    if (keepSelected)
        selected = (Context) getSelectedItem();
    List<Context> contexts = Model.getSingleton().getSession().getContexts();
    Context[] contextsArray = contexts.toArray(new Context[contexts.size()]);
    ComboBoxModel<Context> model = new DefaultComboBoxModel<>(contextsArray);
    // No matter what, set selected item, so it either defaults to 'nothing selected' or
    // restores the previously selected item
    model.setSelectedItem(selected);
    this.setModel(model);
}
Example 67
Project: GeneDB-master  File: GoPanel.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    evidenceLabel = new javax.swing.JLabel();
    cvLabel = new javax.swing.JLabel();
    evidenceCombo = new javax.swing.JComboBox();
    cvCombo = new javax.swing.JComboBox();
    jScrollPane1 = new javax.swing.JScrollPane();
    jList1 = new javax.swing.JList();
    jLabel1 = new javax.swing.JLabel();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    termLabel = new javax.swing.JLabel();
    withFromLabel = new javax.swing.JLabel();
    urlLabel = new javax.swing.JLabel();
    attributionLabel = new javax.swing.JLabel();
    urlField = new javax.swing.JTextField();
    attributionField = new javax.swing.JTextField();
    withField = new javax.swing.JTextField();
    jComboBox4 = new javax.swing.JComboBox();
    clearButton = new javax.swing.JButton();
    transferButton = new javax.swing.JButton();
    setBorder(javax.swing.BorderFactory.createTitledBorder("GO"));
    evidenceLabel.setText("Evidence");
    cvLabel.setText("CV");
    evidenceCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cvCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    jList1.setModel(new javax.swing.AbstractListModel() {

        String[] strings = { "Item 1", "Item 2", "Item 3", "Item 4", "Item 5" };

        public int getSize() {
            return strings.length;
        }

        public Object getElementAt(int i) {
            return strings[i];
        }
    });
    jScrollPane1.setViewportView(jList1);
    jLabel1.setText("Qualifiers");
    jButton1.setText("+");
    jButton1.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton1ActionPerformed(evt);
        }
    });
    jButton2.setText("-");
    termLabel.setText("Term");
    withFromLabel.setText("with");
    urlLabel.setText("URL");
    attributionLabel.setText("Attribution");
    urlField.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            urlFieldActionPerformed(evt);
        }
    });
    attributionField.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            attributionFieldActionPerformed(evt);
        }
    });
    withField.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            withFieldActionPerformed(evt);
        }
    });
    jComboBox4.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    clearButton.setLabel("Clear");
    clearButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            clearButtonActionPerformed(evt);
        }
    });
    transferButton.setLabel("Transfer");
    transferButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            transferButtonActionPerformed(evt);
        }
    });
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(evidenceLabel).addComponent(cvLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(evidenceCombo, javax.swing.GroupLayout.Alignment.TRAILING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(cvCombo, javax.swing.GroupLayout.Alignment.TRAILING, 0, 104, Short.MAX_VALUE))).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false).addComponent(jScrollPane1).addGroup(layout.createSequentialGroup().addComponent(jLabel1).addGap(29, 29, 29).addComponent(jButton1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton2))).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED))).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 39, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(termLabel, javax.swing.GroupLayout.Alignment.TRAILING).addComponent(withFromLabel, javax.swing.GroupLayout.Alignment.TRAILING).addComponent(urlLabel, javax.swing.GroupLayout.Alignment.TRAILING).addComponent(attributionLabel, javax.swing.GroupLayout.Alignment.TRAILING)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(urlField).addComponent(attributionField).addComponent(withField).addComponent(jComboBox4, 0, 291, Short.MAX_VALUE)).addContainerGap()).addGroup(layout.createSequentialGroup().addGap(147, 147, 147).addComponent(clearButton).addGap(18, 18, 18).addComponent(transferButton).addContainerGap()))));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(cvLabel).addComponent(cvCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jComboBox4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(termLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(withField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(withFromLabel).addComponent(evidenceLabel).addComponent(evidenceCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(attributionField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(attributionLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(urlField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(urlLabel).addComponent(jLabel1).addComponent(jButton1).addComponent(jButton2)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 99, javax.swing.GroupLayout.PREFERRED_SIZE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(clearButton).addComponent(transferButton))).addGap(24, 24, 24)));
}
Example 68
Project: nbruby-master  File: GemRequirementDetailsPanel.java View source code
private void initRequiredVersion() {
    DefaultComboBoxModel model = new DefaultComboBoxModel();
    for (String operator : GemRequirement.getOperators()) {
        model.addElement(operator);
    }
    operatorCombo.setModel(model);
    if (!isEmpty(gemRequirement.getOperator())) {
        operatorCombo.setSelectedItem(gemRequirement.getOperator());
    }
}
Example 69
Project: WorldPainter-master  File: TextDialog.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jComboBox1 = new javax.swing.JComboBox();
    jSpinner1 = new javax.swing.JSpinner();
    jToggleButton1 = new javax.swing.JToggleButton();
    jToggleButton2 = new javax.swing.JToggleButton();
    jScrollPane1 = new javax.swing.JScrollPane();
    jTextArea1 = new javax.swing.JTextArea();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    jComboBox2 = new javax.swing.JComboBox();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle("Enter Text");
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    jSpinner1.setModel(new javax.swing.SpinnerNumberModel(18, 1, 999, 1));
    jToggleButton1.setFont(jToggleButton1.getFont().deriveFont(jToggleButton1.getFont().getStyle() | java.awt.Font.BOLD));
    jToggleButton1.setText("B");
    jToggleButton1.setToolTipText("Bold");
    jToggleButton2.setFont(jToggleButton2.getFont().deriveFont((jToggleButton2.getFont().getStyle() | java.awt.Font.ITALIC)));
    jToggleButton2.setText("I");
    jToggleButton2.setToolTipText("Italic");
    jTextArea1.setColumns(20);
    jTextArea1.setRows(5);
    jScrollPane1.setViewportView(jTextArea1);
    jButton1.setText("Cancel");
    jButton1.addActionListener(this::jButton1ActionPerformed);
    jButton2.setText("OK");
    jButton2.addActionListener(this::jButton2ActionPerformed);
    jLabel1.setText("Font:");
    jLabel2.setText("Size:");
    jLabel3.setText("Angle:");
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "0 °", "-90 °", "180 °", "90 °" }));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addGap(0, 0, Short.MAX_VALUE).addComponent(jButton2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton1)).addComponent(jScrollPane1).addGroup(layout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jLabel2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jSpinner1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jToggleButton1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jToggleButton2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jLabel3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 77, Short.MAX_VALUE))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jSpinner1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jToggleButton1).addComponent(jToggleButton2).addComponent(jLabel1).addComponent(jLabel2).addComponent(jLabel3).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 304, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1).addComponent(jButton2)).addContainerGap()));
    pack();
}
Example 70
Project: studio-master  File: FindDialogSupport.java View source code
private void updateHistory(JComboBox c, String identifier) {
    Object item = c.getEditor().getItem();
    List history = getHistory(identifier);
    if (item != null) {
        int index = history.indexOf(item);
        if (index >= 0) {
            history.remove(index);
        }
        history.add(0, item);
    }
    putHistory(identifier, history);
    javax.swing.DefaultComboBoxModel m = new javax.swing.DefaultComboBoxModel(history.toArray());
    c.setModel(m);
}
Example 71
Project: dawn-third-master  File: ScreenRecorderMain.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    formatLabel = new javax.swing.JLabel();
    formatChoice = new javax.swing.JComboBox();
    colorsLabel = new javax.swing.JLabel();
    colorsChoice = new javax.swing.JComboBox();
    infoLabel = new javax.swing.JLabel();
    startStopButton = new javax.swing.JButton();
    mouseLabel = new javax.swing.JLabel();
    cursorChoice = new javax.swing.JComboBox();
    audioRateLabel = new javax.swing.JLabel();
    audioRateChoice = new javax.swing.JComboBox();
    screenRateLabel = new javax.swing.JLabel();
    screenRateField = new javax.swing.JSpinner();
    mouseRateLabel = new javax.swing.JLabel();
    mouseRateField = new javax.swing.JSpinner();
    encodingLabel = new javax.swing.JLabel();
    encodingChoice = new javax.swing.JComboBox();
    areaLabel = new javax.swing.JLabel();
    areaChoice = new javax.swing.JComboBox();
    selectAreaButton = new javax.swing.JButton();
    stateLabel = new javax.swing.JLabel();
    audioSourceLabel = new javax.swing.JLabel();
    audioSourceChoice = new javax.swing.JComboBox();
    FormListener formListener = new FormListener();
    setDefaultCloseOperation(javax.swing.WindowConstants.DO_NOTHING_ON_CLOSE);
    setTitle("Monte Screen Recorder");
    setResizable(false);
    addWindowListener(formListener);
    formatLabel.setText("Format:");
    formatChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "AVI", "QuickTime" }));
    formatChoice.addActionListener(formListener);
    colorsLabel.setText("Colors:");
    colorsChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Hundreds", "Thousands", "Millions" }));
    // NOI18N
    infoLabel.setFont(new java.awt.Font("Lucida Grande", 0, 11));
    infoLabel.setText("<html>The recording will be stored in the folder \"Movies\".<br> Drop a folder on this text to change the storage location.<br> A new file will be created every hour or when the file size limit is reached.<br> <br>This window will be minized before the recording starts.<br> To stop the recording, restore this window and press the Stop button.<br> ");
    startStopButton.setText("Start");
    startStopButton.addActionListener(formListener);
    mouseLabel.setText("Mouse:");
    cursorChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "No Cursor", "Black Cursor", "White Cursor" }));
    audioRateLabel.setText("Audio Rate:");
    audioRateChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "44.100 kHz" }));
    screenRateLabel.setText("Screen Rate:");
    mouseRateLabel.setText("Mouse Rate:");
    encodingLabel.setText("Encoding:");
    encodingChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Screen Capture", "Run Length", "None", "PNG", "JPEG 100 %", "JPEG   50 %" }));
    areaLabel.setText("Area:");
    areaChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Entire Screen", "0 0,  1024 x 768", " " }));
    selectAreaButton.setText("Custom Area...");
    selectAreaButton.addActionListener(formListener);
    stateLabel.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
    stateLabel.setText(" ");
    audioSourceLabel.setText("Audio:");
    audioSourceChoice.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "No Audio", "44.100 kHz" }));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addComponent(stateLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 190, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(startStopButton).addGap(10, 10, 10)).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(colorsLabel).addComponent(mouseLabel).addComponent(formatLabel).addComponent(areaLabel).addComponent(audioSourceLabel)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(formatChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(colorsChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(cursorChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(audioSourceChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(screenRateLabel, javax.swing.GroupLayout.Alignment.TRAILING).addComponent(mouseRateLabel, javax.swing.GroupLayout.Alignment.TRAILING)).addComponent(encodingLabel).addComponent(audioRateLabel)).addGap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(audioRateChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(encodingChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(screenRateField, javax.swing.GroupLayout.PREFERRED_SIZE, 77, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(mouseRateField, javax.swing.GroupLayout.PREFERRED_SIZE, 77, javax.swing.GroupLayout.PREFERRED_SIZE))).addGroup(layout.createSequentialGroup().addComponent(areaChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(selectAreaButton)))).addComponent(infoLabel)).addContainerGap()));
    layout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] { audioRateChoice, colorsChoice, cursorChoice, formatChoice });
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(formatChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(formatLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(colorsChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(colorsLabel)).addGap(11, 11, 11).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(cursorChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(mouseLabel))).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(encodingChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(encodingLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER).addComponent(screenRateField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(screenRateLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER).addComponent(mouseRateField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(mouseRateLabel)))).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(audioRateChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(audioRateLabel).addComponent(audioSourceLabel).addComponent(audioSourceChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(areaChoice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(areaLabel).addComponent(selectAreaButton)).addGap(18, 18, 18).addComponent(infoLabel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 8, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(startStopButton).addComponent(stateLabel)).addContainerGap()));
    pack();
}
Example 72
Project: Pokeboard-1v1-master  File: PokeboardUI.java View source code
/**
	 * This method is called from within the constructor to initialize the form.
	 * WARNING: Do NOT modify this code. The content of this method is always
	 * regenerated by the Form Editor.
	 */
// <editor-fold defaultstate="collapsed" desc="Generated
// Code">//GEN-BEGIN:initComponents
private void initComponents() {
    JohtoActiveZoom = new javax.swing.JLabel();
    KantoActiveZoom = new javax.swing.JLabel();
    JohtoActiveCard = new javax.swing.JFrame();
    KantoActiveCard = new javax.swing.JFrame();
    JohtoActivePic = new javax.swing.JLabel();
    Background = new javax.swing.JLayeredPane();
    Stadium = new javax.swing.JComboBox<>();
    JohtoActiveComboBox = new javax.swing.JComboBox<>();
    JohtoPrize1 = new javax.swing.JLabel();
    JohtoPrize2 = new javax.swing.JLabel();
    JohtoPrize3 = new javax.swing.JLabel();
    JohtoPrize4 = new javax.swing.JLabel();
    JohtoPrize5 = new javax.swing.JLabel();
    JohtoPrize6 = new javax.swing.JLabel();
    KantoPrize1 = new javax.swing.JLabel();
    KantoPrize2 = new javax.swing.JLabel();
    KantoPrize3 = new javax.swing.JLabel();
    KantoPrize4 = new javax.swing.JLabel();
    KantoPrize5 = new javax.swing.JLabel();
    KantoPrize6 = new javax.swing.JLabel();
    JohtoActiveEnergy1 = new javax.swing.JButton();
    JohtoActiveEnergy2 = new javax.swing.JButton();
    JohtoActiveEnergy3 = new javax.swing.JButton();
    JohtoActiveEnergy4 = new javax.swing.JButton();
    JohtoBench5ComboBox = new javax.swing.JComboBox<>();
    JohtoBench5Energy1 = new javax.swing.JButton();
    JohtoBench5Energy2 = new javax.swing.JButton();
    JohtoBench5Energy3 = new javax.swing.JButton();
    JohtoBench5Energy4 = new javax.swing.JButton();
    JohtoBench4ComboBox = new javax.swing.JComboBox<>();
    JohtoBench4Energy1 = new javax.swing.JButton();
    JohtoBench4Energy2 = new javax.swing.JButton();
    JohtoBench4Energy3 = new javax.swing.JButton();
    JohtoBench4Energy4 = new javax.swing.JButton();
    JohtoBench3ComboBox = new javax.swing.JComboBox<>();
    JohtoBench3Energy1 = new javax.swing.JButton();
    JohtoBench3Energy2 = new javax.swing.JButton();
    JohtoBench3Energy3 = new javax.swing.JButton();
    JohtoBench3Energy4 = new javax.swing.JButton();
    JohtoBench2ComboBox = new javax.swing.JComboBox<>();
    JohtoBench2Energy1 = new javax.swing.JButton();
    JohtoBench2Energy2 = new javax.swing.JButton();
    JohtoBench2Energy3 = new javax.swing.JButton();
    JohtoBench2Energy4 = new javax.swing.JButton();
    JohtoBench1ComboBox = new javax.swing.JComboBox<>();
    JohtoBench1Energy4 = new javax.swing.JButton();
    JohtoBench1Energy3 = new javax.swing.JButton();
    JohtoBench1Energy2 = new javax.swing.JButton();
    JohtoBench1Energy1 = new javax.swing.JButton();
    KantoActiveComboBox = new javax.swing.JComboBox<>();
    KantoBench1ComboBox = new javax.swing.JComboBox<>();
    KantoBench2ComboBox = new javax.swing.JComboBox<>();
    KantoBench3ComboBox = new javax.swing.JComboBox<>();
    KantoBench4ComboBox = new javax.swing.JComboBox<>();
    KantoBench5ComboBox = new javax.swing.JComboBox<>();
    ClearButton = new javax.swing.JButton();
    JohtoPlus = new javax.swing.JButton();
    JohtoMinus = new javax.swing.JButton();
    JohtoDamageNumB5 = new javax.swing.JTextField();
    JohtoDamageNum = new javax.swing.JTextField();
    JohtoDamageNumB4 = new javax.swing.JTextField();
    JohtoDamageNumB3 = new javax.swing.JTextField();
    JohtoDamageNumB2 = new javax.swing.JTextField();
    JohtoDamageNumB1 = new javax.swing.JTextField();
    KantoPlus = new javax.swing.JButton();
    KantoMinus = new javax.swing.JButton();
    KantoDamageNum = new javax.swing.JTextField();
    KantoDamageNumB5 = new javax.swing.JTextField();
    KantoDamageNumB4 = new javax.swing.JTextField();
    KantoDamageNumB3 = new javax.swing.JTextField();
    KantoDamageNumB2 = new javax.swing.JTextField();
    KantoDamageNumB1 = new javax.swing.JTextField();
    StadiumCard = new javax.swing.JLabel();
    JohtoCard = new javax.swing.JLabel();
    KantoCard = new javax.swing.JLabel();
    mid = new javax.swing.JLabel();
    Kanto = new javax.swing.JLabel();
    Johto = new javax.swing.JLabel();
    KantoActiveEnergy1 = new javax.swing.JButton();
    KantoActiveEnergy2 = new javax.swing.JButton();
    KantoActiveEnergy3 = new javax.swing.JButton();
    KantoActiveEnergy4 = new javax.swing.JButton();
    KantoBench5Energy4 = new javax.swing.JButton();
    KantoBench5Energy3 = new javax.swing.JButton();
    KantoBench5Energy2 = new javax.swing.JButton();
    KantoBench5Energy1 = new javax.swing.JButton();
    KantoBench4Energy4 = new javax.swing.JButton();
    KantoBench4Energy3 = new javax.swing.JButton();
    KantoBench4Energy2 = new javax.swing.JButton();
    KantoBench4Energy1 = new javax.swing.JButton();
    KantoBench3Energy4 = new javax.swing.JButton();
    KantoBench3Energy3 = new javax.swing.JButton();
    KantoBench3Energy2 = new javax.swing.JButton();
    KantoBench3Energy1 = new javax.swing.JButton();
    KantoBench2Energy4 = new javax.swing.JButton();
    KantoBench2Energy3 = new javax.swing.JButton();
    KantoBench2Energy2 = new javax.swing.JButton();
    KantoBench2Energy1 = new javax.swing.JButton();
    KantoBench1Energy4 = new javax.swing.JButton();
    KantoBench1Energy3 = new javax.swing.JButton();
    KantoBench1Energy2 = new javax.swing.JButton();
    KantoBench1Energy1 = new javax.swing.JButton();
    JohtoPZ = new javax.swing.JButton();
    JohtoSL = new javax.swing.JButton();
    JohtoPO = new javax.swing.JButton();
    JohtoBR = new javax.swing.JButton();
    JohtoCN = new javax.swing.JButton();
    KantoCN = new javax.swing.JButton();
    KantoBR = new javax.swing.JButton();
    KantoPO = new javax.swing.JButton();
    KantoSL = new javax.swing.JButton();
    KantoPZ = new javax.swing.JButton();
    KantoBench5Switch = new javax.swing.JButton();
    KantoBench4Switch = new javax.swing.JButton();
    KantoBench3Switch = new javax.swing.JButton();
    KantoBench2Switch = new javax.swing.JButton();
    KantoBench1Switch = new javax.swing.JButton();
    JohtoBench5Switch = new javax.swing.JButton();
    JohtoBench4Switch = new javax.swing.JButton();
    JohtoBench3Switch = new javax.swing.JButton();
    JohtoBench2Switch = new javax.swing.JButton();
    JohtoBench1Switch = new javax.swing.JButton();
    KantoClear = new javax.swing.JButton();
    JohtoClear = new javax.swing.JButton();
    // NOI18N
    JohtoActivePic.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
    JohtoActiveCard.setAlwaysOnTop(true);
    JohtoActiveCard.setMinimumSize(new java.awt.Dimension(425, 575));
    JohtoActiveCard.setPreferredSize(new java.awt.Dimension(425, 575));
    JohtoActiveCard.setSize(new java.awt.Dimension(425, 575));
    JohtoActiveCard.setType(java.awt.Window.Type.UTILITY);
    KantoActiveCard.setAlwaysOnTop(true);
    KantoActiveCard.setMinimumSize(new java.awt.Dimension(425, 575));
    KantoActiveCard.setPreferredSize(new java.awt.Dimension(425, 575));
    KantoActiveCard.setSize(new java.awt.Dimension(425, 575));
    KantoActiveCard.setType(java.awt.Window.Type.UTILITY);
    javax.swing.GroupLayout JohtoActiveCardLayout = new javax.swing.GroupLayout(JohtoActiveCard.getContentPane());
    JohtoActiveCard.getContentPane().setLayout(JohtoActiveCardLayout);
    JohtoActiveCardLayout.setHorizontalGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 400, Short.MAX_VALUE).addGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, JohtoActiveCardLayout.createSequentialGroup().addContainerGap(36, Short.MAX_VALUE).addComponent(JohtoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(191, Short.MAX_VALUE))));
    JohtoActiveCardLayout.setVerticalGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 300, Short.MAX_VALUE).addGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(JohtoActiveCardLayout.createSequentialGroup().addComponent(JohtoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 30, Short.MAX_VALUE))));
    javax.swing.GroupLayout KantoActiveCardLayout = new javax.swing.GroupLayout(KantoActiveCard.getContentPane());
    KantoActiveCard.getContentPane().setLayout(KantoActiveCardLayout);
    KantoActiveCardLayout.setHorizontalGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 400, Short.MAX_VALUE).addGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, KantoActiveCardLayout.createSequentialGroup().addContainerGap(36, Short.MAX_VALUE).addComponent(KantoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, 400, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(191, Short.MAX_VALUE))));
    KantoActiveCardLayout.setVerticalGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 300, Short.MAX_VALUE).addGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(KantoActiveCardLayout.createSequentialGroup().addComponent(KantoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, 551, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 30, Short.MAX_VALUE))));
    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    setTitle("Pokeleague 2015");
    setAlwaysOnTop(true);
    setBackground(new java.awt.Color(0, 0, 0));
    setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));
    setForeground(java.awt.Color.black);
    Background.setAlignmentX(0.0F);
    Background.setAlignmentY(0.0F);
    Background.setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());
    Stadium.setEditable(true);
    Stadium.setModel(new javax.swing.DefaultComboBoxModel<>(stadiumCards));
    AutoCompleteDecorator.decorate(Stadium);
    Stadium.addItemListener(this::StadiumItemStateChanged);
    Background.add(Stadium, new org.netbeans.lib.awtextra.AbsoluteConstraints(90, 200, 150, 20));
    // NOI18N
    JohtoActiveZoom.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
    JohtoActiveZoom.setMaximumSize(new java.awt.Dimension(400, 551));
    JohtoActiveZoom.setMinimumSize(new java.awt.Dimension(400, 551));
    JohtoActiveZoom.setPreferredSize(new java.awt.Dimension(400, 551));
    // NOI18N
    KantoActiveZoom.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
    KantoActiveZoom.setMaximumSize(new java.awt.Dimension(400, 551));
    KantoActiveZoom.setMinimumSize(new java.awt.Dimension(400, 551));
    KantoActiveZoom.setPreferredSize(new java.awt.Dimension(400, 551));
    JohtoActiveComboBox.setEditable(true);
    // JohtoActive.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    JohtoActiveComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    JohtoActiveComboBox.addItemListener(this::JohtoActiveItemStateChanged);
    AutoCompleteDecorator.decorate(JohtoActiveComboBox);
    Background.add(JohtoActiveComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(280, 260, 210, 20));
    // NOI18N
    JohtoPrize1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    JohtoPrize1.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    JohtoPrize1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPrize1MouseClicked(evt);
        }
    });
    Background.add(JohtoPrize1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 170, 21, 30));
    // NOI18N
    JohtoPrize2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    JohtoPrize2.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    JohtoPrize2.setPreferredSize(new java.awt.Dimension(14, 20));
    JohtoPrize2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPrize2MouseClicked(evt);
        }
    });
    Background.add(JohtoPrize2, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 170, 21, 30));
    // NOI18N
    JohtoPrize3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    JohtoPrize3.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    JohtoPrize3.setPreferredSize(new java.awt.Dimension(21, 30));
    JohtoPrize3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPrize3MouseClicked(evt);
        }
    });
    Background.add(JohtoPrize3, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 210, 21, 30));
    // NOI18N
    JohtoPrize4.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    JohtoPrize4.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    JohtoPrize4.setMaximumSize(new java.awt.Dimension(21, 30));
    JohtoPrize4.setMinimumSize(new java.awt.Dimension(21, 30));
    JohtoPrize4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPrize4MouseClicked(evt);
        }
    });
    Background.add(JohtoPrize4, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 210, 21, 30));
    // NOI18N
    JohtoPrize5.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    JohtoPrize5.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    JohtoPrize5.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPrize5MouseClicked(evt);
        }
    });
    Background.add(JohtoPrize5, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 250, 20, 30));
    // NOI18N
    JohtoPrize6.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    JohtoPrize6.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    JohtoPrize6.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPrize6MouseClicked(evt);
        }
    });
    Background.add(JohtoPrize6, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 250, 20, 30));
    // NOI18N
    KantoPrize1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    KantoPrize1.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    KantoPrize1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPrize1MouseClicked(evt);
        }
    });
    Background.add(KantoPrize1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 450, 21, 30));
    // NOI18N
    KantoPrize2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    KantoPrize2.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    KantoPrize2.setPreferredSize(new java.awt.Dimension(14, 20));
    KantoPrize2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPrize2MouseClicked(evt);
        }
    });
    Background.add(KantoPrize2, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 450, 21, 30));
    // NOI18N
    KantoPrize3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    KantoPrize3.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    KantoPrize3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPrize3MouseClicked(evt);
        }
    });
    Background.add(KantoPrize3, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 490, 21, 30));
    // NOI18N
    KantoPrize4.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    KantoPrize4.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    KantoPrize4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPrize4MouseClicked(evt);
        }
    });
    Background.add(KantoPrize4, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 490, 21, 30));
    // NOI18N
    KantoPrize5.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    KantoPrize5.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    KantoPrize5.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPrize5MouseClicked(evt);
        }
    });
    Background.add(KantoPrize5, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 530, 20, 30));
    // NOI18N
    KantoPrize6.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
    KantoPrize6.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    KantoPrize6.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPrize6MouseClicked(evt);
        }
    });
    Background.add(KantoPrize6, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 530, 20, 30));
    JohtoActiveEnergy1.setBackground(java.awt.Color.lightGray);
    JohtoActiveEnergy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoActiveEnergy1MouseClicked(evt);
        }
    });
    Background.add(JohtoActiveEnergy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 240, -1, 20));
    Background.setLayer(JohtoActiveEnergy1, 1);
    JohtoActiveEnergy2.setBackground(java.awt.Color.lightGray);
    JohtoActiveEnergy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoActiveEnergy2MouseClicked(evt);
        }
    });
    Background.add(JohtoActiveEnergy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(360, 240, 30, 20));
    Background.setLayer(JohtoActiveEnergy2, 2);
    JohtoActiveEnergy3.setBackground(java.awt.Color.lightGray);
    JohtoActiveEnergy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoActiveEnergy3MouseClicked(evt);
        }
    });
    Background.add(JohtoActiveEnergy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 240, 30, 20));
    Background.setLayer(JohtoActiveEnergy3, 3);
    JohtoActiveEnergy4.setBackground(java.awt.Color.lightGray);
    JohtoActiveEnergy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoActiveEnergy4MouseClicked(evt);
        }
    });
    Background.add(JohtoActiveEnergy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(400, 240, 30, 20));
    Background.setLayer(JohtoActiveEnergy4, 4);
    JohtoBench5ComboBox.setEditable(true);
    // JohtoBench5.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    JohtoBench5ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(JohtoBench5ComboBox);
    Background.add(JohtoBench5ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 70, 100, 20));
    JohtoBench5Energy1.setBackground(java.awt.Color.lightGray);
    JohtoBench5Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench5Energy1MouseClicked(evt);
        }
    });
    Background.add(JohtoBench5Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 50, -1, 20));
    Background.setLayer(JohtoBench5Energy1, 1);
    JohtoBench5Energy2.setBackground(java.awt.Color.lightGray);
    JohtoBench5Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench5Energy2MouseClicked(evt);
        }
    });
    Background.add(JohtoBench5Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(660, 50, 30, 20));
    Background.setLayer(JohtoBench5Energy2, 2);
    JohtoBench5Energy3.setBackground(java.awt.Color.lightGray);
    JohtoBench5Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench5Energy3MouseClicked(evt);
        }
    });
    Background.add(JohtoBench5Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(680, 50, 30, 20));
    Background.setLayer(JohtoBench5Energy3, 3);
    JohtoBench5Energy4.setBackground(java.awt.Color.lightGray);
    JohtoBench5Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench5Energy4MouseClicked(evt);
        }
    });
    Background.add(JohtoBench5Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(700, 50, 30, 20));
    Background.setLayer(JohtoBench5Energy4, 4);
    JohtoBench4ComboBox.setEditable(true);
    // JohtoBench4.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    JohtoBench4ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(JohtoBench4ComboBox);
    Background.add(JohtoBench4ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 70, 100, 20));
    JohtoBench4Energy1.setBackground(java.awt.Color.lightGray);
    JohtoBench4Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench4Energy1MouseClicked(evt);
        }
    });
    Background.add(JohtoBench4Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 50, -1, 20));
    Background.setLayer(JohtoBench4Energy1, 1);
    JohtoBench4Energy2.setBackground(java.awt.Color.lightGray);
    JohtoBench4Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench4Energy2MouseClicked(evt);
        }
    });
    Background.add(JohtoBench4Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(510, 50, 30, 20));
    Background.setLayer(JohtoBench4Energy2, 2);
    JohtoBench4Energy3.setBackground(java.awt.Color.lightGray);
    JohtoBench4Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench4Energy3MouseClicked(evt);
        }
    });
    Background.add(JohtoBench4Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(530, 50, 30, 20));
    Background.setLayer(JohtoBench4Energy3, 3);
    JohtoBench4Energy4.setBackground(java.awt.Color.lightGray);
    JohtoBench4Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench4Energy4MouseClicked(evt);
        }
    });
    Background.add(JohtoBench4Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 50, 30, 20));
    Background.setLayer(JohtoBench4Energy4, 4);
    JohtoBench3ComboBox.setEditable(true);
    // JohtoBench3.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    JohtoBench3ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(JohtoBench3ComboBox);
    Background.add(JohtoBench3ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 70, 100, 20));
    JohtoBench3Energy1.setBackground(java.awt.Color.lightGray);
    JohtoBench3Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench3Energy1MouseClicked(evt);
        }
    });
    Background.add(JohtoBench3Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 50, -1, 20));
    Background.setLayer(JohtoBench3Energy1, 1);
    JohtoBench3Energy2.setBackground(java.awt.Color.lightGray);
    JohtoBench3Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench3Energy2MouseClicked(evt);
        }
    });
    Background.add(JohtoBench3Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(350, 50, 30, 20));
    Background.setLayer(JohtoBench3Energy2, 2);
    JohtoBench3Energy3.setBackground(java.awt.Color.lightGray);
    JohtoBench3Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench3Energy3MouseClicked(evt);
        }
    });
    Background.add(JohtoBench3Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 50, 30, 20));
    Background.setLayer(JohtoBench3Energy3, 3);
    JohtoBench3Energy4.setBackground(java.awt.Color.lightGray);
    JohtoBench3Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench3Energy4MouseClicked(evt);
        }
    });
    Background.add(JohtoBench3Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 50, 30, 20));
    Background.setLayer(JohtoBench3Energy4, 4);
    JohtoBench2ComboBox.setEditable(true);
    // JohtoBench2.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    JohtoBench2ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(JohtoBench2ComboBox);
    Background.add(JohtoBench2ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 70, 100, 20));
    JohtoBench2Energy1.setBackground(java.awt.Color.lightGray);
    JohtoBench2Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench2Energy1MouseClicked(evt);
        }
    });
    Background.add(JohtoBench2Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 50, -1, 20));
    Background.setLayer(JohtoBench2Energy1, 1);
    JohtoBench2Energy2.setBackground(java.awt.Color.lightGray);
    JohtoBench2Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench2Energy2MouseClicked(evt);
        }
    });
    Background.add(JohtoBench2Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(190, 50, 30, 20));
    Background.setLayer(JohtoBench2Energy2, 2);
    JohtoBench2Energy3.setBackground(java.awt.Color.lightGray);
    JohtoBench2Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench2Energy3MouseClicked(evt);
        }
    });
    Background.add(JohtoBench2Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(210, 50, 30, 20));
    Background.setLayer(JohtoBench2Energy3, 3);
    JohtoBench2Energy4.setBackground(java.awt.Color.lightGray);
    JohtoBench2Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench2Energy4MouseClicked(evt);
        }
    });
    Background.add(JohtoBench2Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(230, 50, 30, 20));
    Background.setLayer(JohtoBench2Energy4, 4);
    JohtoBench1ComboBox.setEditable(true);
    // JohtoBench1.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    JohtoBench1ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(JohtoBench1ComboBox);
    Background.add(JohtoBench1ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 70, 100, 20));
    JohtoBench1Energy4.setBackground(java.awt.Color.lightGray);
    JohtoBench1Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench1Energy4MouseClicked(evt);
        }
    });
    Background.add(JohtoBench1Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(70, 50, 30, 20));
    Background.setLayer(JohtoBench1Energy4, 4);
    JohtoBench1Energy3.setBackground(java.awt.Color.lightGray);
    JohtoBench1Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench1Energy3MouseClicked(evt);
        }
    });
    Background.add(JohtoBench1Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(50, 50, 30, 20));
    Background.setLayer(JohtoBench1Energy3, 3);
    JohtoBench1Energy2.setBackground(java.awt.Color.lightGray);
    JohtoBench1Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench1Energy2MouseClicked(evt);
        }
    });
    Background.add(JohtoBench1Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(30, 50, 30, 20));
    Background.setLayer(JohtoBench1Energy2, 2);
    JohtoBench1Energy1.setBackground(java.awt.Color.lightGray);
    JohtoBench1Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench1Energy1MouseClicked(evt);
        }
    });
    Background.add(JohtoBench1Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 50, -1, 20));
    Background.setLayer(JohtoBench1Energy1, 1);
    KantoActiveComboBox.setEditable(true);
    // KantoActive.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    KantoActiveComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    KantoActiveComboBox.addItemListener(this::KantoActiveItemStateChanged);
    AutoCompleteDecorator.decorate(KantoActiveComboBox);
    Background.add(KantoActiveComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(280, 460, 210, 20));
    KantoBench1ComboBox.setEditable(true);
    // KantoBench1.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    KantoBench1ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(KantoBench1ComboBox);
    Background.add(KantoBench1ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 620, 100, 20));
    KantoBench2ComboBox.setEditable(true);
    // KantoBench1.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    KantoBench2ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(KantoBench2ComboBox);
    Background.add(KantoBench2ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 620, 100, 20));
    KantoBench3ComboBox.setEditable(true);
    // KantoBench3.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    KantoBench3ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(KantoBench3ComboBox);
    Background.add(KantoBench3ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 620, 100, 20));
    KantoBench4ComboBox.setEditable(true);
    // KantoBench4.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    KantoBench4ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(KantoBench4ComboBox);
    Background.add(KantoBench4ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 620, 100, 20));
    KantoBench5ComboBox.setEditable(true);
    // KantoBench5.setModel(new
    // javax.swing.DefaultComboBoxModel(PokemonList));
    KantoBench5ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
    AutoCompleteDecorator.decorate(KantoBench5ComboBox);
    Background.add(KantoBench5ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 620, 100, 20));
    ClearButton.setBackground(new java.awt.Color(0, 0, 0));
    // NOI18N
    ClearButton.setFont(new java.awt.Font("Tahoma", Font.PLAIN, 12));
    ClearButton.setForeground(new java.awt.Color(204, 0, 0));
    ClearButton.setText("X");
    ClearButton.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            ClearButtonMouseClicked(evt);
        }
    });
    Background.add(ClearButton, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 300, 50, -1));
    JohtoPlus.setBackground(new java.awt.Color(255, 0, 0));
    JohtoPlus.setText("+");
    JohtoPlus.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPlusMouseClicked(evt);
        }
    });
    Background.add(JohtoPlus, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 280, -1, -1));
    Background.setLayer(JohtoPlus, 2);
    JohtoMinus.setBackground(new java.awt.Color(255, 0, 0));
    JohtoMinus.setText("-");
    JohtoMinus.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoMinusMouseClicked(evt);
        }
    });
    Background.add(JohtoMinus, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 280, -1, -1));
    Background.setLayer(JohtoMinus, 2);
    JohtoDamageNumB5.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    JohtoDamageNumB5.setText("0");
    Background.add(JohtoDamageNumB5, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 90, 40, -1));
    JohtoDamageNum.setEditable(false);
    JohtoDamageNum.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    JohtoDamageNum.setText("0");
    Background.add(JohtoDamageNum, new org.netbeans.lib.awtextra.AbsoluteConstraints(290, 280, 40, -1));
    JohtoDamageNumB4.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    JohtoDamageNumB4.setText("0");
    Background.add(JohtoDamageNumB4, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 90, 40, -1));
    JohtoDamageNumB3.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    JohtoDamageNumB3.setText("0");
    Background.add(JohtoDamageNumB3, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 90, 40, -1));
    JohtoDamageNumB2.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    JohtoDamageNumB2.setText("0");
    Background.add(JohtoDamageNumB2, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 90, 40, -1));
    JohtoDamageNumB1.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    JohtoDamageNumB1.setText("0");
    Background.add(JohtoDamageNumB1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 90, 40, -1));
    KantoPlus.setBackground(new java.awt.Color(255, 255, 255));
    KantoPlus.setText("+");
    KantoPlus.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPlusMouseClicked(evt);
        }
    });
    Background.add(KantoPlus, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 480, -1, -1));
    Background.setLayer(KantoPlus, 2);
    KantoMinus.setBackground(new java.awt.Color(255, 255, 255));
    KantoMinus.setText("-");
    KantoMinus.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoMinusMouseClicked(evt);
        }
    });
    Background.add(KantoMinus, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 480, -1, -1));
    Background.setLayer(KantoMinus, 2);
    KantoDamageNum.setEditable(false);
    KantoDamageNum.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    KantoDamageNum.setText("0");
    Background.add(KantoDamageNum, new org.netbeans.lib.awtextra.AbsoluteConstraints(290, 480, 40, -1));
    KantoDamageNumB5.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    KantoDamageNumB5.setText("0");
    Background.add(KantoDamageNumB5, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 640, 40, -1));
    KantoDamageNumB4.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    KantoDamageNumB4.setText("0");
    Background.add(KantoDamageNumB4, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 640, 40, -1));
    KantoDamageNumB3.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    KantoDamageNumB3.setText("0");
    Background.add(KantoDamageNumB3, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 640, 40, -1));
    KantoDamageNumB2.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    KantoDamageNumB2.setText("0");
    Background.add(KantoDamageNumB2, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 640, 40, -1));
    KantoDamageNumB1.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    KantoDamageNumB1.setText("0");
    Background.add(KantoDamageNumB1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 640, 40, -1));
    Background.add(StadiumCard, new org.netbeans.lib.awtextra.AbsoluteConstraints(70, 230, 186, 260));
    // NOI18N
    JohtoCard.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
    JohtoCard.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoCardMouseClicked(evt);
        }
    });
    Background.add(JohtoCard, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 150, 134, 190));
    // NOI18N
    KantoCard.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
    KantoCard.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoCardMouseClicked(evt);
        }
    });
    Background.add(KantoCard, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 390, 134, 190));
    mid.setBackground(new java.awt.Color(0, 0, 0));
    // NOI18N
    mid.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/boackground2-1.png")));
    mid.setAlignmentY(0.0F);
    mid.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
    mid.setMaximumSize(new java.awt.Dimension(750, 469));
    mid.setMinimumSize(new java.awt.Dimension(750, 469));
    mid.setPreferredSize(new java.awt.Dimension(750, 469));
    Background.add(mid, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 150, 750, 430));
    mid.getAccessibleContext().setAccessibleName("mid");
    // NOI18N
    Kanto.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Kanto copy.png")));
    Kanto.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
    Background.add(Kanto, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 570, 750, 170));
    // NOI18N
    Johto.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Johto copy.png")));
    Johto.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
    Background.add(Johto, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 0, 750, 150));
    KantoActiveEnergy1.setBackground(java.awt.Color.lightGray);
    KantoActiveEnergy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoActiveEnergy1MouseClicked(evt);
        }
    });
    Background.add(KantoActiveEnergy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 440, -1, 20));
    Background.setLayer(KantoActiveEnergy1, 1);
    KantoActiveEnergy2.setBackground(java.awt.Color.lightGray);
    KantoActiveEnergy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoActiveEnergy2MouseClicked(evt);
        }
    });
    Background.add(KantoActiveEnergy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(360, 440, 30, 20));
    Background.setLayer(KantoActiveEnergy2, 2);
    KantoActiveEnergy3.setBackground(java.awt.Color.lightGray);
    KantoActiveEnergy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoActiveEnergy3MouseClicked(evt);
        }
    });
    Background.add(KantoActiveEnergy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 440, 30, 20));
    Background.setLayer(KantoActiveEnergy3, 3);
    KantoActiveEnergy4.setBackground(java.awt.Color.lightGray);
    KantoActiveEnergy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoActiveEnergy4MouseClicked(evt);
        }
    });
    Background.add(KantoActiveEnergy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(400, 440, 30, 20));
    Background.setLayer(KantoActiveEnergy4, 4);
    KantoBench5Energy4.setBackground(java.awt.Color.lightGray);
    KantoBench5Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench5Energy4MouseClicked(evt);
        }
    });
    Background.add(KantoBench5Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(700, 600, 30, 20));
    Background.setLayer(KantoBench5Energy4, 4);
    KantoBench5Energy3.setBackground(java.awt.Color.lightGray);
    KantoBench5Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench5Energy3MouseClicked(evt);
        }
    });
    Background.add(KantoBench5Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(680, 600, 30, 20));
    Background.setLayer(KantoBench5Energy3, 3);
    KantoBench5Energy2.setBackground(java.awt.Color.lightGray);
    KantoBench5Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench5Energy2MouseClicked(evt);
        }
    });
    Background.add(KantoBench5Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(660, 600, 30, 20));
    Background.setLayer(KantoBench5Energy2, 2);
    KantoBench5Energy1.setBackground(java.awt.Color.lightGray);
    KantoBench5Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench5Energy1MouseClicked(evt);
        }
    });
    Background.add(KantoBench5Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 600, -1, 20));
    Background.setLayer(KantoBench5Energy1, 1);
    KantoBench4Energy4.setBackground(java.awt.Color.lightGray);
    KantoBench4Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench4Energy4MouseClicked(evt);
        }
    });
    Background.add(KantoBench4Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 600, 30, 20));
    Background.setLayer(KantoBench4Energy4, 4);
    KantoBench4Energy3.setBackground(java.awt.Color.lightGray);
    KantoBench4Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench4Energy3MouseClicked(evt);
        }
    });
    Background.add(KantoBench4Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(530, 600, 30, 20));
    Background.setLayer(KantoBench4Energy3, 3);
    KantoBench4Energy2.setBackground(java.awt.Color.lightGray);
    KantoBench4Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench4Energy2MouseClicked(evt);
        }
    });
    Background.add(KantoBench4Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(510, 600, 30, 20));
    Background.setLayer(KantoBench4Energy2, 2);
    KantoBench4Energy1.setBackground(java.awt.Color.lightGray);
    KantoBench4Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench4Energy1MouseClicked(evt);
        }
    });
    Background.add(KantoBench4Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 600, -1, 20));
    Background.setLayer(KantoBench4Energy1, 1);
    KantoBench3Energy4.setBackground(java.awt.Color.lightGray);
    KantoBench3Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench3Energy4MouseClicked(evt);
        }
    });
    Background.add(KantoBench3Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 600, 30, 20));
    Background.setLayer(KantoBench3Energy4, 4);
    KantoBench3Energy3.setBackground(java.awt.Color.lightGray);
    KantoBench3Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench3Energy3MouseClicked(evt);
        }
    });
    Background.add(KantoBench3Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 600, 30, 20));
    Background.setLayer(KantoBench3Energy3, 3);
    KantoBench3Energy2.setBackground(java.awt.Color.lightGray);
    KantoBench3Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench3Energy2MouseClicked(evt);
        }
    });
    Background.add(KantoBench3Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(350, 600, 30, 20));
    Background.setLayer(KantoBench3Energy2, 2);
    KantoBench3Energy1.setBackground(java.awt.Color.lightGray);
    KantoBench3Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench3Energy1MouseClicked(evt);
        }
    });
    Background.add(KantoBench3Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 600, -1, 20));
    Background.setLayer(KantoBench3Energy1, 1);
    KantoBench2Energy4.setBackground(java.awt.Color.lightGray);
    KantoBench2Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench2Energy4MouseClicked(evt);
        }
    });
    Background.add(KantoBench2Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(230, 600, 30, 20));
    Background.setLayer(KantoBench2Energy4, 4);
    KantoBench2Energy3.setBackground(java.awt.Color.lightGray);
    KantoBench2Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench2Energy3MouseClicked(evt);
        }
    });
    Background.add(KantoBench2Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(210, 600, 30, 20));
    Background.setLayer(KantoBench2Energy3, 3);
    KantoBench2Energy2.setBackground(java.awt.Color.lightGray);
    KantoBench2Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench2Energy2MouseClicked(evt);
        }
    });
    Background.add(KantoBench2Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(190, 600, 30, 20));
    Background.setLayer(KantoBench2Energy2, 2);
    KantoBench2Energy1.setBackground(java.awt.Color.lightGray);
    KantoBench2Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench2Energy1MouseClicked(evt);
        }
    });
    Background.add(KantoBench2Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 600, -1, 20));
    Background.setLayer(KantoBench2Energy1, 1);
    KantoBench1Energy4.setBackground(java.awt.Color.lightGray);
    KantoBench1Energy4.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench1Energy4MouseClicked(evt);
        }
    });
    Background.add(KantoBench1Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(70, 600, 30, 20));
    Background.setLayer(KantoBench1Energy4, 4);
    KantoBench1Energy3.setBackground(java.awt.Color.lightGray);
    KantoBench1Energy3.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench1Energy3MouseClicked(evt);
        }
    });
    Background.add(KantoBench1Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(50, 600, 30, 20));
    Background.setLayer(KantoBench1Energy3, 3);
    KantoBench1Energy2.setBackground(java.awt.Color.lightGray);
    KantoBench1Energy2.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench1Energy2MouseClicked(evt);
        }
    });
    Background.add(KantoBench1Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(30, 600, 30, 20));
    Background.setLayer(KantoBench1Energy2, 2);
    KantoBench1Energy1.setBackground(java.awt.Color.lightGray);
    KantoBench1Energy1.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench1Energy1MouseClicked(evt);
        }
    });
    Background.add(KantoBench1Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 600, -1, 20));
    Background.setLayer(KantoBench1Energy1, 1);
    JohtoPZ.setBackground(java.awt.Color.lightGray);
    JohtoPZ.setText("PZ");
    JohtoPZ.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPZMouseClicked(evt);
        }
    });
    Background.add(JohtoPZ, new org.netbeans.lib.awtextra.AbsoluteConstraints(480, 160, -1, -1));
    Background.setLayer(JohtoPZ, 2);
    JohtoSL.setBackground(java.awt.Color.lightGray);
    JohtoSL.setText("SL");
    JohtoSL.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoSLMouseClicked(evt);
        }
    });
    Background.add(JohtoSL, new org.netbeans.lib.awtextra.AbsoluteConstraints(430, 160, -1, -1));
    Background.setLayer(JohtoSL, 2);
    JohtoPO.setBackground(java.awt.Color.lightGray);
    JohtoPO.setText("PO");
    JohtoPO.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoPOMouseClicked(evt);
        }
    });
    Background.add(JohtoPO, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 160, -1, -1));
    Background.setLayer(JohtoPO, 2);
    JohtoBR.setBackground(java.awt.Color.lightGray);
    JohtoBR.setText("BR");
    JohtoBR.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBRMouseClicked(evt);
        }
    });
    Background.add(JohtoBR, new org.netbeans.lib.awtextra.AbsoluteConstraints(310, 160, -1, -1));
    Background.setLayer(JohtoBR, 2);
    JohtoCN.setBackground(java.awt.Color.lightGray);
    JohtoCN.setText("CN");
    JohtoCN.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoCNMouseClicked(evt);
        }
    });
    Background.add(JohtoCN, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 160, -1, -1));
    Background.setLayer(JohtoCN, 2);
    KantoCN.setBackground(java.awt.Color.lightGray);
    KantoCN.setText("CN");
    KantoCN.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoCNMouseClicked(evt);
        }
    });
    Background.add(KantoCN, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 540, -1, -1));
    Background.setLayer(KantoCN, 2);
    KantoBR.setBackground(java.awt.Color.lightGray);
    KantoBR.setText("BR");
    KantoBR.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBRMouseClicked(evt);
        }
    });
    Background.add(KantoBR, new org.netbeans.lib.awtextra.AbsoluteConstraints(310, 540, -1, -1));
    Background.setLayer(KantoBR, 2);
    KantoPO.setBackground(java.awt.Color.lightGray);
    KantoPO.setText("PO");
    KantoPO.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPOMouseClicked(evt);
        }
    });
    Background.add(KantoPO, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 540, -1, -1));
    Background.setLayer(KantoPO, 2);
    KantoSL.setBackground(java.awt.Color.lightGray);
    KantoSL.setText("SL");
    KantoSL.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoSLMouseClicked(evt);
        }
    });
    Background.add(KantoSL, new org.netbeans.lib.awtextra.AbsoluteConstraints(430, 540, -1, -1));
    Background.setLayer(KantoSL, 2);
    KantoPZ.setBackground(java.awt.Color.lightGray);
    KantoPZ.setText("PZ");
    KantoPZ.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoPZMouseClicked(evt);
        }
    });
    Background.add(KantoPZ, new org.netbeans.lib.awtextra.AbsoluteConstraints(480, 540, -1, -1));
    Background.setLayer(KantoPZ, 2);
    KantoBench5Switch.setBackground(new java.awt.Color(255, 255, 255));
    // NOI18N
    KantoBench5Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    KantoBench5Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    KantoBench5Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench5SwitchMouseClicked(evt);
        }
    });
    Background.add(KantoBench5Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(690, 640, 40, 30));
    Background.setLayer(KantoBench5Switch, 2);
    KantoBench4Switch.setBackground(new java.awt.Color(255, 255, 255));
    // NOI18N
    KantoBench4Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    KantoBench4Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    KantoBench4Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench4SwitchMouseClicked(evt);
        }
    });
    Background.add(KantoBench4Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(540, 640, 40, 30));
    Background.setLayer(KantoBench4Switch, 2);
    KantoBench3Switch.setBackground(new java.awt.Color(255, 255, 255));
    // NOI18N
    KantoBench3Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    KantoBench3Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    KantoBench3Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench3SwitchMouseClicked(evt);
        }
    });
    Background.add(KantoBench3Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 640, 40, 30));
    Background.setLayer(KantoBench3Switch, 2);
    KantoBench2Switch.setBackground(new java.awt.Color(255, 255, 255));
    // NOI18N
    KantoBench2Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    KantoBench2Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    KantoBench2Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench2SwitchMouseClicked(evt);
        }
    });
    Background.add(KantoBench2Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(220, 640, 40, 30));
    Background.setLayer(KantoBench2Switch, 2);
    KantoBench1Switch.setBackground(new java.awt.Color(255, 255, 255));
    // NOI18N
    KantoBench1Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    KantoBench1Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    KantoBench1Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoBench1SwitchMouseClicked(evt);
        }
    });
    Background.add(KantoBench1Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(60, 640, 40, 30));
    Background.setLayer(KantoBench1Switch, 2);
    JohtoBench5Switch.setBackground(new java.awt.Color(255, 0, 0));
    // NOI18N
    JohtoBench5Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    JohtoBench5Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    JohtoBench5Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench5SwitchMouseClicked(evt);
        }
    });
    Background.add(JohtoBench5Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(690, 90, 40, 30));
    Background.setLayer(JohtoBench5Switch, 2);
    JohtoBench4Switch.setBackground(new java.awt.Color(255, 0, 0));
    // NOI18N
    JohtoBench4Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    JohtoBench4Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    JohtoBench4Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench4SwitchMouseClicked(evt);
        }
    });
    Background.add(JohtoBench4Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(540, 90, 40, 30));
    Background.setLayer(JohtoBench4Switch, 2);
    JohtoBench3Switch.setBackground(new java.awt.Color(255, 0, 0));
    // NOI18N
    JohtoBench3Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    JohtoBench3Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    JohtoBench3Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench3SwitchMouseClicked(evt);
        }
    });
    Background.add(JohtoBench3Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 90, 40, 30));
    Background.setLayer(JohtoBench3Switch, 2);
    JohtoBench2Switch.setBackground(new java.awt.Color(255, 0, 0));
    // NOI18N
    JohtoBench2Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    JohtoBench2Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    JohtoBench2Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench2SwitchMouseClicked(evt);
        }
    });
    Background.add(JohtoBench2Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(220, 90, 40, 30));
    Background.setLayer(JohtoBench2Switch, 2);
    JohtoBench1Switch.setBackground(new java.awt.Color(255, 0, 0));
    // NOI18N
    JohtoBench1Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
    JohtoBench1Switch.setPreferredSize(new java.awt.Dimension(33, 10));
    JohtoBench1Switch.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoBench1SwitchMouseClicked(evt);
        }
    });
    Background.add(JohtoBench1Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(60, 90, 40, 30));
    Background.setLayer(JohtoBench1Switch, 2);
    KantoClear.setBackground(new java.awt.Color(255, 255, 255));
    // NOI18N
    KantoClear.setFont(new java.awt.Font("Tahoma", Font.PLAIN, 12));
    KantoClear.setForeground(new java.awt.Color(255, 0, 0));
    KantoClear.setText("X");
    KantoClear.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            KantoClearMouseClicked(evt);
        }
    });
    Background.add(KantoClear, new org.netbeans.lib.awtextra.AbsoluteConstraints(440, 480, -1, -1));
    Background.setLayer(KantoClear, 2);
    JohtoClear.setBackground(new java.awt.Color(255, 0, 0));
    // NOI18N
    JohtoClear.setFont(new java.awt.Font("Tahoma", Font.PLAIN, 12));
    JohtoClear.setText("X");
    JohtoClear.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseClicked(java.awt.event.MouseEvent evt) {
            JohtoClearMouseClicked(evt);
        }
    });
    Background.add(JohtoClear, new org.netbeans.lib.awtextra.AbsoluteConstraints(440, 280, -1, -1));
    Background.setLayer(JohtoClear, 2);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(Background, javax.swing.GroupLayout.PREFERRED_SIZE, 750, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(Background, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 10, Short.MAX_VALUE)));
    pack();
}
Example 73
Project: cismap-commons-master  File: LinearReferencingDialog.java View source code
/**
     * This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The
     * content of this method is always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    java.awt.GridBagConstraints gridBagConstraints;
    lblTitle = new javax.swing.JLabel();
    cbKind = new javax.swing.JComboBox();
    cbRoute = new javax.swing.JComboBox();
    cbFrom = new javax.swing.JComboBox();
    cbTill = new javax.swing.JComboBox();
    lblKind = new javax.swing.JLabel();
    lblFrom = new javax.swing.JLabel();
    lblTill = new javax.swing.JLabel();
    lblRoute = new javax.swing.JLabel();
    butApply = new javax.swing.JButton();
    butCancel = new javax.swing.JButton();
    lblRouteField = new javax.swing.JLabel();
    cbRouteField = new javax.swing.JComboBox();
    lblRouteTargetField = new javax.swing.JLabel();
    cbRouteTargetField = new javax.swing.JComboBox();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.title", // NOI18N
    new Object[] {}));
    getContentPane().setLayout(new java.awt.GridBagLayout());
    // NOI18N
    lblTitle.setFont(new java.awt.Font("Ubuntu", 1, 18));
    lblTitle.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblTitle.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.gridwidth = 4;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 0);
    getContentPane().add(lblTitle, gridBagConstraints);
    cbKind.setMinimumSize(new java.awt.Dimension(80, 27));
    cbKind.setPreferredSize(new java.awt.Dimension(180, 27));
    cbKind.addItemListener(new java.awt.event.ItemListener() {

        @Override
        public void itemStateChanged(final java.awt.event.ItemEvent evt) {
            cbKindItemStateChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(cbKind, gridBagConstraints);
    cbRoute.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbRoute.setMinimumSize(new java.awt.Dimension(80, 27));
    cbRoute.setPreferredSize(new java.awt.Dimension(180, 27));
    cbRoute.addItemListener(new java.awt.event.ItemListener() {

        @Override
        public void itemStateChanged(final java.awt.event.ItemEvent evt) {
            cbRouteItemStateChanged(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(cbRoute, gridBagConstraints);
    cbFrom.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbFrom.setMinimumSize(new java.awt.Dimension(80, 27));
    cbFrom.setPreferredSize(new java.awt.Dimension(180, 27));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(cbFrom, gridBagConstraints);
    cbTill.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbTill.setMinimumSize(new java.awt.Dimension(80, 27));
    cbTill.setPreferredSize(new java.awt.Dimension(180, 27));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(cbTill, gridBagConstraints);
    // NOI18N
    lblKind.setFont(new java.awt.Font("Ubuntu", 1, 15));
    lblKind.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblKind.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(lblKind, gridBagConstraints);
    // NOI18N
    lblFrom.setFont(new java.awt.Font("Ubuntu", 1, 15));
    lblFrom.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblFrom.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(lblFrom, gridBagConstraints);
    // NOI18N
    lblTill.setFont(new java.awt.Font("Ubuntu", 1, 15));
    lblTill.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblTill.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(lblTill, gridBagConstraints);
    // NOI18N
    lblRoute.setFont(new java.awt.Font("Ubuntu", 1, 15));
    lblRoute.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblRoute.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(lblRoute, gridBagConstraints);
    butApply.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.butApply.text", // NOI18N
    new Object[] {}));
    butApply.addActionListener(new java.awt.event.ActionListener() {

        @Override
        public void actionPerformed(final java.awt.event.ActionEvent evt) {
            butApplyActionPerformed(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 7;
    gridBagConstraints.gridwidth = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.SOUTHWEST;
    gridBagConstraints.weighty = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(10, 10, 10, 10);
    getContentPane().add(butApply, gridBagConstraints);
    butCancel.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.butCancel.text", // NOI18N
    new Object[] {}));
    butCancel.addActionListener(new java.awt.event.ActionListener() {

        @Override
        public void actionPerformed(final java.awt.event.ActionEvent evt) {
            butCancelActionPerformed(evt);
        }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 7;
    gridBagConstraints.gridwidth = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.SOUTHEAST;
    gridBagConstraints.weighty = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(10, 10, 10, 10);
    getContentPane().add(butCancel, gridBagConstraints);
    // NOI18N
    lblRouteField.setFont(new java.awt.Font("Ubuntu", 1, 15));
    lblRouteField.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblRouteField.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(lblRouteField, gridBagConstraints);
    cbRouteField.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbRouteField.setMinimumSize(new java.awt.Dimension(80, 27));
    cbRouteField.setPreferredSize(new java.awt.Dimension(210, 27));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(cbRouteField, gridBagConstraints);
    // NOI18N
    lblRouteTargetField.setFont(new java.awt.Font("Ubuntu", 1, 15));
    lblRouteTargetField.setText(org.openide.util.NbBundle.getMessage(LinearReferencingDialog.class, "LinearReferencingDialog.lblRouteTargetField.text", // NOI18N
    new Object[] {}));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(lblRouteTargetField, gridBagConstraints);
    cbRouteTargetField.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    cbRouteTargetField.setMinimumSize(new java.awt.Dimension(80, 27));
    cbRouteTargetField.setPreferredSize(new java.awt.Dimension(180, 27));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.insets = new java.awt.Insets(15, 10, 10, 5);
    getContentPane().add(cbRouteTargetField, gridBagConstraints);
    pack();
}
Example 74
Project: compomics-utilities-master  File: MsAmandaSettingsDialog.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    backgroundPanel = new javax.swing.JPanel();
    advancedSearchSettingsPanel = new javax.swing.JPanel();
    instrumentCmb = new javax.swing.JComboBox();
    decoyDatabaseCmb = new javax.swing.JComboBox();
    decoyDatabaseLabel = new javax.swing.JLabel();
    instrumentLabel = new javax.swing.JLabel();
    maxRankLabel = new javax.swing.JLabel();
    maxRankTxt = new javax.swing.JTextField();
    monoIsotopicLabel = new javax.swing.JLabel();
    monoIsotopicCmb = new javax.swing.JComboBox();
    lowMemoryModeLabel = new javax.swing.JLabel();
    lowMemoryModeCmb = new javax.swing.JComboBox();
    okButton = new javax.swing.JButton();
    closeButton = new javax.swing.JButton();
    openDialogHelpJButton = new javax.swing.JButton();
    advancedSettingsWarningLabel = new javax.swing.JLabel();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle("MS Amanda Advanced Settings");
    setResizable(false);
    backgroundPanel.setBackground(new java.awt.Color(230, 230, 230));
    advancedSearchSettingsPanel.setBorder(javax.swing.BorderFactory.createTitledBorder("Search Settings"));
    advancedSearchSettingsPanel.setOpaque(false);
    instrumentCmb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "b, y", "b, y, -H2O, -NH3", "a, b, y, -H2O, -NH3, Imm", "a, b, y, -H2O, -NH3", "a, b, y", "a, b, y, Imm", "a, b, y, z, -H2O, -NH3, Imm", "c, y, z+1, z+2", "b, c, y, z+1, z+2", "b, y, INT", "b, y, INT, Imm", "a, b, y, INT", "a, b, y, INT, IMM", "a, b, y, INT, IMM, -H2O", "a, b, y, INT, IMM, -H2O, -NH3", "a, b, y, INT, IMM, -NH3" }));
    decoyDatabaseCmb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Yes", "No" }));
    decoyDatabaseCmb.setSelectedIndex(1);
    decoyDatabaseLabel.setText("Generate Decoy Database");
    instrumentLabel.setText("Fragment Ion Types");
    maxRankLabel.setText("Max Rank");
    maxRankTxt.setHorizontalAlignment(javax.swing.JTextField.CENTER);
    maxRankTxt.setText("1");
    maxRankTxt.addKeyListener(new java.awt.event.KeyAdapter() {

        public void keyReleased(java.awt.event.KeyEvent evt) {
            maxRankTxtKeyReleased(evt);
        }
    });
    monoIsotopicLabel.setText("Monoisotopic");
    monoIsotopicCmb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Yes", "No" }));
    lowMemoryModeLabel.setText("Low Memory Mode");
    lowMemoryModeCmb.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Yes", "No" }));
    javax.swing.GroupLayout advancedSearchSettingsPanelLayout = new javax.swing.GroupLayout(advancedSearchSettingsPanel);
    advancedSearchSettingsPanel.setLayout(advancedSearchSettingsPanelLayout);
    advancedSearchSettingsPanelLayout.setHorizontalGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(advancedSearchSettingsPanelLayout.createSequentialGroup().addContainerGap().addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(advancedSearchSettingsPanelLayout.createSequentialGroup().addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(instrumentLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(decoyDatabaseLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(instrumentCmb, 0, 189, Short.MAX_VALUE).addComponent(decoyDatabaseCmb, javax.swing.GroupLayout.Alignment.TRAILING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))).addGroup(advancedSearchSettingsPanelLayout.createSequentialGroup().addComponent(maxRankLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(maxRankTxt)).addGroup(advancedSearchSettingsPanelLayout.createSequentialGroup().addComponent(monoIsotopicLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(monoIsotopicCmb, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addGroup(advancedSearchSettingsPanelLayout.createSequentialGroup().addComponent(lowMemoryModeLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(lowMemoryModeCmb, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))).addContainerGap()));
    advancedSearchSettingsPanelLayout.setVerticalGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(advancedSearchSettingsPanelLayout.createSequentialGroup().addContainerGap().addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(decoyDatabaseLabel).addComponent(decoyDatabaseCmb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(instrumentCmb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(instrumentLabel)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(monoIsotopicLabel).addComponent(monoIsotopicCmb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(maxRankLabel).addComponent(maxRankTxt, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(advancedSearchSettingsPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(lowMemoryModeLabel).addComponent(lowMemoryModeCmb, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    okButton.setText("OK");
    okButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            okButtonActionPerformed(evt);
        }
    });
    closeButton.setText("Close");
    closeButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            closeButtonActionPerformed(evt);
        }
    });
    // NOI18N
    openDialogHelpJButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/icons/help.GIF")));
    openDialogHelpJButton.setToolTipText("Help");
    openDialogHelpJButton.setBorder(null);
    openDialogHelpJButton.setBorderPainted(false);
    openDialogHelpJButton.setContentAreaFilled(false);
    openDialogHelpJButton.addMouseListener(new java.awt.event.MouseAdapter() {

        public void mouseEntered(java.awt.event.MouseEvent evt) {
            openDialogHelpJButtonMouseEntered(evt);
        }

        public void mouseExited(java.awt.event.MouseEvent evt) {
            openDialogHelpJButtonMouseExited(evt);
        }
    });
    openDialogHelpJButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            openDialogHelpJButtonActionPerformed(evt);
        }
    });
    advancedSettingsWarningLabel.setText("Click to open the MS Amanda help page.");
    javax.swing.GroupLayout backgroundPanelLayout = new javax.swing.GroupLayout(backgroundPanel);
    backgroundPanel.setLayout(backgroundPanelLayout);
    backgroundPanelLayout.setHorizontalGroup(backgroundPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, backgroundPanelLayout.createSequentialGroup().addContainerGap().addGroup(backgroundPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(advancedSearchSettingsPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addGroup(backgroundPanelLayout.createSequentialGroup().addGap(10, 10, 10).addComponent(openDialogHelpJButton).addGap(18, 18, 18).addComponent(advancedSettingsWarningLabel).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(okButton, javax.swing.GroupLayout.PREFERRED_SIZE, 59, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(closeButton))).addContainerGap()));
    backgroundPanelLayout.setVerticalGroup(backgroundPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(backgroundPanelLayout.createSequentialGroup().addContainerGap().addComponent(advancedSearchSettingsPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(backgroundPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER).addComponent(openDialogHelpJButton).addComponent(advancedSettingsWarningLabel).addComponent(okButton).addComponent(closeButton)).addContainerGap()));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(backgroundPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(backgroundPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE));
    pack();
}
Example 75
Project: Sane-Java-Tablet-master  File: AreaMappingConfig.java View source code
private void initComponents() {
    configPanelsContainer = new javax.swing.JTabbedPane();
    configRegionsTab = new javax.swing.JPanel();
    tabletPortionContainer = new javax.swing.JPanel();
    tabletSelector = new javax.swing.JComboBox();
    tabletVisualization1 = new javax.swing.JPanel();
    configSetContainer = new javax.swing.JPanel();
    deleteSetButton = new javax.swing.JButton();
    duplicateSetButton = new javax.swing.JButton();
    saveSetButton = new javax.swing.JButton();
    setSelector = new javax.swing.JComboBox();
    mappingsContainer = new javax.swing.JScrollPane();
    mappingsList = new javax.swing.JList();
    saveMappingButton = new javax.swing.JButton();
    destinationPortionContainer = new javax.swing.JPanel();
    dstTabContainer = new javax.swing.JTabbedPane();
    dstTabDisplayContainer = new javax.swing.JPanel();
    displaysVisualization = new javax.swing.JPanel();
    xMinInput = new javax.swing.JSpinner();
    xMaxInput = new javax.swing.JSpinner();
    yMinInput = new javax.swing.JSpinner();
    yMaxInput = new javax.swing.JSpinner();
    dstTabAreaContainer = new javax.swing.JPanel();
    dstAreaInfo = new javax.swing.JLabel();
    dstAreaSelector = new javax.swing.JComboBox();
    configButtonsTab = new javax.swing.JPanel();
    jLabel1 = new javax.swing.JLabel();
    jComboBox2 = new javax.swing.JComboBox();
    jPanel5 = new javax.swing.JPanel();
    jLabel2 = new javax.swing.JLabel();
    configSetContainer1 = new javax.swing.JPanel();
    deleteSetButton1 = new javax.swing.JButton();
    duplicateSetButton1 = new javax.swing.JButton();
    saveSetButton1 = new javax.swing.JButton();
    setSelector1 = new javax.swing.JComboBox();
    saveMappingButton1 = new javax.swing.JButton();
    jPanel6 = new javax.swing.JPanel();
    jPanel7 = new javax.swing.JPanel();
    jComboBox3 = new javax.swing.JComboBox();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    configPanelsContainer.setTabPlacement(javax.swing.JTabbedPane.LEFT);
    tabletPortionContainer.setBorder(javax.swing.BorderFactory.createTitledBorder("Map from tablet region"));
    tabletSelector.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "#01 AIRtek tablet", "#02 Wacom tablet", "#03 Generic tablet" }));
    tabletVisualization1.setBorder(javax.swing.BorderFactory.createLineBorder(javax.swing.UIManager.getDefaults().getColor("Button.light")));
    javax.swing.GroupLayout tabletVisualization1Layout = new javax.swing.GroupLayout(tabletVisualization1);
    tabletVisualization1.setLayout(tabletVisualization1Layout);
    tabletVisualization1Layout.setHorizontalGroup(tabletVisualization1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 464, Short.MAX_VALUE));
    tabletVisualization1Layout.setVerticalGroup(tabletVisualization1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 208, Short.MAX_VALUE));
    javax.swing.GroupLayout tabletPortionContainer1Layout = new javax.swing.GroupLayout(tabletPortionContainer);
    tabletPortionContainer.setLayout(tabletPortionContainer1Layout);
    tabletPortionContainer1Layout.setHorizontalGroup(tabletPortionContainer1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(tabletSelector, 0, 466, Short.MAX_VALUE).addComponent(tabletVisualization1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE));
    tabletPortionContainer1Layout.setVerticalGroup(tabletPortionContainer1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(tabletPortionContainer1Layout.createSequentialGroup().addComponent(tabletSelector, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(tabletVisualization1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    configSetContainer.setBorder(javax.swing.BorderFactory.createTitledBorder("Mapping set"));
    deleteSetButton.setText("Delete set");
    duplicateSetButton.setText("Duplicate set");
    saveSetButton.setText("Save set");
    setSelector.setEditable(true);
    setSelector.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "01. Mega-configuration", "02. Precision (work)", "03. Test set" }));
    mappingsList.setModel(new javax.swing.AbstractListModel() {

        private static final long serialVersionUID = 1L;

        String[] strings = { "01. \"one\" to display", "02. \"four\" to specific area", "03. \"three\" to specific area", "04. \"two\" to specific area" };

        public int getSize() {
            return strings.length;
        }

        public Object getElementAt(int i) {
            return strings[i];
        }
    });
    mappingsContainer.setViewportView(mappingsList);
    saveMappingButton.setText("Save current mapping");
    javax.swing.GroupLayout configSetContainerLayout = new javax.swing.GroupLayout(configSetContainer);
    configSetContainer.setLayout(configSetContainerLayout);
    configSetContainerLayout.setHorizontalGroup(configSetContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(deleteSetButton, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(duplicateSetButton, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(saveSetButton, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(setSelector, 0, 212, Short.MAX_VALUE).addComponent(mappingsContainer, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(saveMappingButton, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE));
    configSetContainerLayout.setVerticalGroup(configSetContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(configSetContainerLayout.createSequentialGroup().addComponent(deleteSetButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(duplicateSetButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(saveSetButton).addGap(4, 4, 4).addComponent(setSelector, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(mappingsContainer, javax.swing.GroupLayout.DEFAULT_SIZE, 473, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(saveMappingButton)));
    destinationPortionContainer.setBorder(javax.swing.BorderFactory.createTitledBorder("Map to"));
    displaysVisualization.setBorder(new javax.swing.border.LineBorder(javax.swing.UIManager.getDefaults().getColor("Button.light"), 1, true));
    javax.swing.GroupLayout displaysVisualizationLayout = new javax.swing.GroupLayout(displaysVisualization);
    displaysVisualization.setLayout(displaysVisualizationLayout);
    displaysVisualizationLayout.setHorizontalGroup(displaysVisualizationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 393, Short.MAX_VALUE));
    displaysVisualizationLayout.setVerticalGroup(displaysVisualizationLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 288, Short.MAX_VALUE));
    javax.swing.GroupLayout dstTabDisplayContainerLayout = new javax.swing.GroupLayout(dstTabDisplayContainer);
    dstTabDisplayContainer.setLayout(dstTabDisplayContainerLayout);
    dstTabDisplayContainerLayout.setHorizontalGroup(dstTabDisplayContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, dstTabDisplayContainerLayout.createSequentialGroup().addGroup(dstTabDisplayContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(dstTabDisplayContainerLayout.createSequentialGroup().addComponent(xMinInput, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 295, Short.MAX_VALUE).addComponent(xMaxInput, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(displaysVisualization, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(dstTabDisplayContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(yMinInput, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(yMaxInput, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap()));
    dstTabDisplayContainerLayout.setVerticalGroup(dstTabDisplayContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(dstTabDisplayContainerLayout.createSequentialGroup().addGroup(dstTabDisplayContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(xMinInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(xMaxInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(dstTabDisplayContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(dstTabDisplayContainerLayout.createSequentialGroup().addComponent(yMinInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 250, Short.MAX_VALUE).addComponent(yMaxInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(displaysVisualization, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))));
    dstTabContainer.addTab("Display", dstTabDisplayContainer);
    dstAreaInfo.setText("Select an application-specified area to which the mapping will be done to.");
    dstAreaSelector.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Tools palette", "Zoomed in window", "Application main window" }));
    javax.swing.GroupLayout dstTabAreaContainerLayout = new javax.swing.GroupLayout(dstTabAreaContainer);
    dstTabAreaContainer.setLayout(dstTabAreaContainerLayout);
    dstTabAreaContainerLayout.setHorizontalGroup(dstTabAreaContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(dstTabAreaContainerLayout.createSequentialGroup().addContainerGap().addGroup(dstTabAreaContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(dstAreaSelector, 0, 441, Short.MAX_VALUE).addComponent(dstAreaInfo)).addContainerGap()));
    dstTabAreaContainerLayout.setVerticalGroup(dstTabAreaContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(dstTabAreaContainerLayout.createSequentialGroup().addContainerGap().addComponent(dstAreaInfo).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(dstAreaSelector, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(265, Short.MAX_VALUE)));
    dstTabContainer.addTab("Specific area", dstTabAreaContainer);
    javax.swing.GroupLayout destinationPortionContainerLayout = new javax.swing.GroupLayout(destinationPortionContainer);
    destinationPortionContainer.setLayout(destinationPortionContainerLayout);
    destinationPortionContainerLayout.setHorizontalGroup(destinationPortionContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(dstTabContainer, javax.swing.GroupLayout.DEFAULT_SIZE, 466, Short.MAX_VALUE));
    destinationPortionContainerLayout.setVerticalGroup(destinationPortionContainerLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(dstTabContainer, javax.swing.GroupLayout.DEFAULT_SIZE, 344, Short.MAX_VALUE));
    javax.swing.GroupLayout configRegionsTabLayout = new javax.swing.GroupLayout(configRegionsTab);
    configRegionsTab.setLayout(configRegionsTabLayout);
    configRegionsTabLayout.setHorizontalGroup(configRegionsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, configRegionsTabLayout.createSequentialGroup().addGroup(configRegionsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(destinationPortionContainer, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(tabletPortionContainer, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(configSetContainer, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)));
    configRegionsTabLayout.setVerticalGroup(configRegionsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, configRegionsTabLayout.createSequentialGroup().addComponent(tabletPortionContainer, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(destinationPortionContainer, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addComponent(configSetContainer, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE));
    configPanelsContainer.addTab("Regions", configRegionsTab);
    jLabel1.setText("Select the tablet whose buttons mappings are to be configured.");
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "#01 AIRtek tablet", "#02 Wacom tablet", "#03 Generic tablet" }));
    jPanel5.setBorder(javax.swing.BorderFactory.createTitledBorder("Test buttons here"));
    jLabel2.setFont(jLabel2.getFont().deriveFont(jLabel2.getFont().getSize() + 20f));
    jLabel2.setText("1, 5, 0");
    javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
    jPanel5.setLayout(jPanel5Layout);
    jPanel5Layout.setHorizontalGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel5Layout.createSequentialGroup().addContainerGap().addComponent(jLabel2, javax.swing.GroupLayout.DEFAULT_SIZE, 436, Short.MAX_VALUE).addContainerGap()));
    jPanel5Layout.setVerticalGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel5Layout.createSequentialGroup().addComponent(jLabel2, javax.swing.GroupLayout.DEFAULT_SIZE, 78, Short.MAX_VALUE).addContainerGap()));
    configSetContainer1.setBorder(javax.swing.BorderFactory.createTitledBorder("Button set"));
    deleteSetButton1.setText("Delete set");
    duplicateSetButton1.setText("Duplicate set");
    saveSetButton1.setText("Save set");
    setSelector1.setEditable(true);
    setSelector1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "01. Normal buttons", "02. Weird buttons", "03. Test button set" }));
    saveMappingButton1.setText("Save button mappings");
    javax.swing.GroupLayout configSetContainer1Layout = new javax.swing.GroupLayout(configSetContainer1);
    configSetContainer1.setLayout(configSetContainer1Layout);
    configSetContainer1Layout.setHorizontalGroup(configSetContainer1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(deleteSetButton1, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(duplicateSetButton1, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(saveSetButton1, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE).addComponent(setSelector1, 0, 212, Short.MAX_VALUE).addComponent(saveMappingButton1, javax.swing.GroupLayout.DEFAULT_SIZE, 212, Short.MAX_VALUE));
    configSetContainer1Layout.setVerticalGroup(configSetContainer1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(configSetContainer1Layout.createSequentialGroup().addComponent(deleteSetButton1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(duplicateSetButton1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(saveSetButton1).addGap(4, 4, 4).addComponent(setSelector1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(18, 18, 18).addComponent(saveMappingButton1)));
    jPanel6.setLayout(new javax.swing.BoxLayout(jPanel6, javax.swing.BoxLayout.LINE_AXIS));
    jPanel7.setBorder(javax.swing.BorderFactory.createTitledBorder("Configure button #0 as"));
    jComboBox3.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);
    jPanel7.setLayout(jPanel7Layout);
    jPanel7Layout.setHorizontalGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel7Layout.createSequentialGroup().addContainerGap().addComponent(jComboBox3, 0, 656, Short.MAX_VALUE).addContainerGap()));
    jPanel7Layout.setVerticalGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel7Layout.createSequentialGroup().addComponent(jComboBox3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(403, Short.MAX_VALUE)));
    jPanel6.add(jPanel7);
    javax.swing.GroupLayout configButtonsTabLayout = new javax.swing.GroupLayout(configButtonsTab);
    configButtonsTab.setLayout(configButtonsTabLayout);
    configButtonsTabLayout.setHorizontalGroup(configButtonsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(configButtonsTabLayout.createSequentialGroup().addGroup(configButtonsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(configButtonsTabLayout.createSequentialGroup().addContainerGap().addComponent(jPanel5, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addGroup(configButtonsTabLayout.createSequentialGroup().addContainerGap().addComponent(jLabel1)).addGroup(configButtonsTabLayout.createSequentialGroup().addContainerGap().addComponent(jComboBox2, 0, 468, Short.MAX_VALUE))).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(configSetContainer1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(configButtonsTabLayout.createSequentialGroup().addContainerGap().addComponent(jPanel6, javax.swing.GroupLayout.DEFAULT_SIZE, 688, Short.MAX_VALUE).addContainerGap()));
    configButtonsTabLayout.setVerticalGroup(configButtonsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(configButtonsTabLayout.createSequentialGroup().addGroup(configButtonsTabLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addGroup(configButtonsTabLayout.createSequentialGroup().addContainerGap().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jComboBox2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jPanel5, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addComponent(configSetContainer1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jPanel6, javax.swing.GroupLayout.DEFAULT_SIZE, 450, Short.MAX_VALUE).addContainerGap()));
    configPanelsContainer.addTab("Buttons", configButtonsTab);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(configPanelsContainer, javax.swing.GroupLayout.DEFAULT_SIZE, 767, Short.MAX_VALUE));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(configPanelsContainer, javax.swing.GroupLayout.DEFAULT_SIZE, 645, Short.MAX_VALUE));
    pack();
}
Example 76
Project: CaliphEmir-master  File: MdsConfiguration.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc=" Generated Code ">//GEN-BEGIN:initComponents
private void initComponents() {
    fdpGroupLabel = new javax.swing.JLabel();
    gravityLabel = new javax.swing.JLabel();
    minDistanceLabel = new javax.swing.JLabel();
    dLabel = new javax.swing.JLabel();
    wLabel = new javax.swing.JLabel();
    rLabel = new javax.swing.JLabel();
    gravity = new javax.swing.JTextField();
    minDistance = new javax.swing.JTextField();
    w = new javax.swing.JTextField();
    d = new javax.swing.JTextField();
    r = new javax.swing.JTextField();
    mdsgroupLabel = new javax.swing.JLabel();
    stepAwaitLabel = new javax.swing.JLabel();
    startWaitLabel = new javax.swing.JLabel();
    stopConditionLabel = new javax.swing.JLabel();
    stepWait = new javax.swing.JTextField();
    startWait = new javax.swing.JTextField();
    stopCondition = new javax.swing.JTextField();
    clusteringAlgorithmLabel = new javax.swing.JLabel();
    jLabel1 = new javax.swing.JLabel();
    clusteringMetric = new javax.swing.JComboBox();
    clusteringAlgorithm = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    fdpMetric = new javax.swing.JComboBox();
    frameTitle = new at.lux.fotoannotation.panels.components.FrameTitle();
    fdpGroupLabel.setFont(new java.awt.Font("Tahoma", 1, 11));
    fdpGroupLabel.setText("FDP Algorithmic parameters:");
    gravityLabel.setText("Gravity:");
    minDistanceLabel.setText("Min. distance:");
    dLabel.setText("Separation:");
    wLabel.setText("Attraction:");
    rLabel.setText("Repulsion:");
    gravity.setToolTipText("Constant gravitation of points, should be related somehow with the number of points, the more points the smaller the gravitation.");
    minDistance.setToolTipText("Defines what is the minimum distance simulated for points at the same location.");
    w.setToolTipText("Tunes the atraction of points the higher this value the smaller the attraction. Default value is 1.");
    d.setToolTipText("This parameter makes cluster separation more significant if value is bigger than 1.");
    r.setToolTipText("Parameter prevents points from coming too close to each other. Value is normally 1, allowed are values from (0, infinite).");
    mdsgroupLabel.setFont(new java.awt.Font("Tahoma", 1, 11));
    mdsgroupLabel.setText("MDS Visualization parameters:");
    stepAwaitLabel.setText("Step wait:");
    startWaitLabel.setText("Start wait:");
    stopConditionLabel.setText("Stop condition:");
    clusteringAlgorithmLabel.setFont(new java.awt.Font("Tahoma", 1, 11));
    clusteringAlgorithmLabel.setText("Clustering Algorithm:");
    jLabel1.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel1.setText("Clustering Metric:");
    clusteringMetric.setModel(new javax.swing.DefaultComboBoxModel(metrics));
    clusteringMetric.setEnabled(false);
    clusteringAlgorithm.setModel(new javax.swing.DefaultComboBoxModel(algorithms));
    clusteringAlgorithm.setEnabled(false);
    jLabel2.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel2.setText("FDP Metric:");
    fdpMetric.setModel(new javax.swing.DefaultComboBoxModel(metrics));
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().addContainerGap().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(layout.createSequentialGroup().add(mdsgroupLabel).add(66, 66, 66)).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().add(10, 10, 10).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false).add(layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(stopConditionLabel).add(startWaitLabel).add(stepAwaitLabel)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(stepWait, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE).add(startWait, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE).add(stopCondition, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE))).add(org.jdesktop.layout.GroupLayout.LEADING, layout.createSequentialGroup().add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(minDistanceLabel).add(wLabel).add(dLabel).add(rLabel).add(gravityLabel)).add(12, 12, 12).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false).add(r).add(d).add(w).add(minDistance).add(gravity, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 103, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))))).add(fdpGroupLabel)).add(17, 17, 17).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().add(10, 10, 10).add(fdpMetric, 0, 109, Short.MAX_VALUE)).add(jLabel2).add(clusteringAlgorithmLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).add(jLabel1).add(layout.createSequentialGroup().add(10, 10, 10).add(clusteringAlgorithm, 0, 171, Short.MAX_VALUE)).add(layout.createSequentialGroup().add(10, 10, 10).add(clusteringMetric, 0, 171, Short.MAX_VALUE))))).add(org.jdesktop.layout.GroupLayout.TRAILING, frameTitle, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 390, Short.MAX_VALUE)).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().add(frameTitle, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(17, 17, 17).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(fdpGroupLabel).add(jLabel1)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(gravityLabel).add(gravity, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(clusteringMetric, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(minDistanceLabel).add(minDistance, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(clusteringAlgorithmLabel)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(wLabel).add(w, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(clusteringAlgorithm, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(dLabel).add(d, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(jLabel2)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(rLabel).add(r, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE).add(fdpMetric, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).add(18, 18, 18).add(mdsgroupLabel).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(stepAwaitLabel).add(stepWait, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).add(layout.createSequentialGroup().add(26, 26, 26).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(startWaitLabel).add(startWait, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(stopConditionLabel).add(stopCondition, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))).addContainerGap()));
}
Example 77
Project: ChromisPOS-master  File: JPanelConfigRestaurant.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    jPanel3 = new javax.swing.JPanel();
    jLabelCustomerTextColour = new javax.swing.JLabel();
    jCustomerColour = new javax.swing.JComboBox();
    jLabelServerTextColour = new javax.swing.JLabel();
    jWaiterColour = new javax.swing.JComboBox();
    jLabelTableNameTextColour = new javax.swing.JLabel();
    jTableNameColour = new javax.swing.JComboBox();
    jPanel1 = new javax.swing.JPanel();
    jchkShowCustomerDetails = new eu.hansolo.custom.SteelCheckBox();
    jchkShowWaiterDetails = new eu.hansolo.custom.SteelCheckBox();
    jTableButtons = new eu.hansolo.custom.SteelCheckBox();
    jTableDesign = new eu.hansolo.custom.SteelCheckBox();
    jAutoRefresh = new eu.hansolo.custom.SteelCheckBox();
    setMinimumSize(new java.awt.Dimension(700, 500));
    setPreferredSize(new java.awt.Dimension(700, 650));
    // NOI18N
    java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("pos_messages");
    // NOI18N
    jPanel3.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), bundle.getString("label.tabledisplayoptions"), javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Arial", 1, 12), new java.awt.Color(102, 102, 102)));
    jPanel3.setLayout(null);
    // NOI18N
    jLabelCustomerTextColour.setFont(new java.awt.Font("Arial", 0, 12));
    jLabelCustomerTextColour.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
    // NOI18N
    jLabelCustomerTextColour.setText(bundle.getString("label.textcolourcustomer"));
    jLabelCustomerTextColour.setMaximumSize(new java.awt.Dimension(0, 25));
    jLabelCustomerTextColour.setMinimumSize(new java.awt.Dimension(0, 0));
    jLabelCustomerTextColour.setPreferredSize(new java.awt.Dimension(0, 25));
    jPanel3.add(jLabelCustomerTextColour);
    jLabelCustomerTextColour.setBounds(240, 20, 130, 25);
    // NOI18N
    jCustomerColour.setFont(new java.awt.Font("Arial", 0, 14));
    jCustomerColour.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "black", "blue", "grey", "green", "orange", "red", "white", "yellow" }));
    jCustomerColour.setMaximumSize(new java.awt.Dimension(0, 25));
    jCustomerColour.setMinimumSize(new java.awt.Dimension(0, 0));
    jCustomerColour.setPreferredSize(new java.awt.Dimension(0, 25));
    jCustomerColour.setSelectedItem("blue");
    jPanel3.add(jCustomerColour);
    jCustomerColour.setBounds(380, 20, 200, 30);
    // NOI18N
    jLabelServerTextColour.setFont(new java.awt.Font("Arial", 0, 12));
    jLabelServerTextColour.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
    // NOI18N
    jLabelServerTextColour.setText(bundle.getString("label.textcolourwaiter"));
    jLabelServerTextColour.setMaximumSize(new java.awt.Dimension(0, 25));
    jLabelServerTextColour.setMinimumSize(new java.awt.Dimension(0, 0));
    jLabelServerTextColour.setPreferredSize(new java.awt.Dimension(0, 25));
    jPanel3.add(jLabelServerTextColour);
    jLabelServerTextColour.setBounds(240, 60, 130, 25);
    // NOI18N
    jWaiterColour.setFont(new java.awt.Font("Arial", 0, 14));
    jWaiterColour.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "black", "blue", "grey", "green", "orange", "red", "white", "yellow" }));
    jWaiterColour.setMaximumSize(new java.awt.Dimension(0, 25));
    jWaiterColour.setMinimumSize(new java.awt.Dimension(0, 0));
    jWaiterColour.setPreferredSize(new java.awt.Dimension(0, 25));
    jPanel3.add(jWaiterColour);
    jWaiterColour.setBounds(380, 60, 200, 30);
    // NOI18N
    jLabelTableNameTextColour.setFont(new java.awt.Font("Arial", 0, 12));
    jLabelTableNameTextColour.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
    // NOI18N
    jLabelTableNameTextColour.setText(bundle.getString("label.textclourtablename"));
    jLabelTableNameTextColour.setMaximumSize(new java.awt.Dimension(0, 25));
    jLabelTableNameTextColour.setMinimumSize(new java.awt.Dimension(0, 0));
    jLabelTableNameTextColour.setPreferredSize(new java.awt.Dimension(0, 25));
    jPanel3.add(jLabelTableNameTextColour);
    jLabelTableNameTextColour.setBounds(230, 100, 140, 30);
    // NOI18N
    jTableNameColour.setFont(new java.awt.Font("Arial", 0, 14));
    jTableNameColour.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "black", "blue", "grey", "green", "orange", "red", "white", "yellow" }));
    jTableNameColour.setMaximumSize(new java.awt.Dimension(0, 25));
    jTableNameColour.setMinimumSize(new java.awt.Dimension(0, 0));
    jTableNameColour.setPreferredSize(new java.awt.Dimension(0, 25));
    jPanel3.add(jTableNameColour);
    jTableNameColour.setBounds(380, 100, 200, 30);
    jPanel1.setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());
    // NOI18N
    jchkShowCustomerDetails.setText(bundle.getString("label.tableshowcustomerdetails"));
    jPanel1.add(jchkShowCustomerDetails, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 0, 220, -1));
    // NOI18N
    jchkShowWaiterDetails.setText(bundle.getString("label.tableshowwaiterdetails"));
    jPanel1.add(jchkShowWaiterDetails, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 40, 220, -1));
    jTableButtons.setBorder(null);
    // NOI18N
    jTableButtons.setText(bundle.getString("label.tablebuttons"));
    jTableButtons.setUi(null);
    jPanel1.add(jTableButtons, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 110, 220, -1));
    jPanel3.add(jPanel1);
    jPanel1.setBounds(10, 20, 220, 140);
    // NOI18N
    jTableDesign.setText(bundle.getString("label.enabletablepositions"));
    jPanel3.add(jTableDesign);
    jTableDesign.setBounds(10, 190, 230, 30);
    // NOI18N
    jAutoRefresh.setText(bundle.getString("label.autorefresh"));
    jPanel3.add(jAutoRefresh);
    jAutoRefresh.setBounds(10, 160, 210, 30);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jPanel3, javax.swing.GroupLayout.DEFAULT_SIZE, 680, Short.MAX_VALUE).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, 302, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(337, Short.MAX_VALUE)));
}
Example 78
Project: constellation-master  File: JServiceSosEditPane.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel2 = new javax.swing.JLabel();
    logLevelCombo = new javax.swing.JComboBox();
    jLabel1 = new javax.swing.JLabel();
    guiSMLDataSourceCombo = new javax.swing.JComboBox();
    SMLPane = new javax.swing.JPanel();
    jLabel3 = new javax.swing.JLabel();
    guiOMDataSourceCombo = new javax.swing.JComboBox();
    OMPane = new javax.swing.JPanel();
    // NOI18N
    java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("org/constellation/swing/Bundle");
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel2, bundle.getString("logLevel"));
    logLevelCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "INFO", "FINE", "FINER" }));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel1, bundle.getString("smlSourceType"));
    guiSMLDataSourceCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "mdweb", "filesystem" }));
    guiSMLDataSourceCombo.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            guiSMLDataSourceComboItemStateChanged(evt);
        }
    });
    SMLPane.setPreferredSize(new java.awt.Dimension(236, 256));
    javax.swing.GroupLayout SMLPaneLayout = new javax.swing.GroupLayout(SMLPane);
    SMLPane.setLayout(SMLPaneLayout);
    SMLPaneLayout.setHorizontalGroup(SMLPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 0, Short.MAX_VALUE));
    SMLPaneLayout.setVerticalGroup(SMLPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 249, Short.MAX_VALUE));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel3, bundle.getString("omSourceType"));
    guiOMDataSourceCombo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "OM2" }));
    guiOMDataSourceCombo.addItemListener(new java.awt.event.ItemListener() {

        public void itemStateChanged(java.awt.event.ItemEvent evt) {
            guiOMDataSourceComboItemStateChanged(evt);
        }
    });
    javax.swing.GroupLayout OMPaneLayout = new javax.swing.GroupLayout(OMPane);
    OMPane.setLayout(OMPaneLayout);
    OMPaneLayout.setHorizontalGroup(OMPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 0, Short.MAX_VALUE));
    OMPaneLayout.setVerticalGroup(OMPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 276, Short.MAX_VALUE));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(OMPane, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addComponent(jLabel3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(guiOMDataSourceCombo, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addComponent(SMLPane, javax.swing.GroupLayout.DEFAULT_SIZE, 638, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addComponent(jLabel2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(logLevelCombo, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addGroup(layout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(guiSMLDataSourceCombo, 0, 479, Short.MAX_VALUE))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel1).addComponent(guiSMLDataSourceCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(SMLPane, javax.swing.GroupLayout.PREFERRED_SIZE, 249, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel3).addComponent(guiOMDataSourceCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(OMPane, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel2).addComponent(logLevelCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap()));
}
Example 79
Project: Cooking-to-Goal-master  File: EditMealPanel.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    datePickerAddon1 = new org.jdesktop.swingx.plaf.DatePickerAddon();
    jLabelTitle = new javax.swing.JLabel();
    jScrollPane2 = new javax.swing.JScrollPane();
    jTextPane1 = new javax.swing.JTextPane();
    jComboBoxMeMenu = new javax.swing.JComboBox();
    jXDatePickerDate = new org.jdesktop.swingx.JXDatePicker();
    jXComboBoxMeal = new org.jdesktop.swingx.JXComboBox();
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    jButtonOK = new javax.swing.JButton();
    jButtonCancel = new javax.swing.JButton();
    jLabelTitle.setFont(new java.awt.Font("Tahoma", 3, 18));
    jLabelTitle.setText("Edit Meal");
    jScrollPane2.setBorder(null);
    jTextPane1.setBackground(javax.swing.UIManager.getDefaults().getColor("control"));
    jTextPane1.setBorder(null);
    jTextPane1.setEditable(false);
    jTextPane1.setText("For what event do you want to plan this meal?");
    jTextPane1.setFocusable(false);
    jTextPane1.setMargin(new java.awt.Insets(0, 0, 0, 0));
    jTextPane1.setOpaque(false);
    jTextPane1.setVerifyInputWhenFocusTarget(false);
    jScrollPane2.setViewportView(jTextPane1);
    jComboBoxMeMenu.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Me Menu", "Edit User", "Logout" }));
    jComboBoxMeMenu.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jComboBoxMeMenuActionPerformed(evt);
        }
    });
    jXComboBoxMeal.setEditable(true);
    jLabel1.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel1.setText("Date:");
    jLabel2.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel2.setText("Meal:");
    jButtonOK.setText("OK");
    jButtonOK.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButtonOKActionPerformed(evt);
        }
    });
    jButtonCancel.setText("Cancel");
    jButtonCancel.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButtonCancelActionPerformed(evt);
        }
    });
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 274, Short.MAX_VALUE).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addComponent(jLabelTitle, javax.swing.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jComboBoxMeMenu, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createSequentialGroup().addComponent(jLabel2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(jXComboBoxMeal, javax.swing.GroupLayout.PREFERRED_SIZE, 152, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(jXDatePickerDate, javax.swing.GroupLayout.PREFERRED_SIZE, 126, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createSequentialGroup().addComponent(jButtonOK).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButtonCancel))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabelTitle).addComponent(jComboBoxMeMenu, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel1).addComponent(jXDatePickerDate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel2).addComponent(jXComboBoxMeal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButtonOK).addComponent(jButtonCancel)).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
}
Example 80
Project: Gw2InfoViewer-master  File: OptionsForm.java View source code
public void setOptions(Options options, WorldNames worldNames, MapNames mapNames) {
    DefaultComboBoxModel worldComboBoxModel = new DefaultComboBoxModel();
    DefaultComboBoxModel mapComboBoxModel = new DefaultComboBoxModel();
    mapComboBoxModel.addElement("None");
    worldComboBoxModel.addElement("None");
    List<String> sortedMapNames = new ArrayList<String>();
    sortedMapNames.addAll(worldNames.getMap().values());
    Collections.sort(sortedMapNames);
    for (Iterator<String> it = sortedMapNames.iterator(); it.hasNext(); ) {
        mapComboBoxModel.addElement(it.next());
    }
    List<String> sortedWorldNames = new ArrayList<String>();
    sortedWorldNames.addAll(worldNames.getMap().values());
    Collections.sort(sortedWorldNames);
    for (Iterator<String> it = sortedWorldNames.iterator(); it.hasNext(); ) {
        worldComboBoxModel.addElement(it.next());
    }
    mapComboBox.setModel(mapComboBoxModel);
    worldComboBox.setModel(worldComboBoxModel);
    if (options.getMap() != 0) {
        mapComboBox.setSelectedItem(mapNames.getMap().get(options.getMap()));
    } else {
        mapComboBox.setSelectedItem("None");
    }
    if (options.getWorld() != 0) {
        worldComboBox.setSelectedItem(worldNames.getMap().get(options.getWorld()));
    } else {
        worldComboBox.setSelectedItem("None");
    }
    eventIdText.setText(options.getEventId());
    matchIdText.setText(options.getMatchId().toString());
    proxyEnabledCheckbox.setSelected(options.isProxyEnabled());
    proxyAddressText.setText(options.getProxyAddress());
    proxyPortText.setText(options.getProxyPort().toString());
}
Example 81
Project: liquiface-master  File: AddForeignKeyVisualPanel1.java View source code
@Override
public void actionPerformed(ActionEvent e) {
    String referencedTableName = (String) referencedTableField.getSelectedItem();
    if (!"".equals(referencedTableName)) {
        List<String> constraintNames = new ArrayList<String>();
        constraintNames.add("");
        Table referencedTable = ModelFacade.getInstance().getTableByName(referencedTableName);
        PrimaryKeyConstraint pk = referencedTable.getPrimaryKeyConstraint();
        if (pk != null) {
            constraintNames.add(pk.getName());
        }
        for (UniqueConstraint uniqueConstraint : referencedTable.getUniqueConstraints()) {
            constraintNames.add(uniqueConstraint.getName());
        }
        referencedConstraintField.setModel(new DefaultComboBoxModel(constraintNames.toArray()));
        columnsTable.setModel(new AddForeignKeyTableModel(new Object[][] {}, new String[] { "Referenced column", "Local column" }));
    }
}
Example 82
Project: netbeans-mmd-plugin-master  File: MovePanel.java View source code
private void initValues() {
    final String text;
    if (this.files.length > 1) {
        text = String.format(BUNDLE.getString("MovePanel.multiFileText"), Integer.toString(this.files.length));
    } else {
        text = String.format(BUNDLE.getString("MovePanel.singleFileText"), this.files[0].getName());
    }
    this.labelMessage.setText(text);
    final List<Project> projects = new ArrayList<Project>();
    for (final Project p : OpenProjects.getDefault().getOpenProjects()) {
        projects.add(p);
    }
    final ComboBoxModel<Project> projectModel = new DefaultComboBoxModel<Project>(projects.toArray(new Project[projects.size()]));
    final ItemListener listener = new ItemListener() {

        @Override
        public void itemStateChanged(final ItemEvent e) {
            if (comboProjects.equals(e.getSource())) {
                updateFolders();
                parent.stateChanged(null);
            } else if (comboFolders.equals(e.getSource())) {
                parent.stateChanged(null);
            }
        }
    };
    this.comboProjects.addItemListener(listener);
    this.comboFolders.addItemListener(listener);
    this.comboProjects.setModel(projectModel);
    this.comboProjects.setSelectedItem(FileOwnerQuery.getOwner(this.files[0]));
    updateFolders();
    final ExplorerContext explorerContext = this.lookup.lookup(ExplorerContext.class);
    if (explorerContext != null) {
        final Node targetNode = explorerContext.getTargetNode();
        if (targetNode != null) {
            final DataObject dobj = targetNode.getLookup().lookup(DataObject.class);
            if (dobj != null) {
                final FileObject fo = dobj.getPrimaryFile();
                if (fo != null && fo.isValid() && fo.isFolder()) {
                    final Project proj = FileOwnerQuery.getOwner(fo);
                    if (proj != null) {
                        this.comboProjects.setSelectedItem(proj);
                        this.comboFolders.setSelectedItem(FileUtil.getRelativePath(proj.getProjectDirectory(), fo));
                    }
                }
            }
        }
    }
}
Example 83
Project: SHPExporter-master  File: SHPExporterDialog.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    fakeRealGroup = new javax.swing.ButtonGroup();
    fileChooser = new javax.swing.JFileChooser();
    realCoordinatesRadioButton = new javax.swing.JRadioButton();
    fakeCoordinatesRadioButton = new javax.swing.JRadioButton();
    jLabel2 = new javax.swing.JLabel();
    longitudeComboBox = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    latitudeComboBox = new javax.swing.JComboBox();
    jSeparator1 = new javax.swing.JSeparator();
    filler1 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0));
    filler2 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(32767, 0));
    filler3 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(32767, 0));
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    fileChooser.setAcceptAllFileFilterUsed(false);
    fileChooser.setDialogType(javax.swing.JFileChooser.SAVE_DIALOG);
    // NOI18N
    fileChooser.setApproveButtonToolTipText(org.openide.util.NbBundle.getMessage(SHPExporterDialog.class, "SHPExporterDialog.approveButtonToolTipText"));
    fileChooser.setCurrentDirectory(null);
    // NOI18N
    fileChooser.setDialogTitle(org.openide.util.NbBundle.getMessage(SHPExporterDialog.class, "SHPExporterDialog.dialogTitle"));
    // NOI18N
    fileChooser.setName("");
    fileChooser.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            fileChooserAction(evt);
        }
    });
    fakeRealGroup.add(realCoordinatesRadioButton);
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(realCoordinatesRadioButton, org.openide.util.NbBundle.getMessage(SHPExporterDialog.class, "SHPExporterDialog.realCoordinatesRadioButton.text"));
    realCoordinatesRadioButton.addChangeListener(new javax.swing.event.ChangeListener() {

        public void stateChanged(javax.swing.event.ChangeEvent evt) {
            updateRealFake(evt);
        }
    });
    fakeRealGroup.add(fakeCoordinatesRadioButton);
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(fakeCoordinatesRadioButton, org.openide.util.NbBundle.getMessage(SHPExporterDialog.class, "SHPExporterDialog.fakeCoordinatesRadioButton.text"));
    fakeCoordinatesRadioButton.addChangeListener(new javax.swing.event.ChangeListener() {

        public void stateChanged(javax.swing.event.ChangeEvent evt) {
            updateRealFake(evt);
        }
    });
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel2, org.openide.util.NbBundle.getMessage(SHPExporterDialog.class, "SHPExporterDialog.jLabel2.text"));
    longitudeComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(jLabel3, org.openide.util.NbBundle.getMessage(SHPExporterDialog.class, "SHPExporterDialog.jLabel3.text"));
    latitudeComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(fileChooser, javax.swing.GroupLayout.DEFAULT_SIZE, 650, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jSeparator1, javax.swing.GroupLayout.Alignment.TRAILING).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(filler3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addGroup(layout.createSequentialGroup().addGap(219, 219, 219).addComponent(jLabel3).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(latitudeComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, 197, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createSequentialGroup().addComponent(realCoordinatesRadioButton).addGap(18, 18, 18).addComponent(jLabel2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(longitudeComboBox, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addComponent(fakeCoordinatesRadioButton))).addGroup(layout.createSequentialGroup().addGap(68, 68, 68).addComponent(filler1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(filler2, javax.swing.GroupLayout.PREFERRED_SIZE, 191, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, Short.MAX_VALUE))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addGap(11, 11, 11).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(realCoordinatesRadioButton).addComponent(jLabel2).addComponent(longitudeComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(24, 24, 24).addComponent(fakeCoordinatesRadioButton)).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel3).addComponent(latitudeComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(filler3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 3, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(filler1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(1, 1, 1).addComponent(filler2, javax.swing.GroupLayout.PREFERRED_SIZE, 0, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(fileChooser, javax.swing.GroupLayout.DEFAULT_SIZE, 352, Short.MAX_VALUE)));
    pack();
}
Example 84
Project: tif-master  File: DifferenceDialog.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    diffProgress = new javax.swing.JProgressBar();
    cancelBtn = new javax.swing.JButton();
    diffBtn = new javax.swing.JButton();
    combo1 = new javax.swing.JComboBox();
    complbl = new javax.swing.JLabel();
    withlbl = new javax.swing.JLabel();
    combo2 = new javax.swing.JComboBox();
    checkReport = new javax.swing.JCheckBox();
    txtReport = new javax.swing.JTextField();
    btnReportBrowse = new javax.swing.JButton();
    summaryTextScroll = new javax.swing.JScrollPane();
    summaryText = new javax.swing.JTextArea();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    setTitle("Select two definitions to difference");
    diffProgress.setStringPainted(true);
    cancelBtn.setText("Cancel");
    cancelBtn.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            cancelBtnActionPerformed(evt);
        }
    });
    diffBtn.setText("Difference");
    diffBtn.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            diffBtnActionPerformed(evt);
        }
    });
    combo1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    combo1.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            combo1ActionPerformed(evt);
        }
    });
    complbl.setText("Compare template");
    withlbl.setText("with");
    combo2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    combo2.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            combo2ActionPerformed(evt);
        }
    });
    checkReport.setText("Generate detail report");
    checkReport.addChangeListener(new javax.swing.event.ChangeListener() {

        public void stateChanged(javax.swing.event.ChangeEvent evt) {
            stateReportChanged(evt);
        }
    });
    txtReport.setText("report.diff");
    txtReport.setEnabled(false);
    btnReportBrowse.setText("...");
    btnReportBrowse.setEnabled(false);
    btnReportBrowse.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            btnReportBrowseActionPerformed(evt);
        }
    });
    summaryText.setEditable(false);
    summaryText.setColumns(20);
    // NOI18N
    summaryText.setFont(new java.awt.Font("Tahoma", 0, 12));
    summaryText.setLineWrap(true);
    summaryText.setRows(3);
    summaryText.setText("Generate difference to make Template 1 equivalent to Template 2");
    summaryText.setWrapStyleWord(true);
    summaryText.setAutoscrolls(false);
    summaryTextScroll.setViewportView(summaryText);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(combo1, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(combo2, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(diffProgress, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(summaryTextScroll, javax.swing.GroupLayout.DEFAULT_SIZE, 409, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(complbl).addComponent(withlbl).addComponent(checkReport)).addGap(0, 0, Short.MAX_VALUE)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addGap(0, 0, Short.MAX_VALUE).addComponent(diffBtn).addGap(18, 18, 18).addComponent(cancelBtn)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addComponent(txtReport).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(btnReportBrowse, javax.swing.GroupLayout.PREFERRED_SIZE, 27, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(4, 4, 4))).addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(6, 6, 6).addComponent(complbl).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(combo1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(withlbl).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(combo2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(summaryTextScroll, javax.swing.GroupLayout.DEFAULT_SIZE, 58, Short.MAX_VALUE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(checkReport).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(txtReport, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btnReportBrowse)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(diffProgress, javax.swing.GroupLayout.PREFERRED_SIZE, 25, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(46, 46, 46)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(cancelBtn).addComponent(diffBtn)).addContainerGap()))));
    java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize();
    setBounds((screenSize.width - 445) / 2, (screenSize.height - 326) / 2, 445, 326);
}
Example 85
Project: Ardulink-master  File: DigisparkConnectionPanel.java View source code
public void actionPerformed(ActionEvent e) {
    List<String> portList = link.getPortList();
    //				portList.add("COM20");
    if (portList != null && !portList.isEmpty()) {
        deviceComboBox.setModel(new DefaultComboBoxModel(portList.toArray(new String[portList.size()])));
    } else {
        deviceComboBox.removeAllItems();
    }
}
Example 86
Project: ceres-master  File: ComboBoxAdapter.java View source code
private void adjustComboBoxModel() {
    ValueSet valueSet = getValueDescriptor().getValueSet();
    if (valueSet != null) {
        final Object oldValue = getBinding().getPropertyValue();
        comboBox.setModel(new DefaultComboBoxModel(valueSet.getItems()));
        comboBox.setSelectedItem(oldValue);
        adjustProperty();
    } else {
    // No else here, "valueSet == null" means the comboBox's model
    // is controlled by client.
    }
}
Example 87
Project: Cinch-master  File: JComboBoxWiringHarness.java View source code
private void updateComboModel(JComboBox combo, List<?> newContents, String nullValue) {
    int selectedIndex = combo.getSelectedIndex();
    Object selected = combo.getSelectedItem();
    DefaultComboBoxModel comboModel = new DefaultComboBoxModel();
    if (nullValue != null) {
        comboModel.addElement(nullValue);
    }
    for (Object obj : newContents) {
        comboModel.addElement(obj);
    }
    if (comboModel.getIndexOf(selected) != -1) {
        comboModel.setSelectedItem(selected);
    } else {
        if (comboModel.getSize() > selectedIndex) {
            comboModel.setSelectedItem(combo.getItemAt(selectedIndex));
        } else if (comboModel.getSize() > 0) {
            comboModel.setSelectedItem(combo.getItemAt(comboModel.getSize() - 1));
        }
    }
    combo.setModel(comboModel);
}
Example 88
Project: Classeur-master  File: JSane_Combo.java View source code
/*
	 * Overridden method
	 */
public void setWidgetOptions(Object value) {
    if (value instanceof JSane_Base_Constraint_String_List) {
        JSane_Base_Constraint_String_List list = (JSane_Base_Constraint_String_List) value;
        setModel(new DefaultComboBoxModel(list.getList()));
        setSelectedItem(list.elementAt(0));
        return;
    }
    if (value instanceof JSane_Base_Constraint_Word_List) {
        JSane_Base_Constraint_Word_List list = (JSane_Base_Constraint_Word_List) value;
        setModel(new DefaultComboBoxModel(list.getList()));
        setSelectedItem(list.elementAt(0));
        return;
    }
}
Example 89
Project: ConverterApp-master  File: ConverterView.java View source code
// </editor-fold>//GEN-END:initComponents
private void toggleBtn_switchItemStateChanged(java.awt.event.ItemEvent evt) {
    //GEN-FIRST:event_toggleBtn_switchItemStateChanged
    // TODO add your handling code here: swap the source units into target units and otherwise
    int selectedSourceIndex = cbox_sourceUnit.getSelectedIndex();
    int selectedTargetIndex = cbox_targetUnit.getSelectedIndex();
    if (evt.getStateChange() == ItemEvent.DESELECTED) {
        cbox_sourceUnit.setModel(new javax.swing.DefaultComboBoxModel(ISUnits));
        cbox_targetUnit.setModel(new javax.swing.DefaultComboBoxModel(USUnits));
    } else {
        cbox_sourceUnit.setModel(new javax.swing.DefaultComboBoxModel(USUnits));
        cbox_targetUnit.setModel(new javax.swing.DefaultComboBoxModel(ISUnits));
    }
    cbox_sourceUnit.setSelectedIndex(selectedTargetIndex);
    cbox_targetUnit.setSelectedIndex(selectedSourceIndex);
}
Example 90
Project: DataCleaner-master  File: SchemaNamePropertyWidget.java View source code
public void setDatastore(final Datastore datastore) {
    final String previousValue = getValue();
    _datastoreRef.set(datastore);
    if (datastore == null) {
        _comboBox.setModel(new DefaultComboBoxModel<>(new Schema[1]));
    } else {
        try (DatastoreConnection con = datastore.openConnection()) {
            Schema[] schemas = con.getSchemaNavigator().getSchemas();
            schemas = CollectionUtils.array(new Schema[1], schemas);
            _comboBox.setModel(new DefaultComboBoxModel<>(schemas));
            Schema newValue = null;
            if (previousValue != null) {
                newValue = con.getSchemaNavigator().getSchemaByName(previousValue);
            }
            if (newValue == null) {
                newValue = con.getSchemaNavigator().getDefaultSchema();
            }
            _comboBox.setSelectedItem(newValue);
        }
    }
}
Example 91
Project: deegree2-desktop-master  File: MapModelDialog.java View source code
private void initGUI() {
    try {
        GridBagLayout thisLayout = new GridBagLayout();
        getContentPane().setLayout(thisLayout);
        {
            pnDesc = new JPanel();
            BorderLayout pnDescLayout = new BorderLayout();
            pnDesc.setLayout(pnDescLayout);
            getContentPane().add(pnDesc, new GridBagConstraints(0, 0, 1, 2, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(0, 0, 0, 5), 0, 0));
            pnDesc.setBorder(BorderFactory.createTitledBorder("map model selection"));
            {
                tpDesp = new JTextPane();
                pnDesc.add(tpDesp, BorderLayout.CENTER);
                tpDesp.setText(Messages.get("$DI10041"));
                tpDesp.setBackground(new Color(212, 208, 200));
                tpDesp.setEditable(false);
            }
        }
        {
            pnModels = new JPanel();
            BorderLayout pnModelsLayout = new BorderLayout();
            pnModels.setLayout(pnModelsLayout);
            getContentPane().add(pnModels, new GridBagConstraints(1, 0, 1, 2, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(0, 5, 0, 0), 0, 0));
            pnModels.setBorder(BorderFactory.createTitledBorder("available map models"));
            {
                ListModel lstMapModelsModel = new DefaultComboBoxModel(mapModels);
                lstMapModels = new JList();
                pnModels.add(lstMapModels, BorderLayout.CENTER);
                lstMapModels.setModel(lstMapModelsModel);
            }
        }
        {
            pnButtons = new JPanel();
            FlowLayout pnButtonsLayout = new FlowLayout();
            pnButtonsLayout.setAlignment(FlowLayout.LEFT);
            getContentPane().add(pnButtons, new GridBagConstraints(0, 2, 2, 1, 0.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
            pnButtons.setLayout(pnButtonsLayout);
            {
                btOK = new JButton("add map model", IconRegistry.getIcon("accept.png"));
                pnButtons.add(btOK);
                btOK.addActionListener(new ActionListener() {

                    public void actionPerformed(ActionEvent e) {
                        dispose();
                    }
                });
            }
            {
                btCancel = new JButton("cancel", IconRegistry.getIcon("cancel.png"));
                pnButtons.add(btCancel);
                btCancel.addActionListener(new ActionListener() {

                    public void actionPerformed(ActionEvent e) {
                        lstMapModels.removeSelectionInterval(0, mapModels.length - 1);
                        dispose();
                    }
                });
            }
        }
        thisLayout.rowWeights = new double[] { 0.0, 0.0, 0.1 };
        thisLayout.rowHeights = new int[] { 127, 124, 7 };
        thisLayout.columnWeights = new double[] { 0.0, 0.1 };
        thisLayout.columnWidths = new int[] { 178, 7 };
        this.setSize(414, 317);
    } catch (Exception e) {
        e.printStackTrace();
    }
}
Example 92
Project: domainmath-ide-master  File: GlpkPanel.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jSplitPane1 = new javax.swing.JSplitPane();
    jPanel2 = new javax.swing.JPanel();
    AButton = new javax.swing.JButton();
    jLabel14 = new javax.swing.JLabel();
    ATextField = new javax.swing.JTextField();
    jLabel15 = new javax.swing.JLabel();
    bTextField = new javax.swing.JTextField();
    bButton = new javax.swing.JButton();
    ubTextField = new javax.swing.JTextField();
    jLabel16 = new javax.swing.JLabel();
    lbButton = new javax.swing.JButton();
    lbTextField = new javax.swing.JTextField();
    jLabel17 = new javax.swing.JLabel();
    vartypeTextField = new javax.swing.JTextField();
    jLabel18 = new javax.swing.JLabel();
    helpButton = new javax.swing.JButton();
    ubButton = new javax.swing.JButton();
    jLabel19 = new javax.swing.JLabel();
    ctypeTextField = new javax.swing.JTextField();
    jLabel20 = new javax.swing.JLabel();
    jSeparator2 = new javax.swing.JSeparator();
    jLabel21 = new javax.swing.JLabel();
    cButton = new javax.swing.JButton();
    cTextField = new javax.swing.JTextField();
    runButton = new javax.swing.JButton();
    senseComboBox = new javax.swing.JComboBox();
    jLabel22 = new javax.swing.JLabel();
    jLabel23 = new javax.swing.JLabel();
    jLabel24 = new javax.swing.JLabel();
    jPanel1 = new javax.swing.JPanel();
    jSeparator1 = new javax.swing.JSeparator();
    param_branchComboBox = new javax.swing.JComboBox();
    jLabel9 = new javax.swing.JLabel();
    jLabel12 = new javax.swing.JLabel();
    param_itcntTextField = new javax.swing.JTextField();
    param_priceComboBox = new javax.swing.JComboBox();
    jLabel2 = new javax.swing.JLabel();
    jLabel1 = new javax.swing.JLabel();
    param_roundComboBox = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    jLabel6 = new javax.swing.JLabel();
    param_dualComboBox = new javax.swing.JComboBox();
    jLabel10 = new javax.swing.JLabel();
    jLabel7 = new javax.swing.JLabel();
    param_btrackComboBox = new javax.swing.JComboBox();
    jLabel4 = new javax.swing.JLabel();
    jLabel5 = new javax.swing.JLabel();
    jLabel8 = new javax.swing.JLabel();
    param_scaleComboBox = new javax.swing.JComboBox();
    jLabel11 = new javax.swing.JLabel();
    param_msglevComboBox = new javax.swing.JComboBox();
    param_lpsolverComboBox = new javax.swing.JComboBox();
    param_itlimTextField = new javax.swing.JTextField();
    param_presolTextField = new javax.swing.JTextField();
    jSplitPane1.setDividerLocation(400);
    AButton.setText("[mxn]");
    AButton.setToolTipText("Convert the text to Octave matrix style");
    AButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            AButtonActionPerformed(evt);
        }
    });
    // NOI18N
    jLabel14.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel14.setText("Constraints Coefficients");
    ATextField.setToolTipText("<html>A matrix containing the <b>constraints coefficients</b></html>");
    // NOI18N
    jLabel15.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel15.setText("Lower Bound");
    bTextField.setToolTipText("<html>A column array containing the<b> right-hand side value for<br> each constraint in the constraint matrix</b></html>");
    bButton.setText("[mxn]");
    bButton.setToolTipText("Convert the text to Octave matrix style");
    bButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            bButtonActionPerformed(evt);
        }
    });
    ubTextField.setToolTipText("<html>An array containing the <b>upper bound</b> on each of the variables.<br> If ub is not supplied, the default upper bound is assumed to be infinite</html>");
    // NOI18N
    jLabel16.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel16.setText("Upper Bound");
    lbButton.setText("[mxn]");
    lbButton.setToolTipText("Convert the text to Octave matrix style");
    lbButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            lbButtonActionPerformed(evt);
        }
    });
    lbTextField.setToolTipText("<html>An array containing the<b> lower bound</b> on each of the variables.<br> If lb is not supplied, the default lower bound for the variables is zero</html>");
    // NOI18N
    jLabel17.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel17.setText("sense");
    vartypeTextField.setText("\"CCC\"");
    vartypeTextField.setToolTipText("<html>A column array containing the types of the variables.<br>\"C\"<br>   A continuous variable.<br>\"I\"<br>   An integer variable.</html> ");
    // NOI18N
    jLabel18.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel18.setText("ctype");
    helpButton.setText("Help");
    helpButton.setToolTipText("<html> Function File: [<var>xopt</var>,\n<var>fmin</var>, <var>status</var>, <var>extra</var>]\n= <b>glpk</b> (<var>c, A, b, lb, ub, ctype, vartype,\nsense, param</var>)<var><a name=\"index-glpk-2449\"></a></var><br>\n<p>Solve a linear program using the GNU <span class=\"sc\">glpk</span>\nlibrary. Given three\narguments, <code>glpk</code> solves the following standard\nLP: </p>\n<pre class=\"example\">          min C'*x<br></pre>\n<p>subject to </p>\n<pre class=\"example\">          A*x  = b<br>            x >= 0<br></pre>\n<p>but may also solve problems of the form </p>\n<pre class=\"example\">          [ min | max ] C'*x<br></pre>\n<p>subject to </p>\n<pre class=\"example\">          A*x [ \"=\" | \"<=\" | \">=\" ] b<br>            x >= LB<br>            x <= UB<br></pre></html>");
    helpButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            helpButtonActionPerformed(evt);
        }
    });
    ubButton.setText("[mxn]");
    ubButton.setToolTipText("Convert the text to Octave matrix style");
    ubButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            ubButtonActionPerformed(evt);
        }
    });
    // NOI18N
    jLabel19.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel19.setText("vartype");
    ctypeTextField.setText("\"UUU\"");
    ctypeTextField.setToolTipText("<html>An array of characters containing the sense of each constraint in the constraint matrix.<br> Each element of the array may be one of the following values<br>\"F\"<br>   A free (unbounded) constraint (the constraint is ignored).<br>\"U\"<br>   An inequality constraint with an upper bound (A(i,:)*x <= b(i)).<br>\"S\"<br>    An equality constraint (A(i,:)*x = b(i)).<br>\"L\"<br>   An inequality with a lower bound (A(i,:)*x >= b(i)).<br>\n\"D\"<br>   An inequality constraint with both upper and lower bounds (A(i,:)*x >= -b(i) and (A(i,:)*x <= b(i)).</html>");
    jLabel20.setForeground(new java.awt.Color(0, 0, 255));
    jLabel20.setText("Data");
    // NOI18N
    jLabel21.setFont(new java.awt.Font("Tahoma", 1, 11));
    jLabel21.setText("Objective Function");
    cButton.setText("[mxn]");
    cButton.setToolTipText("Convert the text to Octave matrix style");
    cButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            cButtonActionPerformed(evt);
        }
    });
    cTextField.setToolTipText("<html>A column array containing<br> the <b>objective function coefficients<b><html>");
    runButton.setText("Run");
    runButton.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            runButtonActionPerformed(evt);
        }
    });
    senseComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "minimization", "maximization" }));
    jLabel22.setText("c:");
    jLabel23.setText("A:");
    jLabel24.setText("b:");
    javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
    jPanel2.setLayout(jPanel2Layout);
    jPanel2Layout.setHorizontalGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addContainerGap().addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addComponent(jLabel20).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jSeparator2)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup().addComponent(helpButton).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(runButton).addGap(29, 29, 29)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup().addGap(10, 10, 10).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel21).addComponent(jLabel14).addGroup(jPanel2Layout.createSequentialGroup().addGap(10, 10, 10).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel22).addComponent(jLabel24).addComponent(jLabel23)))).addGap(36, 36, 36).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addGroup(jPanel2Layout.createSequentialGroup().addComponent(bTextField).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(AButton)).addGroup(jPanel2Layout.createSequentialGroup().addComponent(cTextField).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(cButton)).addGroup(jPanel2Layout.createSequentialGroup().addComponent(ATextField).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(bButton)))).addGroup(jPanel2Layout.createSequentialGroup().addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel15).addComponent(jLabel16)).addGap(98, 98, 98).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(lbTextField, javax.swing.GroupLayout.DEFAULT_SIZE, 132, Short.MAX_VALUE).addComponent(ubTextField, javax.swing.GroupLayout.DEFAULT_SIZE, 132, Short.MAX_VALUE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(lbButton).addComponent(ubButton))).addGroup(jPanel2Layout.createSequentialGroup().addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel18).addComponent(jLabel19).addComponent(jLabel17)).addGap(125, 125, 125).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(vartypeTextField, javax.swing.GroupLayout.Alignment.TRAILING).addComponent(ctypeTextField).addComponent(senseComboBox, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))))).addContainerGap()));
    jPanel2Layout.setVerticalGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addContainerGap().addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jSeparator2, javax.swing.GroupLayout.PREFERRED_SIZE, 10, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel20)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jLabel21).addGap(2, 2, 2).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(cTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(cButton).addComponent(jLabel22)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jLabel14).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel23).addComponent(bButton).addComponent(ATextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel24).addComponent(AButton).addComponent(bTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel15).addComponent(lbTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(lbButton)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel16).addComponent(ubTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(ubButton)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel18).addComponent(ctypeTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel19).addComponent(vartypeTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel17).addComponent(senseComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 88, Short.MAX_VALUE).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(runButton).addComponent(helpButton)).addContainerGap()));
    jSplitPane1.setLeftComponent(jPanel2);
    param_branchComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { " ", "Branch on the first variable", "Branch on the last variable", "Branch using a heuristic by Driebeck and Tomlin" }));
    jLabel9.setText("Branching Heuristic  (for MIP only)");
    jLabel12.setText("LP Solver");
    param_priceComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { " ", "Textbook pricing.", "Steepest edge pricing. " }));
    jLabel2.setText("Output Message");
    jLabel1.setForeground(new java.awt.Color(0, 0, 255));
    jLabel1.setText("Parameters");
    param_roundComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { " ", "Report all primal and dual values \"as is\"", "Replace tiny primal and dual values by exact zero. " }));
    jLabel3.setText("Scaling");
    jLabel6.setText("Solution Rounding");
    param_dualComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { " ", "No dual simplex", "Use dual simplex" }));
    jLabel10.setText("Backtracking Heuristic  (for MIP only)");
    jLabel7.setText("Simplex Iterations Limit");
    param_btrackComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { " ", "Depth first search", "Breadth first search", "Backtrack using the best projection heuristic" }));
    jLabel4.setText("Dual Simplex ");
    jLabel5.setText("Pricing");
    jLabel8.setText("Output Frequency in Iterations");
    param_scaleComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { " ", "No scaling", "Equilibration scaling", "Geometric mean scaling" }));
    jLabel11.setText("LP Presolver");
    param_msglevComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "No output", "Error messages only", "Normal output", "Full output (includes informational messages)" }));
    param_msglevComboBox.setToolTipText("");
    param_lpsolverComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Revised simplex method.", "Interior point method. " }));
    javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addContainerGap().addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jSeparator1)).addGroup(jPanel1Layout.createSequentialGroup().addGap(10, 10, 10).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel2).addComponent(jLabel3).addComponent(jLabel4).addComponent(jLabel5).addComponent(jLabel6).addComponent(jLabel7).addComponent(jLabel8).addComponent(jLabel9).addComponent(jLabel10).addComponent(jLabel11).addComponent(jLabel12)).addGap(24, 24, 24).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(param_priceComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_roundComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_itlimTextField).addComponent(param_itcntTextField).addComponent(param_branchComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_btrackComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_lpsolverComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_presolTextField).addComponent(param_msglevComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_scaleComboBox, 0, 1, Short.MAX_VALUE).addComponent(param_dualComboBox, 0, 1, Short.MAX_VALUE)).addGap(87, 87, 87))).addGap(55, 55, 55)));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addContainerGap().addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 10, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel1)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel2).addComponent(param_msglevComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(param_scaleComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel3)).addGap(9, 9, 9).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel4).addComponent(param_dualComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel5).addComponent(param_priceComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel6).addComponent(param_roundComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel7).addComponent(param_itlimTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel8).addComponent(param_itcntTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel9).addComponent(param_branchComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(param_btrackComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel10)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel11).addComponent(param_presolTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel12).addComponent(param_lpsolverComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap(97, Short.MAX_VALUE)));
    jSplitPane1.setRightComponent(jPanel1);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 774, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(jSplitPane1).addGap(0, 0, 0))));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 413, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jSplitPane1)));
}
Example 93
Project: freehep-ncolor-pdf-master  File: OpenStyleStorePanel.java View source code
public void updateAction() {
    list.clear();
    map.clear();
    StyleRegistry registry = StyleRegistry.getStyleRegistry();
    String[] stores = registry.getAvailableStoreNames();
    if (stores != null) {
        for (int i = 0; i < stores.length; i++) {
            map.put(stores[i], registry.getStore(stores[i]));
            list.add(stores[i]);
        }
    }
    Lookup.Template template = new Lookup.Template(IStyleStore.class);
    Lookup.Result result = FreeHEPLookup.instance().lookup(template);
    for (Iterator i = result.allInstances().iterator(); i.hasNext(); ) {
        IStyleStore store = (IStyleStore) i.next();
        if (store != null && !map.containsValue(store)) {
            map.put(store.getStoreName(), store);
            list.add(store.getStoreName());
        }
    }
    DefaultComboBoxModel model = new DefaultComboBoxModel(list);
    storeList.setModel(model);
}
Example 94
Project: freemarker-support-for-netbeans-master  File: FTLPanel.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    embeddedMime = new javax.swing.JComboBox();
    label1 = new javax.swing.JLabel();
    embeddedMime.setEditable(true);
    embeddedMime.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "text/html", "text/css", "text/javascript", "text/plain" }));
    // NOI18N
    org.openide.awt.Mnemonics.setLocalizedText(label1, org.openide.util.NbBundle.getMessage(FTLPanel.class, "FTLPanel.label1.text"));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(label1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(embeddedMime, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(148, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(label1).addComponent(embeddedMime, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addContainerGap(147, Short.MAX_VALUE)));
}
Example 95
Project: geotoolkit-master  File: JUOMPane.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    guiLabel = new JLabel();
    jcb_uom = new JComboBox();
    setOpaque(false);
    // NOI18N
    guiLabel.setText(MessageBundle.format("unit"));
    jcb_uom.setModel(new DefaultComboBoxModel(new String[] { "Pixels", "Meters", "Feet" }));
    jcb_uom.addItemListener(new ItemListener() {

        public void itemStateChanged(ItemEvent evt) {
            jcb_uomItemStateChanged(evt);
        }
    });
    GroupLayout layout = new GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(guiLabel).addPreferredGap(ComponentPlacement.RELATED).addComponent(jcb_uom, 0, 63, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout.createParallelGroup(Alignment.BASELINE).addComponent(guiLabel).addComponent(jcb_uom, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)));
}
Example 96
Project: geotools-tike-master  File: JGeomPane.java View source code
/** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
    guiBox = new org.geotools.gui.swing.style.sld.JGeomBox();
    lbl = new javax.swing.JLabel();
    setOpaque(false);
    guiBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    guiBox.setOpaque(false);
    // NOI18N
    java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("org/geotools/gui/swing/style/sld/Bundle");
    // NOI18N
    lbl.setText(bundle.getString("geometry"));
    lbl.setEnabled(false);
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createSequentialGroup().add(lbl).addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED).add(guiBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)));
    layout.setVerticalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING).add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE).add(lbl).add(guiBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)));
}
Example 97
Project: GitToolBox-master  File: GtForm.java View source code
@Override
public void init() {
    presentationMode.setRenderer(new ListCellRendererWrapper<StatusPresenter>() {

        @Override
        public void customize(JList jList, StatusPresenter presenter, int index, boolean isSelected, boolean hasFocus) {
            setText(presenter.getLabel());
        }
    });
    presentationMode.setModel(new DefaultComboBoxModel(StatusPresenters.values()));
    presentationMode.addActionListener(new ActionListener() {

        @Override
        public void actionPerformed(ActionEvent e) {
            StatusPresenter presenter = getPresenter();
            presentationStatusBarPreview.setText(getStatusBarPreview(presenter));
            presentationProjectViewPreview.setText(getProjectViewPreview(presenter));
        }
    });
    showProjectViewStatusCheckBox.addItemListener(new ItemListener() {

        @Override
        public void itemStateChanged(ItemEvent e) {
            onProjectViewStatusChange();
        }
    });
    showLocationPathCheckBox.addItemListener(new ItemListener() {

        @Override
        public void itemStateChanged(ItemEvent e) {
            onProjectViewStatusChange();
        }
    });
}
Example 98
Project: HermesJMS-master  File: GeneralPreferences.java View source code
public void setConfig(HermesConfig config) throws HermesException {
    spinner.getModel().setValue(config.getMaxMessagesInBrowserPane());
    spinner_1.getModel().setValue(config.getAutoBrowseRefreshRate());
    spinner_2.getModel().setValue(config.getQueueBrowseConsumerTimeout().intValue());
    Vector<String> sessionNames = new Vector<String>();
    for (SessionConfig sessionConfig : HermesBrowser.getBrowser().getConfigDAO().getAllSessions(config)) {
        sessionNames.add(sessionConfig.getId());
    }
    comboBox.setModel(new DefaultComboBoxModel(sessionNames));
    comboBox.getModel().setSelectedItem(config.getMessageStoreMessageFactory());
    deleteBatchSpinner.setValue(config.getDeleteBatch());
}
Example 99
Project: hypergraphdb-android-master  File: SwingDefaultComboBoxModelPersistenceDelegate.java View source code
@Override
@SuppressWarnings({ "nls", "boxing" })
protected void initialize(Class<?> type, Object oldInstance, Object newInstance, Encoder enc) {
    super.initialize(type, oldInstance, newInstance, enc);
    DefaultComboBoxModel model = (DefaultComboBoxModel) oldInstance;
    int count = model.getSize();
    Expression getterExp = null;
    for (int i = 0; i < count; i++) {
        getterExp = new Expression(model, "getElementAt", new Object[] { i });
        try {
            // Calculate the old value of the property
            Object oldVal = getterExp.getValue();
            // Write the getter expression to the encoder
            enc.writeExpression(getterExp);
            // Get the target value that exists in the new environment
            Object targetVal = enc.get(oldVal);
            // Get the current property value in the new environment
            Object newVal = null;
            try {
                newVal = new Expression(newInstance, "getElementAt", new Object[] { i }).getValue();
            } catch (IndexOutOfBoundsException ex) {
            }
            /*
				 * Make the target value and current property value equivalent
				 * in the new environment
				 */
            Statement setterStm = null;
            if (null == targetVal) {
                if (null != newVal) {
                    // Set to null
                    setterStm = new Statement(oldInstance, "addElement", new Object[] { null });
                    enc.writeStatement(setterStm);
                }
            } else {
                PersistenceDelegate pd = enc.getPersistenceDelegate(targetVal.getClass());
                if (!pd.mutatesTo(targetVal, newVal)) {
                    setterStm = new Statement(oldInstance, "addElement", new Object[] { oldVal });
                    enc.writeStatement(setterStm);
                }
            }
        } catch (Exception ex) {
            enc.getExceptionListener().exceptionThrown(ex);
        }
    }
}
Example 100
Project: IBAdataAnalysis-master  File: FrameConfigLang.java View source code
/**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    jComboBoxLang = new javax.swing.JComboBox();
    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
    jLabel1.setText("Please choose your language :");
    jComboBoxLang.setModel(new javax.swing.DefaultComboBoxModel(getLanguages()));
    if (languageName != null) {
        String[] availableLang = getLanguages();
        for (int i = 0; i < availableLang.length; i++) {
            if (availableLang[i].equals(languageName)) {
                jComboBoxLang.setSelectedIndex(i);
            }
        }
    }
    jComboBoxLang.addActionListener(new java.awt.event.ActionListener() {

        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jComboBoxLangActionPerformed(evt);
        }
    });
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(34, 34, 34).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jComboBoxLang, javax.swing.GroupLayout.PREFERRED_SIZE, 176, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jLabel1)).addGap(0, 32, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jLabel1).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jComboBoxLang, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
    pack();
}
Example 101
Project: igv-master  File: GroupTracksMenuAction.java View source code
public void run() {
    final AttributeSelectionDialog dlg = new AttributeSelectionDialog(mainFrame.getMainFrame(), true);
    List<String> attributeKeys = AttributeManager.getInstance().getVisibleAttributes();
    // Sorting disabled -- order will match the order in the panel.  If sorting is desired make a copy
    // of the array so the panel is not affected.
    //if (attributeKeys != null) {
    //    Collections.sort(attributeKeys,
    //            AttributeManager.getInstance().getAttributeComparator());
    //}
    ArrayList<String> selections = new ArrayList(attributeKeys);
    selections.add(0, "None");
    String[] selArray = selections.toArray(new String[] {});
    dlg.setModel(new javax.swing.DefaultComboBoxModel(selArray));
    dlg.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
    String currentSelection = IGV.getInstance().getGroupByAttribute();
    if (currentSelection == null) {
        dlg.setSelectedIndex(0);
    } else {
        dlg.setSelectedItem(currentSelection);
    }
    dlg.setVisible(true);
    if (!dlg.isCanceled()) {
        int selIndex = dlg.getSelectedIndex();
        String selectedAttribute = (selIndex == 0 ? null : selArray[selIndex]);
        IGV.getInstance().setGroupByAttribute(selectedAttribute);
        mainFrame.doRefresh();
    }
}