Ignore:
Timestamp:
Apr 2, 2015, 9:28:24 AM (9 years ago)
Author:
ldelgass
Message:

s/styles/style/ (for code consistency), remove unused member variables

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/1.4/gui/scripts/flowvisviewer.tcl

    r5183 r5187  
    717717# ----------------------------------------------------------------------
    718718itcl::body Rappture::FlowvisViewer::scale {args} {
    719     array set styles {
     719    array set style {
    720720        -color BCGYR
    721721        -levels 6
     
    732732            if { ![info exists _volcomponents($cname)] } {
    733733                lappend _componentsList $cname
    734                 array set styles [lindex [$dataobj components -style $cname] 0]
    735                 set cmap [ColorsToColormap $styles(-color)]
     734                array set style [lindex [$dataobj components -style $cname] 0]
     735                set cmap [ColorsToColormap $style(-color)]
    736736                set _cname2defaultcolormap($cname) $cmap
    737                 set _settings($cname-colormap) $styles(-color)
     737                set _settings($cname-colormap) $style(-color)
    738738            }
    739739            lappend _volcomponents($cname) $dataobj-$cname
     
    12551255    foreach key [array names _serverObjs *-*] {
    12561256        if {[string match $_first-* $key]} {
    1257             array set styles {
     1257            array set style {
    12581258                -cutplanes 1
    12591259            }
    12601260            foreach {dataobj comp} [split $key -] break
    1261             array set styles [lindex [$dataobj components -style $comp] 0]
    1262             if {$what != "-cutplanes" || $styles(-cutplanes)} {
     1261            array set style [lindex [$dataobj components -style $comp] 0]
     1262            if {$what != "-cutplanes" || $style(-cutplanes)} {
    12631263                lappend rlist $_serverObjs($key)
    12641264            }
     
    16941694#
    16951695itcl::body Rappture::FlowvisViewer::NameTransferFunc { dataobj cname } {
    1696     array set styles {
     1696    array set style {
    16971697        -color BCGYR
    16981698        -levels 6
    16991699        -opacity 0.5
    17001700    }
    1701     array set styles [lindex [$dataobj components -style $cname] 0]
    1702     set _settings($this-opacity) [expr $styles(-opacity) * 100]
     1701    array set style [lindex [$dataobj components -style $cname] 0]
     1702    set _settings($this-opacity) [expr $style(-opacity) * 100]
    17031703    set _obj2style($dataobj-$cname) $cname
    17041704    lappend _style2objs($cname) $dataobj $cname
     
    17161716#
    17171717itcl::body Rappture::FlowvisViewer::ComputeTransferFunc { tf } {
    1718     array set styles {
     1718    array set style {
    17191719        -color BCGYR
    17201720        -levels 6
     
    17261726        return 0
    17271727    }
    1728     array set styles [lindex [$dataobj components -style $comp] 0]
     1728    array set style [lindex [$dataobj components -style $comp] 0]
    17291729
    17301730    # We have to parse the style attributes for a volume using this
     
    17431743    if { ![info exists _isomarkers($tf)] } {
    17441744        # Have to defer creation of isomarkers until we have data limits
    1745         if { [info exists styles(-markers)] &&
    1746              [llength $styles(-markers)] > 0  } {
    1747             ParseMarkersOption $tf $styles(-markers)
     1745        if { [info exists style(-markers)] &&
     1746             [llength $style(-markers)] > 0  } {
     1747            ParseMarkersOption $tf $style(-markers)
    17481748        } else {
    1749             ParseLevelsOption $tf $styles(-levels)
    1750         }
    1751     }
    1752     if { [info exists styles(-nonuniformcolors)] } {
    1753         foreach { value color } $styles(-nonuniformcolors) {
     1749            ParseLevelsOption $tf $style(-levels)
     1750        }
     1751    }
     1752    if { [info exists style(-nonuniformcolors)] } {
     1753        foreach { value color } $style(-nonuniformcolors) {
    17541754            append cmap "$value [Color2RGB $color] "
    17551755        }
    17561756    } else {
    1757         set cmap [ColorsToColormap $styles(-color)]
     1757        set cmap [ColorsToColormap $style(-color)]
    17581758    }
    17591759
    17601760    if { ![info exists _settings($this-opacity)] } {
    1761         set _settings($this-opacity) [expr $styles(-opacity) * 100]
     1761        set _settings($this-opacity) [expr $style(-opacity) * 100]
    17621762    }
    17631763
Note: See TracChangeset for help on using the changeset viewer.