Changeset 6343


Ignore:
Timestamp:
May 16, 2016, 7:41:22 AM (8 years ago)
Author:
ldelgass
Message:

Fix for setting isoline color to none in surface viewer.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gui/scripts/vtksurfaceviewer.tcl

    r6338 r6343  
    13151315            set _changed($what) 1
    13161316            set color [$itk_component(isolinecolor) value]
    1317             set _settings($what) $color
    1318             SendCmd "contour2d linecolor [Color2RGB $color]"
     1317            if { $color == "none" } {
     1318                if { $_settings(-isolinesvisible) } {
     1319                    set _changed(-isolinesvisible) 1
     1320                    foreach tag [CurrentDatasets -visible] {
     1321                        SendCmd "contour2d visible 0 $tag"
     1322                    }
     1323                    set _settings(-isolinesvisible) 0
     1324                }
     1325            } else {
     1326                set _settings($what) $color
     1327                if { !$_settings(-isolinesvisible) } {
     1328                    set _changed(-isolinesvisible) 1
     1329                    foreach tag [CurrentDatasets -visible] {
     1330                        SendCmd "contour2d visible 0 $tag"
     1331                    }
     1332                    set _settings(-isolinesvisible) 1
     1333                }
     1334                SendCmd "contour2d linecolor [Color2RGB $color]"
     1335            }
    13191336            DrawLegend
    13201337        }
     
    13241341            SendCmd "contour2d visible 0"
    13251342            if { $bool } {
     1343                if { [$itk_component(isolinecolor) value] != $_settings(-isolinecolor)} {
     1344                    $itk_component(isolinecolor) value $_settings(-isolinecolor)
     1345                }
    13261346                foreach tag [CurrentDatasets -visible] {
    13271347                    SendCmd "contour2d visible $bool $tag"
Note: See TracChangeset for help on using the changeset viewer.