version 1.1.1.1, 1999/09/28 21:25:37
|
version 1.2, 1999/11/02 19:10:44
|
Line 50 proc createGradeSubjWindow {} {
|
Line 50 proc createGradeSubjWindow {} {
|
pack $msglist $msgbutton -side top |
pack $msglist $msgbutton -side top |
pack configure $msgbutton -anchor w |
pack configure $msgbutton -anchor w |
|
|
set gSubj(response) [listbox $msglist.list -width 40 -height 5 \ |
set gSubj(responseList) [listbox $msglist.list -width 40 -height 5 \ |
-yscrollcommand "$msglist.scroll set"] |
-yscrollcommand "$msglist.scroll set"] |
scrollbar $msglist.scroll -command "$msglist.text yview" |
scrollbar $msglist.scroll -command "$msglist.text yview" |
pack $gSubj(response) $msglist.scroll -side left |
pack $gSubj(responseList) $msglist.scroll -side left |
pack configure $msglist.scroll -fill y |
pack configure $msglist.scroll -fill y |
|
|
set gSubj(numresponse) 0 |
set gSubj(numresponse) 0 |
Line 674 proc subjSendResponse {} {
|
Line 674 proc subjSendResponse {} {
|
global gSubj |
global gSubj |
} |
} |
|
|
|
########################################################### |
|
# subjIndexResponse |
|
########################################################### |
|
########################################################### |
|
########################################################### |
proc subjIndexResponse {} { |
proc subjIndexResponse {} { |
global gSubj |
global gSubj |
|
|
$gSubj(response) delete 0 end |
$gSubj(responseList) delete 0 end |
|
|
set i 0 |
set i 0 |
foreach element [lsort -dictionary [array names gSubj "response.*"]] { |
foreach element [lsort -dictionary [array names gSubj "response.*"]] { |
set head [string range $gSubj($element) 0 30] |
regsub -all -- "\n\r\t" [string range $gSubj($element) 0 30] " " head |
$gSubj(response) insert end "[incr i]. $head" |
$gSubj(responseList) insert end "[incr i]. $head" |
} |
} |
} |
} |
|
|
Line 696 proc subjSaveResponse {} {
|
Line 701 proc subjSaveResponse {} {
|
|
|
set num [incr gSubj(numresponse)] |
set num [incr gSubj(numresponse)] |
set gSubj(response.$num) [$gSubj(responseEdit) get 0.0 end] |
set gSubj(response.$num) [$gSubj(responseEdit) get 0.0 end] |
|
destroy [winfo toplevel $gSubj(responseEdit)] |
subjIndexResponse |
subjIndexResponse |
} |
} |
|
|
Line 717 proc subjNewResponse {} {
|
Line 723 proc subjNewResponse {} {
|
|
|
set textFrame [frame $response.text] |
set textFrame [frame $response.text] |
set buttonFrame [frame $response.button] |
set buttonFrame [frame $response.button] |
|
pack $textFrame $buttonFrame |
|
|
set gSubj(responseEdit) [text $textFrame.text -yscrollcommand \ |
set gSubj(responseEdit) [text $textFrame.text -yscrollcommand \ |
"$textFrame.scroll set" -wrap char -height 15] |
"$textFrame.scroll set" -wrap char -height 15] |
scrollbar $textFrame.scroll -command "$textFrame.text yview" |
scrollbar $textFrame.scroll -command "$textFrame.text yview" |
pack $textFrame.scroll $textFrame.text -side left -expand 1 |
pack $textFrame.text $textFrame.scroll -side left -expand 1 |
|
pack configure $textFrame.scroll -fill y |
|
|
button $buttonFrame.save -text Save -command "subjSaveResponse" |
button $buttonFrame.save -text Save -command "subjSaveResponse" |
button $buttonFrame.forget -text Cancel -command "destroy $response" |
button $buttonFrame.forget -text Cancel -command "destroy $response" |