1 option add
*Interval.activeForeground
#d0d0d0
2 option add
*Interval.sliderForeground
#b0b0b0
3 option add
*Interval.activeForeground
#d0d0d0
4 option add
*Interval.sliderForeground
#b0b0b0
6 ########################################################################
9 proc ShowDynamicPanel
{win
} {
10 if {! [winfo ismapped
$win.bottomframe
]} {
11 pack append $win $win.bottomframe
{bottom
frame center fill expand
}
12 set x
[winfo rootx
$win]
13 set y
[winfo rooty
$win]
14 set width
[winfo width
$win]
16 wm geometry
$win ${width
}x
${height
}
21 proc HideDynamicPanel
{win
} {
22 if {[winfo ismapped
$win.bottomframe
]} {
23 pack unpack
$win.bottomframe
24 set x
[winfo rootx
$win]
25 set y
[winfo rooty
$win]
26 set width
[winfo width
$win]
28 wm geometry
$win ${width
}x
${height
}
37 for {set i
0} {$i < 8} {incr i
} {
38 foreach win
$MapWindows {
39 [WindowLink
$win.interval
]$i reset
46 proc SetDynamicData
{win index min max
} {
47 set MinIndex
[expr "$index * 2"]
48 set MaxIndex
[expr "$MinIndex + 1"]
50 sim DynamicData
$MinIndex $min
51 sim DynamicData
$MaxIndex $max
53 set int
[WindowLink
$win.interval
]$index
54 set from
[lindex [$int config
-from] 4]
55 set to
[lindex [$int config
-to] 4]
56 set min
[lindex [$int config
-min] 4]
57 set max
[lindex [$int config
-max] 4]
58 set range
[expr "${to}-${from}"]
61 set low
[expr "(($min-$from)*$scale/$range) + $offset"]
62 set high
[expr "(($max-$from)*$scale/$range) + $offset"]
64 set title Slider
$index
68 UIDoSound
"\"sound replay $title -channel $chan -volume $vol ; sound replay $sound -channel $chan -volume $vol -speed $low ; sound play $sound -channel $chan -volume $vol -speed $high\""
71 foreach win
$MapWindows {
72 [WindowLink
$win.interval
]$index set $min $max
83 {Residential Zone Map
}
88 {Population Density Map
}
102 proc UISetMapState
{w state
} {
104 set win
[winfo toplevel $w]
105 set m
[WindowLink
$win.view
]
106 set title
[lindex $MapTitles $state]
107 wm title
$win "$title"
108 wm iconname
$win "$title"
109 global [set var MapState.
$win]
113 {6 8 9 10 11 12 13} {
114 [WindowLink
$win.legend
] config
-bitmap "@Images/LegendMaxMin.xpm"
115 HideDynamicPanel
$win
118 [WindowLink
$win.legend
] config
-bitmap "@Images/LegendPlusMinus.xpm"
119 HideDynamicPanel
$win
122 [WindowLink
$win.legend
] config
-bitmap "@Images/LegendNone.xpm"
124 ShowDynamicPanel
$win
126 HideDynamicPanel
$win