Example usage for javax.swing GroupLayout createSequentialGroup

List of usage examples for javax.swing GroupLayout createSequentialGroup

Introduction

In this page you can find the example usage for javax.swing GroupLayout createSequentialGroup.

Prototype

public SequentialGroup createSequentialGroup() 

Source Link

Document

Creates and returns a SequentialGroup .

Usage

From source file:org.nekorp.workflow.desktop.view.EventoObservacionesView.java

/**
 * 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.//from   w w w . ja v a 2  s  .c  o m
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    jToolBar1 = new javax.swing.JToolBar();
    evidencias = new javax.swing.JButton();
    borrar = new javax.swing.JButton();
    jLabel1 = new javax.swing.JLabel();
    responsable = new org.nekorp.workflow.desktop.view.binding.SimpleBindableJTextField();
    fechaCreacionLabel = new org.nekorp.workflow.desktop.view.binding.FormatedJLabel(dateConverter);
    jLabel2 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    jScrollPane2 = new org.nekorp.workflow.desktop.view.resource.imp.MouseFreeJScrollPane();
    observaciones = new org.nekorp.workflow.desktop.view.binding.SimpleBindableJTextArea();

    setBackground(new java.awt.Color(255, 255, 255));
    setMaximumSize(new java.awt.Dimension(32767, 65));
    setPreferredSize(new java.awt.Dimension(425, 65));

    jToolBar1.setBackground(new java.awt.Color(255, 255, 255));
    jToolBar1.setFloatable(false);
    jToolBar1.setRollover(true);

    evidencias.setBackground(new java.awt.Color(255, 255, 255));
    evidencias.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    evidencias.setText("Evidencias");
    evidencias.setFocusable(false);
    evidencias.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
    evidencias.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
    evidencias.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            evidenciasActionPerformed(evt);
        }
    });
    jToolBar1.add(evidencias);

    borrar.setBackground(new java.awt.Color(255, 255, 255));
    borrar.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    borrar.setText("Borrar");
    borrar.setFocusable(false);
    borrar.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
    borrar.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
    borrar.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            borrarActionPerformed(evt);
        }
    });
    jToolBar1.add(borrar);

    jLabel1.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jLabel1.setText("Responsable:");

    responsable.setBackground(new java.awt.Color(224, 230, 230));
    responsable.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    responsable.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(224, 230, 230), 4));

    fechaCreacionLabel.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    fechaCreacionLabel.setText("12/12/2012");

    jLabel2.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jLabel2.setText("Creado el dia:");

    jLabel3.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jLabel3.setText("Observaciones:");

    jScrollPane2.setBorder(null);
    jScrollPane2.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
    jScrollPane2.setWheelScrollingEnabled(false);

    observaciones.setBackground(new java.awt.Color(224, 230, 230));
    observaciones.setColumns(20);
    observaciones.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    observaciones.setLineWrap(true);
    observaciones.setRows(2);
    jScrollPane2.setViewportView(observaciones);

    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, false)
                            .addComponent(jLabel3, javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(layout.createSequentialGroup()
                                    .addComponent(responsable, javax.swing.GroupLayout.DEFAULT_SIZE, 46,
                                            Short.MAX_VALUE)
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(jLabel2)
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(fechaCreacionLabel, javax.swing.GroupLayout.PREFERRED_SIZE,
                                            100, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(jToolBar1, javax.swing.GroupLayout.PREFERRED_SIZE,
                                            javax.swing.GroupLayout.DEFAULT_SIZE,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(jScrollPane2))
                    .addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel1)
                                    .addComponent(responsable, javax.swing.GroupLayout.PREFERRED_SIZE, 20,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(fechaCreacionLabel).addComponent(jLabel2))
                            .addComponent(jToolBar1, 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(jLabel3).addComponent(jScrollPane2,
                                    javax.swing.GroupLayout.PREFERRED_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))));
}

From source file:misc.TextAreaPrintingDemo.java

/** This method is called from within the constructor to
 * initialize the form./*from w  w w  .  j  a va2s  .  c  om*/
 * 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() {
    jScrollPane1 = new javax.swing.JScrollPane();
    text = new javax.swing.JTextArea();
    headerLabel = new javax.swing.JLabel();
    headerField = new javax.swing.JTextField();
    footerLabel = new javax.swing.JLabel();
    footerField = new javax.swing.JTextField();
    interactiveCheck = new javax.swing.JCheckBox();
    printButton = new javax.swing.JButton();
    guideText = new javax.swing.JTextArea();
    backgroundCheck = new javax.swing.JCheckBox();

    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    setTitle("TextAreaPrintingDemo");
    text.setColumns(20);
    text.setRows(5);
    text.setMargin(new java.awt.Insets(2, 2, 2, 2));
    jScrollPane1.setViewportView(text);

    headerLabel.setText("Header");

    headerField.setText("William Shakespeare");

    footerLabel.setText("Footer");

    footerField.setText("Page {0}");

    interactiveCheck.setSelected(true);
    interactiveCheck.setText("Show Progress Dialog");
    interactiveCheck.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));

    printButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("images/print.png")));
    printButton.setText("Print!");
    printButton.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            print(evt);
        }
    });

    guideText.setColumns(20);
    guideText.setEditable(false);
    guideText.setLineWrap(true);
    guideText.setRows(5);
    guideText.setWrapStyleWord(true);
    guideText.setOpaque(false);

    backgroundCheck.setSelected(true);
    backgroundCheck.setText("Print in Background");
    backgroundCheck.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));

    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, false)
                            .addComponent(guideText)
                            .addGroup(layout.createSequentialGroup().addGroup(layout
                                    .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                    .addComponent(backgroundCheck, javax.swing.GroupLayout.DEFAULT_SIZE,
                                            javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                    .addComponent(interactiveCheck, javax.swing.GroupLayout.PREFERRED_SIZE, 159,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(
                                            printButton, javax.swing.GroupLayout.DEFAULT_SIZE,
                                            javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(layout.createSequentialGroup().addGroup(layout
                                    .createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                    .addComponent(footerLabel, javax.swing.GroupLayout.Alignment.LEADING,
                                            javax.swing.GroupLayout.DEFAULT_SIZE,
                                            javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                    .addComponent(headerLabel, javax.swing.GroupLayout.Alignment.LEADING,
                                            javax.swing.GroupLayout.PREFERRED_SIZE, 74,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addGroup(layout
                                            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING,
                                                    false)
                                            .addComponent(footerField).addComponent(headerField,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE, 209,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addGap(15, 15, 15)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 343, Short.MAX_VALUE)
                    .addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout
                    .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.TRAILING,
                            javax.swing.GroupLayout.DEFAULT_SIZE, 403, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                            .addComponent(guideText, javax.swing.GroupLayout.DEFAULT_SIZE, 260, Short.MAX_VALUE)
                            .addGap(18, 18, 18)
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(headerLabel).addComponent(headerField,
                                            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(footerLabel).addComponent(footerField,
                                            javax.swing.GroupLayout.PREFERRED_SIZE,
                                            javax.swing.GroupLayout.DEFAULT_SIZE,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGap(27, 27, 27)
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(layout.createSequentialGroup()
                                            .addComponent(interactiveCheck,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE, 23,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                            .addComponent(backgroundCheck,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE, 23,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addComponent(printButton, javax.swing.GroupLayout.PREFERRED_SIZE, 52,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addContainerGap()));
    pack();
}

From source file:view.ViewReportUI.java

/**
 * 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./*from ww  w  .java 2  s.com*/
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    jScrollPane1 = new javax.swing.JScrollPane();
    jTable1 = new javax.swing.JTable();
    jButton1 = new javax.swing.JButton();
    jPanel1 = new javax.swing.JPanel();

    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    setTitle(" Expense Report");
    setResizable(false);
    addWindowListener(new java.awt.event.WindowAdapter() {
        public void windowClosing(java.awt.event.WindowEvent evt) {
            formWindowClosing(evt);
        }
    });

    String col[] = { "Amount", "Store", "Date of Purchase", "Date Addded" };
    DefaultTableModel tableModel = new DefaultTableModel(col, 0) {
        public boolean isCellEditable(int row, int column) {
            return false;//This causes all cells to be not editable
        }
    };
    jTable1.setModel(tableModel);
    for (model.InvoiceModel in : myInvoice) {

        Object[] objs = { "$" + in.getAmount(), in.getStore(), in.getDateOfPurchase(), in.getAddedDate() };
        tableModel.addRow(objs);
    }

    jTable1.setGridColor(Color.gray);
    jTable1.getTableHeader().setBackground(new Color(102, 178, 255));
    jTable1.addMouseListener(new java.awt.event.MouseAdapter() {
        public void mouseClicked(java.awt.event.MouseEvent evt) {
            jTable1MouseClicked(evt);
        }
    });
    jScrollPane1.setViewportView(jTable1);

    jButton1.setText("Close");

    jPanel1.setLayout(new java.awt.BorderLayout());
    PieDataset dataset = createDataset();
    // based on the dataset we create the chart
    JFreeChart chart = createChart(dataset, "Hello");
    // we put the chart into a panel
    this.chartPanel = new ChartPanel(chart);
    // default size
    chartPanel.setPreferredSize(new Dimension(500, 270));
    //        this.jPanel1.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));
    //
    System.out.println(chartPanel == null);
    jPanel1.add(chartPanel);
    jPanel1.validate();

    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                    layout.createSequentialGroup()
                            .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jButton1).addGap(242, 242, 242))
            .addGroup(layout.createSequentialGroup().addGap(15, 15, 15)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 536,
                                    Short.MAX_VALUE)
                            .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addContainerGap(14, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup().addContainerGap()
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 293,
                            javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGap(18, 18, 18)
                    .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE,
                            javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jButton1)
                    .addGap(20, 20, 20)));

    pack();
    setLocationRelativeTo(null);
}

From source file:org.nekorp.workflow.desktop.view.EventoDiagnosticoView.java

/**
 * 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.//w ww. jav a  2 s  . c  o  m
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    jToolBar1 = new javax.swing.JToolBar();
    evidencias = new javax.swing.JButton();
    borrar = new javax.swing.JButton();
    jLabel1 = new javax.swing.JLabel();
    responsable = new org.nekorp.workflow.desktop.view.binding.SimpleBindableJTextField();
    fechaCreacionLabel = new org.nekorp.workflow.desktop.view.binding.FormatedJLabel(dateConverter);
    jLabel2 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    jScrollPane2 = new org.nekorp.workflow.desktop.view.resource.imp.MouseFreeJScrollPane();
    diagnostico = new org.nekorp.workflow.desktop.view.binding.SimpleBindableJTextArea();

    setBackground(new java.awt.Color(255, 255, 255));
    setMaximumSize(new java.awt.Dimension(32767, 65));

    jToolBar1.setBorder(null);
    jToolBar1.setFloatable(false);
    jToolBar1.setRollover(true);

    evidencias.setBackground(new java.awt.Color(255, 255, 255));
    evidencias.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    evidencias.setText("Evidencias");
    evidencias.setFocusable(false);
    evidencias.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
    evidencias.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
    evidencias.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            evidenciasActionPerformed(evt);
        }
    });
    jToolBar1.add(evidencias);

    borrar.setBackground(new java.awt.Color(255, 255, 255));
    borrar.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    borrar.setText("Borrar");
    borrar.setFocusable(false);
    borrar.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
    borrar.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
    borrar.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            borrarActionPerformed(evt);
        }
    });
    jToolBar1.add(borrar);

    jLabel1.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jLabel1.setText("Responsable:");

    responsable.setBackground(new java.awt.Color(224, 230, 230));
    responsable.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    responsable.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(224, 230, 230), 4));

    fechaCreacionLabel.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    fechaCreacionLabel.setText("12/12/2012");

    jLabel2.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jLabel2.setText("Creado el dia:");

    jLabel3.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jLabel3.setText("Diagnostico:");

    jScrollPane2.setBorder(null);
    jScrollPane2.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
    jScrollPane2.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    jScrollPane2.setWheelScrollingEnabled(false);

    diagnostico.setBackground(new java.awt.Color(224, 230, 230));
    diagnostico.setColumns(20);
    diagnostico.setFont(new java.awt.Font("Arial", 0, 11)); // NOI18N
    diagnostico.setLineWrap(true);
    diagnostico.setRows(2);
    diagnostico.setBorder(null);
    jScrollPane2.setViewportView(diagnostico);

    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, false)
                            .addComponent(jLabel3, javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(layout.createSequentialGroup()
                                    .addComponent(responsable, javax.swing.GroupLayout.DEFAULT_SIZE, 59,
                                            Short.MAX_VALUE)
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(jLabel2)
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(fechaCreacionLabel, javax.swing.GroupLayout.PREFERRED_SIZE,
                                            100, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addComponent(jToolBar1, javax.swing.GroupLayout.PREFERRED_SIZE,
                                            javax.swing.GroupLayout.DEFAULT_SIZE,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(jScrollPane2))
                    .addContainerGap()));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel1)
                                    .addComponent(responsable, javax.swing.GroupLayout.PREFERRED_SIZE, 20,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(fechaCreacionLabel).addComponent(jLabel2))
                            .addComponent(jToolBar1, 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(jLabel3).addComponent(jScrollPane2,
                                    javax.swing.GroupLayout.PREFERRED_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))));
}

From source file:userInterface.cdcRole.OverviewJPanel.java

@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    jPanel1 = new javax.swing.JPanel();
    jComboBox1 = new javax.swing.JComboBox();
    jScrollPane1 = new javax.swing.JScrollPane();
    jTable1 = new javax.swing.JTable();
    jButton2 = new javax.swing.JButton();
    jScrollPane2 = new javax.swing.JScrollPane();
    jTable2 = new javax.swing.JTable();
    jButton1 = new javax.swing.JButton();

    setBackground(new java.awt.Color(255, 255, 255));

    jPanel1.setLayout(new java.awt.CardLayout());

    jComboBox1.setModel(/*from ww w  .j  av a  2 s .com*/
            new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    jComboBox1.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jComboBox1ActionPerformed(evt);
        }
    });

    jTable1.setModel(
            new javax.swing.table.DefaultTableModel(new Object[][] { { null } }, new String[] { "Hospials" }));
    jScrollPane1.setViewportView(jTable1);

    jButton2.setText(">>");
    jButton2.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton2ActionPerformed(evt);
        }
    });

    jTable2.setModel(new javax.swing.table.DefaultTableModel(new Object[][] { { null, null } },
            new String[] { "Vaccine", "Inventory" }));
    jScrollPane2.setViewportView(jTable2);

    jButton1.setText(">>");
    jButton1.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton1ActionPerformed(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)
                            .addGroup(layout.createSequentialGroup().addGap(618, 618, 618).addComponent(
                                    jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, 176,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(layout.createSequentialGroup().addGap(43, 43, 43)
                                    .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, 695,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addGap(18, 18, 18).addComponent(jButton2).addGap(18, 18, 18)
                                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 191,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addGap(18, 18, 18).addComponent(jButton1).addGap(18, 18, 18)
                                    .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 289,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addContainerGap(1304, Short.MAX_VALUE)));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup().addGap(11, 11, 11)
                    .addComponent(jComboBox1, 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(48, 48, 48)
                                    .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, 468,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addGap(46, 46, 46))
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                    .addGroup(layout
                                            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                                                    layout.createSequentialGroup()
                                                            .addComponent(jButton2,
                                                                    javax.swing.GroupLayout.PREFERRED_SIZE, 160,
                                                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                                                            .addGap(194, 194, 194))
                                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                                                    layout.createSequentialGroup()
                                                            .addComponent(jButton1,
                                                                    javax.swing.GroupLayout.PREFERRED_SIZE, 167,
                                                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                                                            .addGap(193, 193, 193))))))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                    layout.createSequentialGroup().addContainerGap()
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 533,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 533,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addContainerGap()));
}

From source file:UserInterface.VaccineManufacturer.TrackVaccineWastage.java

/**
 * 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.// w w w.  j a  va 2  s. co  m
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    panelDescriptionJLabel = new javax.swing.JLabel();
    jScrollPane1 = new javax.swing.JScrollPane();
    vaccineJTable = new javax.swing.JTable();
    viewJLabel = new javax.swing.JLabel();
    jScrollPane2 = new javax.swing.JScrollPane();
    wastageJTable = new javax.swing.JTable();
    backJButton = new javax.swing.JButton();
    clickJButton = new javax.swing.JButton();
    listJLabel = new javax.swing.JLabel();
    totalWastageJLabel = new javax.swing.JLabel();
    totalWastageJTextField = new javax.swing.JTextField();
    summarizeJButton = new javax.swing.JButton();

    panelDescriptionJLabel.setFont(new java.awt.Font("Arial", 1, 14)); // NOI18N
    panelDescriptionJLabel.setText("Vaccine Wastage Record");

    vaccineJTable.setFont(new java.awt.Font("Arial", 0, 12)); // NOI18N
    vaccineJTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object[][] { { null, null }, { null, null }, { null, null }, { null, null } },
            new String[] { "Vaccines", "Disease" }));
    vaccineJTable.setRowHeight(25);
    jScrollPane1.setViewportView(vaccineJTable);

    viewJLabel.setFont(new java.awt.Font("Arial", 1, 12)); // NOI18N
    viewJLabel.setText("View Wastage Details");

    wastageJTable.setFont(new java.awt.Font("Arial", 0, 12)); // NOI18N
    wastageJTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object[][] { { null, null }, { null, null }, { null, null }, { null, null } },
            new String[] { "Manufacturing Batch", "Wasted Quantity" }));
    wastageJTable.setRowHeight(25);
    jScrollPane2.setViewportView(wastageJTable);

    backJButton.setFont(new java.awt.Font("Arial", 0, 12)); // NOI18N
    backJButton.setText("<< Back");
    backJButton.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            backJButtonActionPerformed(evt);
        }
    });

    clickJButton.setFont(new java.awt.Font("Arial", 0, 12)); // NOI18N
    clickJButton.setText("Click Here!");
    clickJButton.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            clickJButtonActionPerformed(evt);
        }
    });

    listJLabel.setFont(new java.awt.Font("Arial", 1, 12)); // NOI18N
    listJLabel.setText("List of vaccines:");

    totalWastageJLabel.setFont(new java.awt.Font("Arial", 1, 12)); // NOI18N
    totalWastageJLabel.setText("Total Wastage");

    totalWastageJTextField.setFont(new java.awt.Font("Arial", 0, 12)); // NOI18N

    summarizeJButton.setFont(new java.awt.Font("Arial", 0, 12)); // NOI18N
    summarizeJButton.setText("Summarize graphically");
    summarizeJButton.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            summarizeJButtonActionPerformed(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)
                    .addGroup(layout.createSequentialGroup().addGroup(layout
                            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 817,
                                    Short.MAX_VALUE)
                            .addGroup(layout.createSequentialGroup().addGroup(layout
                                    .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(panelDescriptionJLabel)
                                    .addGroup(layout.createSequentialGroup().addComponent(viewJLabel)
                                            .addGap(18, 18, 18).addComponent(clickJButton))
                                    .addComponent(listJLabel)
                                    .addGroup(layout.createSequentialGroup()
                                            .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE,
                                                    542, javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addGap(31, 31, 31).addComponent(summarizeJButton,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE, 201,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE)))
                                    .addGap(0, 0, Short.MAX_VALUE)))
                            .addContainerGap())
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                            .addGap(0, 0, Short.MAX_VALUE).addComponent(totalWastageJLabel).addGap(31, 31, 31)
                            .addComponent(totalWastageJTextField, javax.swing.GroupLayout.PREFERRED_SIZE, 92,
                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addGap(121, 121, 121))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                            layout.createSequentialGroup().addComponent(backJButton)
                                    .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))));
    layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup().addContainerGap().addComponent(panelDescriptionJLabel)
                    .addGap(24, 24, 24).addComponent(listJLabel)
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(layout.createSequentialGroup()
                                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 127,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addGap(28, 28, 28))
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                                    layout.createSequentialGroup().addComponent(summarizeJButton).addGap(69, 69,
                                            69)))
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(viewJLabel).addComponent(clickJButton))
                    .addGap(18, 18, 18)
                    .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 127,
                            javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGap(18, 18, 18)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(totalWastageJLabel).addComponent(totalWastageJTextField,
                                    javax.swing.GroupLayout.PREFERRED_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGap(30, 30, 30).addComponent(backJButton).addContainerGap(23, Short.MAX_VALUE)));
}

From source file:com.polivoto.vistas.Editor.java

/**
 * 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./*from w w w  . ja v a  2  s.c o m*/
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    jFrame1 = new javax.swing.JFrame();
    jColorChooser1 = new javax.swing.JColorChooser();
    jButton1 = new javax.swing.JButton();
    jButton2 = new javax.swing.JButton();
    jPanel1 = new javax.swing.JPanel();
    jTabbedPane = new javax.swing.JTabbedPane();

    jButton1.setText("Aceptar");
    jButton1.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            jButton1ActionPerformed(evt);
        }
    });

    jButton2.setText("Cancelar");

    javax.swing.GroupLayout jFrame1Layout = new javax.swing.GroupLayout(jFrame1.getContentPane());
    jFrame1.getContentPane().setLayout(jFrame1Layout);
    jFrame1Layout.setHorizontalGroup(jFrame1Layout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                    jFrame1Layout.createSequentialGroup().addGap(0, 0, Short.MAX_VALUE).addComponent(
                            jColorChooser1, javax.swing.GroupLayout.PREFERRED_SIZE,
                            javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jFrame1Layout.createSequentialGroup()
                    .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jButton2).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                    .addComponent(jButton1).addContainerGap()));
    jFrame1Layout.setVerticalGroup(jFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jFrame1Layout.createSequentialGroup()
                    .addComponent(jColorChooser1, javax.swing.GroupLayout.PREFERRED_SIZE,
                            javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGap(18, 18, 18)
                    .addGroup(jFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jButton1).addComponent(jButton2))
                    .addGap(0, 0, Short.MAX_VALUE)));

    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);

    jPanel1.setBackground(new java.awt.Color(255, 255, 255));

    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(jTabbedPane, javax.swing.GroupLayout.DEFAULT_SIZE, 742, Short.MAX_VALUE)
                    .addContainerGap()));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup().addContainerGap()
                    .addComponent(jTabbedPane, javax.swing.GroupLayout.DEFAULT_SIZE, 593, Short.MAX_VALUE)
                    .addContainerGap()));

    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().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));

    pack();
}

From source file:Main.java

public Main() {
    setDefaultCloseOperation(EXIT_ON_CLOSE);

    Container pane = getContentPane();
    GroupLayout gl = new GroupLayout(pane);
    pane.setLayout(gl);//from   w  w  w  .j a  v  a 2s  . co  m

    gl.setAutoCreateGaps(true);
    gl.setAutoCreateContainerGaps(true);

    JButton btn = new JButton("Switch");
    btn.addActionListener(new ActionListener() {
        @Override
        public void actionPerformed(ActionEvent e) {
            for (int i = 1; i < 9; i++) {
                labels[i].setVisible(!labels[i].isVisible());
            }
        }
    });

    gl.setHonorsVisibility(false);

    SequentialGroup seqGroup = gl.createSequentialGroup();
    gl.setHorizontalGroup(seqGroup);
    seqGroup.addComponent(btn);
    seqGroup.addPreferredGap(ComponentPlacement.UNRELATED, 10, 10);
    for (int i = 0; i < 10; i++) {
        seqGroup.addComponent(labels[i]);
        seqGroup.addPreferredGap(ComponentPlacement.UNRELATED, 10, 10);
    }
    ParallelGroup parGroup = gl.createParallelGroup();
    gl.setVerticalGroup(parGroup);
    parGroup.addComponent(btn);

    for (int i = 0; i < 10; i++) {
        parGroup.addComponent(labels[i]);
    }
    pack();
}

From source file:frames.Screen2.java

/**
 * 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./*  w  w w.j a  v a2 s.c o  m*/
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    jPanel1 = new javax.swing.JPanel();
    Exit = new javax.swing.JButton();
    jScrollPane1 = new javax.swing.JScrollPane();
    jTable1 = new javax.swing.JTable();
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    DateTF = new javax.swing.JTextField();
    Piechart = new javax.swing.JButton();

    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    setBackground(new java.awt.Color(153, 0, 153));

    jPanel1.setBackground(new java.awt.Color(22, 110, 22));

    Exit.setBackground(new java.awt.Color(255, 0, 0));
    Exit.setFont(new java.awt.Font("Tahoma", 1, 18)); // NOI18N
    Exit.setForeground(new java.awt.Color(255, 255, 255));
    Exit.setText("Exit");
    Exit.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            ExitActionPerformed(evt);
        }
    });

    jTable1.setBackground(java.awt.Color.lightGray);
    jTable1.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(51, 0, 0), 2));
    jTable1.setModel(new javax.swing.table.DefaultTableModel(
            new Object[][] { { "process1", new Long(9729719), new Integer(267839), "TCP", "Listen" },
                    { "process2", new Long(5930022), new Integer(356118), "TCP", "Established" },
                    { "process3", new Long(12648669), new Integer(154132), "TCP", "Listen" },
                    { "process4", new Long(2806211), new Integer(131547), "UDP", "Time_Wait" } },
            new String[] { "Process", "MemoryInfo", "IoInfo", "Protocol", "State" }) {
        Class[] types = new Class[] { java.lang.String.class, java.lang.Long.class, java.lang.Integer.class,
                java.lang.String.class, java.lang.String.class };

        public Class getColumnClass(int columnIndex) {
            return types[columnIndex];
        }
    });
    jTable1.setGridColor(new java.awt.Color(51, 0, 0));
    jScrollPane1.setViewportView(jTable1);

    jLabel1.setBackground(new java.awt.Color(255, 51, 0));
    jLabel1.setFont(new java.awt.Font("Monotype Corsiva", 3, 36)); // NOI18N
    jLabel1.setForeground(java.awt.Color.white);
    jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
    jLabel1.setText("Metrics Collector");

    jLabel2.setBackground(new java.awt.Color(255, 255, 51));
    jLabel2.setForeground(new java.awt.Color(157, 255, 101));
    jLabel2.setText("Date");

    DateTF.setEditable(false);
    DateTF.setBackground(new java.awt.Color(255, 153, 153));
    DateTF.setFont(new java.awt.Font("Tahoma", 3, 10)); // NOI18N
    DateTF.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            DateTFActionPerformed(evt);
        }
    });

    Piechart.setBackground(new java.awt.Color(204, 0, 51));
    Piechart.setFont(new java.awt.Font("Tahoma", 1, 8)); // NOI18N
    Piechart.setForeground(new java.awt.Color(204, 255, 255));
    Piechart.setText("Piechart");
    Piechart.addActionListener(new java.awt.event.ActionListener() {
        public void actionPerformed(java.awt.event.ActionEvent evt) {
            PiechartActionPerformed(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()
                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel1Layout.createSequentialGroup().addGap(143, 143, 143).addComponent(
                                    jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 267,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(jPanel1Layout.createSequentialGroup().addGap(101, 101, 101).addComponent(
                                    jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 379,
                                    javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addContainerGap(118, Short.MAX_VALUE))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
                    .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                                    jPanel1Layout.createSequentialGroup().addComponent(jLabel2)
                                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                            .addComponent(DateTF, javax.swing.GroupLayout.PREFERRED_SIZE, 69,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addGap(23, 23, 23))
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
                                    jPanel1Layout.createSequentialGroup()
                                            .addComponent(Exit, javax.swing.GroupLayout.PREFERRED_SIZE, 90,
                                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addGap(44, 44, 44))))
            .addGroup(jPanel1Layout.createSequentialGroup().addGap(251, 251, 251).addComponent(Piechart)
                    .addGap(0, 0, Short.MAX_VALUE)));
    jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
                    .addGap(19, 19, 19)
                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel2).addComponent(DateTF, javax.swing.GroupLayout.PREFERRED_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 28, Short.MAX_VALUE)
                    .addComponent(jLabel1).addGap(18, 18, 18)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 90,
                            javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGap(73, 73, 73).addComponent(Piechart).addGap(67, 67, 67).addComponent(Exit,
                            javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGap(19, 19, 19)));

    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().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));

    pack();
}

From source file:gui.images.ClassHubsPanel.java

/**
 * 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./*  ww w  . j  ava  2s. c o  m*/
 */
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

    pointTypePanel = new javax.swing.JPanel();
    jLabel1 = new javax.swing.JLabel();
    jLabel2 = new javax.swing.JLabel();
    jLabel3 = new javax.swing.JLabel();
    badHubsScrollPane = new javax.swing.JScrollPane();
    badHubsPanel = new javax.swing.JPanel();
    goodHubsScrollPane = new javax.swing.JScrollPane();
    goodHubsPanel = new javax.swing.JPanel();
    hubsScrollPane = new javax.swing.JScrollPane();
    hubsPanel = new javax.swing.JPanel();
    classNameLabel = new javax.swing.JLabel();

    javax.swing.GroupLayout pointTypePanelLayout = new javax.swing.GroupLayout(pointTypePanel);
    pointTypePanel.setLayout(pointTypePanelLayout);
    pointTypePanelLayout.setHorizontalGroup(pointTypePanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 378, Short.MAX_VALUE));
    pointTypePanelLayout.setVerticalGroup(pointTypePanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 262, Short.MAX_VALUE));

    jLabel1.setText("Bad Hubs:");

    jLabel2.setText("Good Hubs:");

    jLabel3.setText("Hubs:");

    badHubsScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS);

    javax.swing.GroupLayout badHubsPanelLayout = new javax.swing.GroupLayout(badHubsPanel);
    badHubsPanel.setLayout(badHubsPanelLayout);
    badHubsPanelLayout.setHorizontalGroup(badHubsPanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 335, Short.MAX_VALUE));
    badHubsPanelLayout.setVerticalGroup(badHubsPanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 100, Short.MAX_VALUE));

    badHubsScrollPane.setViewportView(badHubsPanel);

    goodHubsScrollPane
            .setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS);

    javax.swing.GroupLayout goodHubsPanelLayout = new javax.swing.GroupLayout(goodHubsPanel);
    goodHubsPanel.setLayout(goodHubsPanelLayout);
    goodHubsPanelLayout.setHorizontalGroup(goodHubsPanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 335, Short.MAX_VALUE));
    goodHubsPanelLayout.setVerticalGroup(goodHubsPanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 100, Short.MAX_VALUE));

    goodHubsScrollPane.setViewportView(goodHubsPanel);

    hubsScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS);

    javax.swing.GroupLayout hubsPanelLayout = new javax.swing.GroupLayout(hubsPanel);
    hubsPanel.setLayout(hubsPanelLayout);
    hubsPanelLayout.setHorizontalGroup(hubsPanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 335, Short.MAX_VALUE));
    hubsPanelLayout.setVerticalGroup(hubsPanelLayout
            .createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 100, Short.MAX_VALUE));

    hubsScrollPane.setViewportView(hubsPanel);

    classNameLabel.setText("class");

    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)
                            .addGroup(layout.createSequentialGroup().addContainerGap()
                                    .addComponent(classNameLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 113,
                                            javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(pointTypePanel, javax.swing.GroupLayout.PREFERRED_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGap(2, 2, 2)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 68,
                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 68,
                                    javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 70,
                                    javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(goodHubsScrollPane, javax.swing.GroupLayout.Alignment.TRAILING,
                                    javax.swing.GroupLayout.DEFAULT_SIZE, 304, Short.MAX_VALUE)
                            .addComponent(badHubsScrollPane, javax.swing.GroupLayout.Alignment.TRAILING,
                                    javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)
                            .addComponent(hubsScrollPane, javax.swing.GroupLayout.PREFERRED_SIZE, 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.LEADING)
                    .addGroup(layout.createSequentialGroup()
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                                    .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 112,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(badHubsScrollPane, javax.swing.GroupLayout.PREFERRED_SIZE, 0,
                                            Short.MAX_VALUE))
                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                                    .addComponent(jLabel2, javax.swing.GroupLayout.DEFAULT_SIZE, 113,
                                            Short.MAX_VALUE)
                                    .addComponent(goodHubsScrollPane, javax.swing.GroupLayout.DEFAULT_SIZE, 113,
                                            Short.MAX_VALUE))
                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 116,
                                            javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(hubsScrollPane, javax.swing.GroupLayout.PREFERRED_SIZE, 0,
                                            Short.MAX_VALUE)))
                    .addGroup(layout.createSequentialGroup().addComponent(classNameLabel).addGap(20, 20, 20)
                            .addComponent(pointTypePanel, javax.swing.GroupLayout.PREFERRED_SIZE,
                                    javax.swing.GroupLayout.DEFAULT_SIZE,
                                    javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addContainerGap()));
}