Changeset 399 for trunk/expgui
- Timestamp:
- Dec 4, 2009 5:05:31 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/expgui
- Property rcs:date changed from 2001/05/23 20:11:12 to 2001/06/29 18:06:31
- Property rcs:lines changed from +39 -7 to +90 -16
- Property rcs:rev changed from 1.43 to 1.44
r395 r399 379 379 # set fo extraction on LS page 380 380 SetupExtractHist 381 # set convergence criterion 382 InitLSvars 381 383 382 384 # update the histogram list & update the page … … 417 419 set expgui(titleunchanged) 1 418 420 wm iconname . [file tail $expgui(expfile)] 421 # set convergence criterion 422 InitLSvars 419 423 } 420 424 … … 783 787 wm title . $expgui(expfile) 784 788 set expgui(titleunchanged) 1 789 # set convergence criterion 790 InitLSvars 785 791 } 786 792 … … 2235 2241 set entrycmd(fobsextract) "histinfo [list $histlist] foextract" 2236 2242 if {[llength $histlist] == 0 || [string trim $histlist] == ""} { 2243 set entrycmd(LBdamp) "" 2237 2244 foreach phase {1 2 3 4 5 6 7 8 9} { 2238 2245 $expgui(FobsExtractFrame).l$phase config -fg grey … … 2246 2253 set entrycmd(trace) 0 2247 2254 set entryvar(fobsextract) [histinfo $histlist foextract] 2255 set entrycmd(LBdamp) "histinfo $histlist LBdamp" 2256 set entryvar(LBdamp) [histinfo $histlist LBdamp] 2248 2257 foreach phase {1 2 3 4 5 6 7 8 9} { 2249 2258 # is the phase present? … … 2264 2273 } elseif {[llength $histlist] > 1} { 2265 2274 # disable traces on entryvar 2275 set entrycmd(LBdamp) "histinfo [list $histlist] LBdamp" 2276 set entryvar(LBdamp) [histinfo [lindex $histlist 0] LBdamp] 2266 2277 set entrycmd(trace) 0 2267 2278 # multiple histograms need phases in any histogram … … 2330 2341 grid [label $w.0.a \ 2331 2342 -text "Setting background terms for histogram $histlist" \ 2332 -bg beige] -row 0 -column 0 -columnspan 10 2343 -bg beige] -row 0 -column 0 -columnspan 4 2344 grid [button $w.0.bkg -text "Fit Background\nGraphically" \ 2345 -command "QuitEditBackground $w; bkgedit $histlist"] \ 2346 -row 0 -column 4 -rowspan 2 2347 grid columnconfig $w.0 0 -weight 1 2348 grid columnconfig $w.0 4 -weight 1 2333 2349 } 2334 2350 set hist [lindex $histlist 0] 2335 grid [label $w.0.b -text "Function type" -bg beige] -row 1 -column 02351 grid [label $w.0.b -text "Function type" -bg beige] -row 1 -column 0 -sticky e 2336 2352 2337 2353 # disable traces on expgui(backtype) & expgui(backterms) now … … 2345 2361 $typemenu delete 0 end 2346 2362 foreach item { 2347 "1 - Shifted Chebys hev"2363 "1 - Shifted Chebyschev" 2348 2364 "2 - Cosine Fourier series" 2349 2365 "3 - Radial distribution peaks" … … 3235 3251 3236 3252 pack [frame $expgui(lsFrame).f1] -fill both -expand true 3237 grid rowconfigure $expgui(lsFrame).f1 4 -weight 13238 3253 set row 0 3239 3254 grid [label $expgui(lsFrame).f1.his1 -pady 6 -text "Last History:"] -row $row -column 0 … … 3249 3264 3250 3265 incr row 3266 grid rowconfigure $expgui(lsFrame).f1 $row -weight 1 3267 incr row 3251 3268 grid [frame $expgui(lsFrame).f1.b -bd 4 -relief groove] \ 3252 -row $row -column 0 -columnspan 2 -pady 3 3269 -row $row -column 0 -columnspan 2 -pady 3 -sticky s 3253 3270 grid [label $expgui(lsFrame).f1.b.lcyc -text "Number of Cycles"] -row 0 -column 0 3254 3271 grid [entry $expgui(lsFrame).f1.b.ecyc -width 3 \ 3255 3272 -textvariable entryvar(cycles)] -row 0 -column 1 3256 3273 set entrybox(cycles) $expgui(lsFrame).f1.b.ecyc 3274 3275 grid [frame $expgui(lsFrame).f1.cv -bd 4 -relief groove] \ 3276 -row $row -column 2 -sticky ew 3277 grid [label $expgui(lsFrame).f1.cv.l -text "Convgerence Criterion"] \ 3278 -row 0 -column 0 -columnspan 2 3279 grid [label $expgui(lsFrame).f1.cv.v -textvariable expgui(convlbl)] -row 1 -column 0 3280 grid [scale $expgui(lsFrame).f1.cv.s -orient horizontal \ 3281 -from -200 -to 200 -showvalue 0 -command SetConv -resolution 10 \ 3282 -variable expgui(convg)] -row 1 -column 1 3283 3284 incr row 3257 3285 grid [menubutton $expgui(lsFrame).f1.lprint -textvariable expgui(printopt) \ 3258 3286 -menu $expgui(lsFrame).f1.lprint.menu -bd 4 -relief raised \ 3259 ] -row $row -column 23287 ] -row $row -column 0 -columnspan 2 3260 3288 menu $expgui(lsFrame).f1.lprint.menu 3261 3289 foreach num [lsort [array names printopts]] { … … 3264 3292 -variable entryvar(printopt$num) 3265 3293 } 3266 #grid [frame $expgui(lsFrame).f1.c -bd 4 -relief groove] -row $row -column 3 3267 #grid [label $expgui(lsFrame).f1.c.fol -text "Extract Fobs"] -row 0 -column 2 3268 #grid [checkbutton $expgui(lsFrame).f1.c.foc -variable entryvar(fobsextract)] -row 0 -column 3 3294 3295 grid [frame $expgui(lsFrame).f1.marq -bd 4 -relief groove] \ 3296 -row $row -column 2 -sticky ew 3297 grid [label $expgui(lsFrame).f1.marq.l -text "Marquardt Damping"] \ 3298 -row 0 -column 0 -columnspan 2 3299 grid [label $expgui(lsFrame).f1.marq.v -textvariable expgui(marq)] \ 3300 -row 1 -column 0 3301 grid [scale $expgui(lsFrame).f1.marq.s -orient horizontal \ 3302 -from 1.0 -to 9.99 -showvalue 0 -command SetMarq -resolution 0.01 \ 3303 -variable expgui(marq)] -row 1 -column 1 3304 3305 incr row 3306 grid rowconfigure $expgui(lsFrame).f1 $row -weight 1 3307 3269 3308 incr row 3270 3309 if {$expgui(haveBW)} { … … 3278 3317 set expgui(FobsExtractFrame) $expgui(lsFrame).f1.a 3279 3318 } 3280 grid rowconfigure $expgui(lsFrame).f1 $row -pad 16 3319 3281 3320 grid [frame $expgui(FobsExtractFrame).c -bd 4 -relief groove] \ 3282 -row 0 -column 8 -columnspan 3 -sticky e 3321 -row 0 -column 8 -columnspan 3 -sticky ens 3283 3322 grid [label $expgui(FobsExtractFrame).c.fol -text "Extract Fobs"] \ 3284 3323 -row 0 -column 2 3285 3324 grid [checkbutton $expgui(FobsExtractFrame).c.foc \ 3286 3325 -variable entryvar(fobsextract)] -row 0 -column 3 3326 3327 grid [frame $expgui(FobsExtractFrame).d -bd 4 -relief groove] \ 3328 -row 0 -column 3 -columnspan 5 -sticky ens 3329 grid [label $expgui(FobsExtractFrame).d.fol -text "LeBail damping"] \ 3330 -row 0 -column 2 3331 tk_optionMenu $expgui(FobsExtractFrame).d.d entryvar(LBdamp) \ 3332 0 1 2 3 4 5 6 7 8 9 3333 grid $expgui(FobsExtractFrame).d.d -row 0 -column 3 3334 incr row 3335 grid rowconfigure $expgui(lsFrame).f1 $row -weight 1 3336 3337 3338 3287 3339 foreach num {1 2 3 4 5 6 7 8 9} { 3288 3340 grid [label $expgui(FobsExtractFrame).l$num -text $num] -row 1 -column $num … … 3306 3358 grid [label $expgui(FobsExtractFrame).t \ 3307 3359 -text "Extraction\nMethod" -anchor c] \ 3308 -column 0 -row 0 - rowspan 2 -sticky s3309 grid [label $expgui(FobsExtractFrame).t0 -text " Phase #" -anchor sw] \3310 -column 1 -row 0 -columnspan 7 -sticky sw3360 -column 0 -row 0 -sticky n 3361 grid [label $expgui(FobsExtractFrame).t0 -text "(Phase #)" -anchor c] \ 3362 -column 10 -row 1 -sticky w 3311 3363 grid [label $expgui(FobsExtractFrame).t1 -text "Rietveld" -anchor c] -column 0 -row 2 3312 3364 grid [label $expgui(FobsExtractFrame).t2 -text "F(calc) Weighted" -anchor c] -column 0 -row 3 … … 3314 3366 grid [label $expgui(FobsExtractFrame).t2a -text "(Model biased)" -anchor c] -column 10 -row 3 3315 3367 grid [label $expgui(FobsExtractFrame).t3a -text "(Le Bail method)" -anchor c] -column 10 -row 4 3368 3369 proc InitLSvars {} { 3370 global expgui 3371 set expgui(convg) [set expgui(convinit) [expinfo convg]] 3372 set expgui(convlbl) [format %5.2f [expr pow(10,$expgui(convg)/100.)]] 3373 set expgui(marq) [set expgui(marqinit) [expinfo marq]] 3374 } 3375 proc SetConv {x} { 3376 global expgui 3377 if {$x != $expgui(convinit) && $expgui(changed) <= 0} { 3378 incr expgui(changed) 3379 } 3380 if {$expgui(changed)} {expinfo convg set $x} 3381 set expgui(convlbl) [format %5.2f [expr {pow(10,$x/100.)}]] 3382 } 3383 proc SetMarq {x} { 3384 global expgui 3385 if {$x != $expgui(marqinit) && $expgui(changed) <= 0} { 3386 incr expgui(changed) 3387 } 3388 if {$expgui(changed)} {expinfo marq set $x} 3389 } 3316 3390 # ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ END OF LS PANE CODE ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 3317 3391 #-------------------------------------------------------------------------
Note: See TracChangeset
for help on using the changeset viewer.