source /home/ventana/source/elem_prop2.tcl

#--------------------------------------------------
# initialize and set variable for the window name
#--------------------------------------------------
set anaout2 .analog_output_list2




##############################################################
# "dispay" is the path of the entry window where we want
# to display our selection
##############################################################


proc analog_output_list2 { display } {

   #-------------------
   # Declare variable
   #-------------------
   global out2
   global anaout2


   if [winfo exists $anaout2] {destroy $anaout2 }

   #-------------------------------------------------------
   # Create a new window that contains the analog list
   #-------------------------------------------------------
   global env
   set env(DISPLAY) :0.1
   toplevel $anaout2

   set out2 $display


   button $anaout2.in1 -relief flat -text "Analog Output #1" -command { anaout_selected2 $out2  "Analog Output 1"}
   button $anaout2.in2 -relief flat -text "Analog Output #2" -command { anaout_selected2 $out2  "Analog Output 2"}
   button $anaout2.in3 -relief flat -text "Analog Output #3" -command { anaout_selected2 $out2  "Analog Output 3"}
   button $anaout2.in4 -relief flat -text "Analog Output #4" -command { anaout_selected2 $out2  "Analog Output 4"}
   button $anaout2.in5 -relief flat -text "Analog Output #5" -command { anaout_selected2 $out2  "Analog Output 5"}
   button $anaout2.in6 -relief flat -text "Analog Output #6" -command { anaout_selected2 $out2  "Analog Output 6"}
   button $anaout2.in7 -relief flat -text "Analog Output #7" -command { anaout_selected2 $out2  "Analog Output 7"}
   button $anaout2.in8 -relief flat -text "Analog Output #8" -command { anaout_selected2 $out2  "Analog Output 8"}
   button $anaout2.in9 -relief flat -text "Analog Output #9" -command { anaout_selected2 $out2  "Analog Output 9"}
   button $anaout2.in10 -relief flat -text "Analog Output #10" -command { anaout_selected2 $out2  "Analog Output 10"}
   button $anaout2.in11 -relief flat -text "Analog Output #11" -command { anaout_selected2 $out2  "Analog Output 11"}
   button $anaout2.in12 -relief flat -text "Analog Output #12" -command { anaout_selected2 $out2  "Analog Output 12"}
   button $anaout2.in13 -relief flat -text "Analog Output #13" -command { anaout_selected2 $out2  "Analog Output 13"}
   button $anaout2.in14 -relief flat -text "Analog Output #14" -command { anaout_selected2 $out2  "Analog Output 14"}
   button $anaout2.in15 -relief flat -text "Analog Output #15" -command { anaout_selected2 $out2  "Analog Output 15"}
   button $anaout2.in16 -relief flat -text "Analog Output #16" -command { anaout_selected2 $out2  "Analog Output 16"}

   for {set i 1 } {$i <= 16 } {incr i} {

   	pack $anaout2.in$i -side top


   }

  button $anaout2.b -text Close -command {destroy $anaout2}
  pack $anaout2.b






   proc anaout_selected2 { display text } {

      global anaout2

      $display configure -state normal
      $display delete 0 100
      $display insert 0 $text
      $display configure -state disabled

      # Close the output list after
      destroy $anaout2

   # end proc list_output
   }

#end of proc "analog_output_list2"
}