import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

public class adresspanel extends JPanel {
   private JPanel labelPanel, fieldsPanel;
   private String labels[] =
                 { 
	            " ID : ",
	            " name : " ,
                " lastname :  " ,
                " adress :  " ,
                " city :  " ,
                " state :  " ,
                " zipcode :  " ,
                " country :  " ,
                " email :  " ,
                " home_phone :  " ,
                " work_phone :  " ,
                " mobile_phone :  " ,
                " fax :  " , 
                " web_adress :  " , 
                " home_adress) "};
   JTextField id, name, lastname, adress,     // alan nameleri
              city, state,zipcode,country,email,home_phone,
              work_phone,mobile_phone,fax,web_adress,home_adress;
   public adresspanel()
   {  // Label
      labelPanel = new JPanel();
      labelPanel.setLayout(
                       new GridLayout( labels.length, 1 ) );
      ImageIcon ii = new ImageIcon( "images/icon.jpg" );
      for ( int i = 0; i < labels.length; i++ )
         labelPanel.add( new JLabel( labels[ i ], ii, 0) );
      // TextField panel
      fieldsPanel = new JPanel();
      fieldsPanel.setLayout(
                        new GridLayout( labels.length, 1 ) );
      id = new JTextField( 20 );
      id.setEditable( false );
      fieldsPanel.add( id );
      name = new JTextField( 20 );
      fieldsPanel.add( name );
      lastname = new JTextField( 20 );
      fieldsPanel.add( lastname );
      adress = new JTextField( 20 );
      fieldsPanel.add( adress );
      city = new JTextField( 20 );
      fieldsPanel.add( city );
      state = new JTextField( 20 );
      fieldsPanel.add( state );
      zipcode = new JTextField( 20 );
      fieldsPanel.add( zipcode );
      country = new JTextField( 20 );
       fieldsPanel.add( country );
      email = new JTextField( 20 );
       fieldsPanel.add( email);
      home_phone = new JTextField( 20 );
      fieldsPanel.add( home_phone );
      work_phone = new JTextField( 20 );
      fieldsPanel.add( work_phone );
      mobile_phone = new JTextField( 20 );
      fieldsPanel.add( mobile_phone );
      fax = new JTextField( 20 );
      fieldsPanel.add( fax );
      web_adress = new JTextField( 20 );
      fieldsPanel.add( web_adress );
      home_adress = new JTextField( 20 );
      fieldsPanel.add( home_adress );
      setLayout( new GridLayout( 1, 2 ) );
      add( labelPanel );
      add( fieldsPanel );
   }
}


