Ignore:
Timestamp:
Oct 12, 2010 12:46:50 PM (12 years ago)
Author:
chlake
Message:

add disagl edit & viewer

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/sandbox/distrest.tcl

    r1013 r1021  
    66#::sr_lookuplist1
    77#::sr_lookuplist2
    8 #::sr_top
     8#sr_top
    99#::sr_checkall
    1010#::sr_entryvar(choicenum)
     
    9393
    9494    #Activate Restraint Editor
    95     grid [button $editorbox.edit -text "Activate Distance \n Restraint Editor" -command SR_TEST] -column 0 -row 3 \
    96         -sticky sw -columnspan 2
     95    grid [button $editorbox.edit -text "Activate Restraint \n Editor" -command SR_TEST] -column 0 -row 4 \
     96        -columnspan 2 -pady 5
    9797        $editorbox.edit config -bg LightGreen -bd 6
     98
     99    grid [button $editorbox.search -text "Edit Search Distance \n Parameters" -command DA_Control_Panel] -column 0 -row 3 \
     100        -columnspan 2
     101        $editorbox.edit config -bd 4
    98102
    99103
     
    317321    pack $sr_rb -side top -fill both -expand 1
    318322
    319     foreach {::sr_top main side lbl} [MakeScrollTable $sr_rb] {}
     323    foreach {sr_top main side lbl} [MakeScrollTable $sr_rb] {}
    320324    set     ::contraintmainbox $main
    321325
    322     button $::sr_top.alabel1 -text "Atom 1 " -width 7   \
    323         -command "SR_Sort atom1 $main $::sr_top.alabel1 $::sr_top.alabel2 $::sr_top.dlabel1"
    324     button $::sr_top.alabel2 -text "Atom 2 " -width 7 \
    325         -command "SR_Sort atom2 $main $::sr_top.alabel1 $::sr_top.alabel2 $::sr_top.dlabel1"
    326     button $::sr_top.dlabel1 -text "Distance " -width 9 \
    327         -command "SR_Sort distance $main $::sr_top.alabel1 $::sr_top.alabel2 $::sr_top.dlabel1"
    328 
    329     grid $::sr_top.alabel1 -column 1 -row 2
    330     grid $::sr_top.alabel2 -column 2 -row 2
    331     grid $::sr_top.dlabel1 -column 3 -row 2
    332 
    333     label  $::sr_top.rlabel1 -text "Restraint"
    334     label  $::sr_top.rlabel2 -text "esd"
    335     grid $::sr_top.rlabel1 -column 4 -row 2 -padx 20
    336     grid $::sr_top.rlabel2 -column 5 -row 2 -padx 20
    337 
    338 
    339     button $::sr_top.rcon1   -text "Check All" -width 10 -command {
    340         set ::sr_checkall 1
    341         SR_Set_All_Check_Buttons
    342         grid forget $::sr_top.rcon1
    343         grid $::sr_top.rcon2 -column 6 -row 2 -padx 5
    344     }
    345 
    346     button $::sr_top.rcon2   -text "Clear All" -width 10 -command {
    347         set ::sr_checkall 0
    348         SR_Set_All_Check_Buttons
    349         grid forget $::sr_top.rcon2
    350         grid $::sr_top.rcon1 -column 6 -row 2 -padx 5
    351     }
    352 
    353     grid $::sr_top.rcon1   -column 6 -row 2 -padx 5
     326    button $sr_top.alabel1 -text "Atom 1 " -width 7   \
     327        -command "SR_Sort atom1 $main $sr_top.alabel1 $sr_top.alabel2 $sr_top.dlabel1"
     328    button $sr_top.alabel2 -text "Atom 2 " -width 7 \
     329        -command "SR_Sort atom2 $main $sr_top.alabel1 $sr_top.alabel2 $sr_top.dlabel1"
     330    button $sr_top.dlabel1 -text "Distance " -width 9 \
     331        -command "SR_Sort distance $main $sr_top.alabel1 $sr_top.alabel2 $sr_top.dlabel1"
     332
     333    grid $sr_top.alabel1 -column 1 -row 2
     334    grid $sr_top.alabel2 -column 2 -row 2
     335    grid $sr_top.dlabel1 -column 3 -row 2
     336
     337    label  $sr_top.rlabel1 -text "Restraint"
     338    label  $sr_top.rlabel2 -text "esd"
     339    grid $sr_top.rlabel1 -column 4 -row 2 -padx 20
     340    grid $sr_top.rlabel2 -column 5 -row 2 -padx 20
     341
     342
     343    button $sr_top.rcon1   -text "Check All" -width 10 -command "
     344        set ::sr_checkall 1;
     345        SR_Set_All_Check_Buttons;
     346        grid forget $sr_top.rcon1;
     347        grid $sr_top.rcon2 -column 6 -row 2 -padx 5;
     348    "
     349
     350    button $sr_top.rcon2   -text "Clear All" -width 10 -command "
     351        set ::sr_checkall 0;
     352        SR_Set_All_Check_Buttons;
     353        grid forget $sr_top.rcon2;
     354        grid $sr_top.rcon1 -column 6 -row 2 -padx 5;
     355    "
     356
     357    grid $sr_top.rcon1   -column 6 -row 2 -padx 5
    354358
    355359    #SR_Sort atom1 $main
     
    391395                                label $main.rdistance$i -text [lindex $rprint 8] -justify center -anchor center
    392396                                entry $main.restraint$i -width 8 -textvariable ::sr_restraintdist([lindex $rprint 13]) -takefocus 1
    393                                 bind  $main.restraint$i <KeyRelease> {SR_Validate_Soft %W distance}
     397                                      $main.restraint$i selection range 0 end
     398                                bind  $main.restraint$i <KeyRelease> {SR_Validate_Soft %W distance}
    394399                                entry $main.restesd$i -width 8 -textvariable ::sr_restraintesd([lindex $rprint 13]) -takefocus 1
     400                                      $main.restesd$i selection range 0 end
    395401                                bind  $main.restesd$i <KeyRelease> {SR_Validate_Soft %W esd}
    396402                                checkbutton $main.sr_crestraint$i -variable ::sr_crestraint([lindex $rprint 13])
     
    623629
    624630    entry  $srcb1.sr_dminvalue -width 8 -textvariable ::sr_dminvalue        -takefocus 1
     631           $srcb1.sr_dminvalue selection range 0 end
    625632    entry  $srcb1.sr_dmaxvalue -width 8 -textvariable ::sr_dmaxvalue        -takefocus 1
     633           $srcb1.sr_dmaxvalue selection range 0 end
    626634    entry  $srcb2.sr_rvalue    -width 8 -textvariable ::sr_rvalue           -takefocus 1
     635           $srcb2.sr_rvalue selection range 0 end
    627636    entry  $srcb2.sr_resd      -width 8 -textvariable ::sr_resd             -takefocus 1
     637           $srcb2.sr_resd selection range 0 end
    628638
    629639    bind  $srcb1.sr_dminvalue <KeyRelease> {SR_Validate_Soft %W dmin}
Note: See TracChangeset for help on using the changeset viewer.