/*
 * NotPanel_n.java
 *
 * Created on November 22, 2003, 3:35 PM
 */

package usda.weru.weps.gui;

/**
 * This GUI object allows a user to enter the WEPS rum level comments for future references.
 * @author  manmohan
 */
public class NotPanel_n extends javax.swing.JFrame {
    
    /**
    * Default constructor for the Notes Panel GUI object that helps the user in entering
    * WEPS run notes to be retrieved and referred to by any future user.
    */
    public NotPanel_n() {
        initComponents();
    }
    
    /**
    * Single argument constructor for the Notes Panel GUI object that helps the 
    * user in entering WEPS run notes to be retrieved and referred to by any future 
    * user.
    * @param sTitle The title string for the parent frame of the GUI.
    */
    public NotPanel_n(java.lang.String sTitle) {
     this();
	 setTitle(sTitle);
    }
    
    /** 
     * 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() {

        JP_main = new javax.swing.JPanel();
        JB_Edit = new javax.swing.JButton();
        JNP_Clear = new javax.swing.JButton();
        JSP_text = new javax.swing.JScrollPane();
        JTA_text = new javax.swing.JTextArea();

        setDefaultCloseOperation(javax.swing.WindowConstants.DO_NOTHING_ON_CLOSE);
        setTitle("Notes Panel");
        addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosing(java.awt.event.WindowEvent evt) {
                exitForm(evt);
            }
        });

        JP_main.setToolTipText("JP_main : NotPanel");

        JB_Edit.setText("Edit");
        JB_Edit.setMaximumSize(new java.awt.Dimension(58, 23));
        JB_Edit.setMinimumSize(new java.awt.Dimension(58, 23));
        JB_Edit.setPreferredSize(new java.awt.Dimension(58, 23));
        JB_Edit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                JB_EditActionPerformed(evt);
            }
        });

        JNP_Clear.setText("Clear");
        JNP_Clear.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                JNP_ClearActionPerformed(evt);
            }
        });

        JSP_text.setToolTipText("NotPanel:text");

        JTA_text.setFont(new java.awt.Font("Monospaced", 0, 12)); // NOI18N
        JTA_text.setLineWrap(true);
        JTA_text.setToolTipText("NotPanel:text");
        JTA_text.setWrapStyleWord(true);
        JTA_text.setDisabledTextColor(new java.awt.Color(51, 51, 51));
        JTA_text.addFocusListener(new java.awt.event.FocusAdapter() {
            public void focusLost(java.awt.event.FocusEvent evt) {
                JTAText_FocusLost(evt);
            }
        });
        JSP_text.setViewportView(JTA_text);

        org.jdesktop.layout.GroupLayout JP_mainLayout = new org.jdesktop.layout.GroupLayout(JP_main);
        JP_main.setLayout(JP_mainLayout);
        JP_mainLayout.setHorizontalGroup(
            JP_mainLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(JP_mainLayout.createSequentialGroup()
                .addContainerGap()
                .add(JP_mainLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(JSP_text, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 219, Short.MAX_VALUE)
                    .add(JP_mainLayout.createSequentialGroup()
                        .add(JB_Edit, 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(JNP_Clear, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 66, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );

        JP_mainLayout.linkSize(new java.awt.Component[] {JB_Edit, JNP_Clear}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        JP_mainLayout.setVerticalGroup(
            JP_mainLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(JP_mainLayout.createSequentialGroup()
                .add(JSP_text, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 94, Short.MAX_VALUE)
                .add(5, 5, 5)
                .add(JP_mainLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(JB_Edit, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 18, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(JNP_Clear, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 18, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(JP_main, 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(JP_main, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
        );

        java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize();
        setBounds((screenSize.width-247)/2, (screenSize.height-155)/2, 247, 155);
    }// </editor-fold>//GEN-END:initComponents

    private void JB_EditActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_JB_EditActionPerformed
        JBEdit_actionPerformed(evt);
    }//GEN-LAST:event_JB_EditActionPerformed

    private void JNP_ClearActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_JNP_ClearActionPerformed
        JNPClear_actionPerformed(evt);
    }//GEN-LAST:event_JNP_ClearActionPerformed

    private void JTAText_FocusLost(java.awt.event.FocusEvent evt) {//GEN-FIRST:event_JTAText_FocusLost
        // Add your handling code here:
        JTAText_focusLost(evt);
    }//GEN-LAST:event_JTAText_FocusLost
   
    public void JTAText_focusLost(java.awt.event.FocusEvent event)
    {   // to do: code goes here.
			 
    }
    
    protected void JNPClear_actionPerformed(java.awt.event.ActionEvent evt)
    {
        
    }

    protected void JBEdit_actionPerformed(java.awt.event.ActionEvent evt)
    {
        
    }
    
    /** 
    * This method is called when the config panel is to be closed by hitting the 
    * "Red X" button of the window.
    * @param evt The window event generated when the " Red X " button on the window is hit. 
    */
    private void exitForm(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_exitForm
        System.exit(0);
    }//GEN-LAST:event_exitForm
    
  /**
   * This method is used if this dialog is rum as an independent application. If executed,
   * makes the GUI visible.
   * @param args These are the command line arguments passed to the main method.
   */
    public static void main(String args[]) {
        new NotPanel_n().setVisible(true);
    }
    
 
    
    // Variables declaration - do not modify//GEN-BEGIN:variables
    public javax.swing.JButton JB_Edit;
    public javax.swing.JButton JNP_Clear;
    public javax.swing.JPanel JP_main;
    public javax.swing.JScrollPane JSP_text;
    public javax.swing.JTextArea JTA_text;
    // End of variables declaration//GEN-END:variables
    
}
