Changeset 1318 for trunk/gui/scripts/flowvisviewer.tcl
- Timestamp:
- Mar 12, 2009 7:00:58 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gui/scripts/flowvisviewer.tcl
r1315 r1318 1 1 2 # ---------------------------------------------------------------------- 2 3 # COMPONENT: flowvisviewer - 3D vector field rendering … … 173 174 rename -highlightbackground -controlbackground controlBackground Background 174 175 } 175 pack $itk_component(reset) -side left -padx {4 1} -pady 4176 pack $itk_component(reset) -side left -padx {4 1} -pady 2 176 177 Rappture::Tooltip::for $itk_component(reset) "Reset the view to the default zoom level" 177 178 … … 186 187 rename -highlightbackground -controlbackground controlBackground Background 187 188 } 188 pack $itk_component(zoomin) -side left -padx 1 -pady 4189 pack $itk_component(zoomin) -side left -padx 1 -pady 2 189 190 Rappture::Tooltip::for $itk_component(zoomin) "Zoom in" 190 191 … … 199 200 rename -highlightbackground -controlbackground controlBackground Background 200 201 } 201 pack $itk_component(zoomout) -side left -padx {1 4} -pady 4202 pack $itk_component(zoomout) -side left -padx {1 4} -pady 2 202 203 Rappture::Tooltip::for $itk_component(zoomout) "Zoom out" 203 204 … … 211 212 rename -background -controlbackground controlBackground Background 212 213 } 213 pack $itk_component(slicers) -side bottom -padx 4 -pady 4214 pack $itk_component(slicers) -side bottom -padx 4 -pady 2 214 215 grid rowconfigure $itk_component(slicers) 1 -weight 1 215 216 # … … 338 339 "Toggle the volume cloud on/off" 339 340 grid $itk_component(volume) -row 0 -column 0 -columnspan 3 \ 340 -sticky ew -padx 1 -pady 3341 -sticky ew -padx 1 -pady 2 341 342 342 343 # … … 354 355 rename -highlightbackground -controlbackground controlBackground Background 355 356 } 356 pack $itk_component(settings) -side top -pady 2357 pack $itk_component(settings) -side top 357 358 358 359 Rappture::Balloon $itk_component(controls).panel -title "Settings" … … 472 473 rename -background -controlbackground controlBackground Background 473 474 } 474 pack $itk_component(flowctrl) -side top -padx 4 -pady 4475 pack $itk_component(flowctrl) -side top -padx 4 -pady 0 475 476 grid rowconfigure $itk_component(flowctrl) 1 -weight 1 476 477 … … 491 492 Rappture::Tooltip::for $itk_component(record) \ 492 493 "Record flow visualization" 493 grid $itk_component(record) -row 1 -column 0 - sticky ew -padx 1494 grid $itk_component(record) -row 1 -column 0 -padx 1 494 495 495 496 # … … 498 499 itk_component add stop { 499 500 label $itk_component(flowctrl).stop \ 500 -borderwidth 1 -relief sunken - state disable -padx 1 -pady 1 \501 -borderwidth 1 -relief sunken -padx 1 -pady 1 \ 501 502 -image [Rappture::icon playback-stop] 502 503 } { … … 509 510 Rappture::Tooltip::for $itk_component(stop) \ 510 511 "Stop flow visualization" 511 grid $itk_component(stop) -row 1 -column 1 - sticky ew -padx 1512 grid $itk_component(stop) -row 1 -column 1 -padx 1 512 513 513 514 # … … 527 528 Rappture::Tooltip::for $itk_component(play) \ 528 529 "Play/Pause flow visualization" 529 grid $itk_component(play) -row 1 -column 2 - sticky ew -padx 1530 grid $itk_component(play) -row 1 -column 2 -padx 1 530 531 531 532 # Bindings for rotation via mouse … … 951 952 952 953 # raise the record button back up. 953 $itk_component(record) configure -relief raised -state normal954 $itk_component(record) configure -relief raised 954 955 955 956 # FIXME: manually download file??? … … 1318 1319 switch -- $action { 1319 1320 record { 1320 $itk_component(record) configure -relief sunken -state disable 1321 $itk_component(stop) configure -relief raised -state normal 1322 $itk_component(play) configure -relief raised -state normal 1323 set inner [$itk_component(controls).panel component inner] 1324 set frames [$inner.scales.framecnt value] 1325 set cmds "flow capture $frames" 1326 _send $cmds 1321 if { [$itk_component(record) cget -relief] != "sunken" } { 1322 $itk_component(record) configure -relief sunken 1323 $itk_component(stop) configure -relief raised 1324 $itk_component(play) configure -relief raised 1325 set inner \ 1326 [$itk_component(controls).panel component inner] 1327 set frames [$inner.scales.framecnt value] 1328 set cmds "flow capture $frames" 1329 _send $cmds 1330 } 1327 1331 } 1328 1332 stop { 1329 $itk_component(record) configure -relief raised -state normal 1330 $itk_component(stop) configure -relief sunken -state disable 1331 $itk_component(play) configure -relief raised -state normal 1332 _pause 1333 set cmds "flow reset" 1334 _send $cmds 1335 1333 if { [$itk_component(stop) cget -relief] != "sunken" } { 1334 $itk_component(record) configure -relief raised 1335 $itk_component(stop) configure -relief sunken 1336 $itk_component(play) configure -relief raised 1337 _pause 1338 set cmds "flow reset" 1339 _send $cmds 1340 } 1336 1341 } 1337 1342 play { 1338 $itk_component(record) configure -relief raised -state normal 1339 $itk_component(stop) configure -relief raised -state normal 1340 $itk_component(play) configure \ 1341 -image [Rappture::icon playback-pause] \ 1342 -relief sunken -state normal 1343 bind $itk_component(play) <ButtonPress> \ 1344 [itcl::code $this _pause] 1345 _play 1343 if { [$itk_component(play) cget -relief] != "sunken" } { 1344 $itk_component(record) configure -relief raised 1345 $itk_component(stop) configure -relief raised 1346 $itk_component(play) configure \ 1347 -image [Rappture::icon playback-pause] \ 1348 -relief sunken 1349 bind $itk_component(play) <ButtonPress> \ 1350 [itcl::code $this _pause] 1351 _play 1352 } 1346 1353 } 1347 1354 default { … … 1383 1390 $itk_component(play) configure \ 1384 1391 -image [Rappture::icon playback-start] \ 1385 -relief raised -state normal1392 -relief raised 1386 1393 bind $itk_component(play) <ButtonPress> \ 1387 1394 [itcl::code $this _flow movie play toggle]
Note: See TracChangeset
for help on using the changeset viewer.