Changeset 3791 for trunk/gui/scripts/xyresult.tcl
- Timestamp:
- Jul 12, 2013 7:39:50 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gui/scripts/xyresult.tcl
r3784 r3791 310 310 set barwidth $params(-barwidth) 311 311 foreach {mapx mapy} [GetAxes $dataobj] break 312 set label [$dataobj hints label] 312 313 foreach comp [$dataobj components] { 313 314 set tag $dataobj-$comp … … 316 317 # Ignore -type, it's already been set 317 318 switch -- [$g element type $elem] { 318 "line" - "scatter" { 319 "line" { 320 set xv [$g line cget $elem -x] 321 if {([$xv length] <= 1) || ($lwidth == 0)} { 322 set sym square 323 set pixels 2 324 } else { 325 set sym "" 326 set pixels 6 327 } 319 328 $g line configure $elem \ 320 -linewidth $lwidth \ 321 -dashes $dashes -hide no 322 } "bar" { 329 -symbol $sym -pixels $pixels \ 330 -linewidth $lwidth -label $label \ 331 -color $color -dashes $dashes \ 332 -mapx $mapx -mapy $mapy -hide no 333 } 334 "scatter" { 335 $g line configure $elem \ 336 -symbol square -pixels 2 \ 337 -linewidth $lwidth -label $label \ 338 -color $color -dashes $dashes \ 339 -mapx $mapx -mapy $mapy -hide no 340 } 341 "bar" { 323 342 $g bar configure $elem \ 324 -barwidth $barwidth \ 325 -hide no 343 -barwidth $barwidth -label $label \ 344 -background $color -foreground $color \ 345 -mapx $mapx -mapy $mapy -hide no 326 346 } 327 347 } 328 348 } else { 329 349 set elem "$type[incr _nextElement]" 330 set label [$dataobj hints label]331 350 set _elem2comp($elem) $tag 332 351 set _comp2elem($tag) $elem … … 360 379 -barwidth $barwidth \ 361 380 -label $label \ 362 - color$color \381 -background $color -foreground $color \ 363 382 -mapx $mapx -mapy $mapy 364 383 } … … 1631 1650 # Default 1632 1651 if {[info exists params(-color)]} { 1633 set color params(-color)1652 set color $params(-color) 1634 1653 } else { 1635 1654 set color black … … 1638 1657 set type "line" 1639 1658 } 1640 if {[info exists par mas(-barwidth)]} {1659 if {[info exists params(-barwidth)]} { 1641 1660 set barwidth $params(-barwidth) 1642 1661 } else { … … 1649 1668 } 1650 1669 if {[info exists params(-linestyle)]} { 1651 set dashes $parmas(-linestyle) 1670 # convert -linestyle to BLT -dashes 1671 switch -- $params(-linestyle) { 1672 dashed { set dashes {4 4} } 1673 dotted { set dashes {2 4} } 1674 default { set dashes {} } 1675 } 1652 1676 } else { 1653 1677 set dashes ""
Note: See TracChangeset
for help on using the changeset viewer.