2 proc FormatXTicks { w value } {
4 # Determine the element name from the value
6 set index [expr round($value)]
7 if { $index != $value } {
12 set name [lindex { A1 B1 A2 B2 C1 D1 C2 A3 E1 } $index]
16 source scripts/patterns.tcl
18 image create photo bgTexture -file ./images/chalk.gif
21 Axis.TickFont -*-helvetica-medium-r-*-*-12-*-*
22 Axis.TitleFont -*-helvetica-bold-r-*-*-12-*-*
23 Element.Background white
28 Legend.Font "-*-helvetica*-bold-r-*-*-12-*-*"
29 Legend.ActiveBorderWidth 2
30 Legend.ActiveRelief raised
34 TextMarker.Font *Helvetica-Bold-R*14*
35 activeBar.Foreground black
36 activeBar.Stipple pattern1
38 Font -*-helvetica-bold-r-*-*-14-*-*
40 Title "Comparison of Simulators"
41 x.Command FormatXTicks
46 set resource [string trimleft $graph .]
47 foreach { option value } $configOptions {
48 option add *$resource.$option $value
51 set visual [winfo screenvisual .]
52 if { $visual != "staticgray" && $visual != "grayscale" } {
53 option add *print.background yellow
54 option add *quit.background red
55 option add *quit.activeBackground red2
58 vector create X Y0 Y1 Y2 Y3 Y4
60 X set { 1 2 3 4 5 6 7 8 9 }
62 0.729111111 0.002250000 0.09108333 0.006416667 0.026509167
63 0.007027778 0.1628611 0.06405278 0.08786667
66 0.003120278 0.004638889 0.01113889 0.048888889 0.001814722
67 0.291388889 0.0503500 0.13876389 0.04513333
70 11.534444444 3.879722222 4.54444444 4.460277778 2.334055556
71 1.262194444 1.8009444 4.12194444 3.24527778
74 1.015750000 0.462888889 0.49394444 0.429166667 1.053694444
75 0.466111111 1.4152500 2.17538889 2.55294444
78 0.022018611 0.516333333 0.54772222 0.177638889 0.021703889
79 0.134305556 0.5189278 0.07957222 0.41155556
86 # Label yData Color Stipple Pattern
88 "Load" Y2 lightblue pattern1
89 "Other" Y4 lightpink pattern1
90 "Read In" Y0 lightgoldenrod pattern1
91 "Setup" Y1 lightyellow pattern2
94 "Load" Y2 white azure "" 0
95 "Solve" Y3 cyan1 lightcyan pattern2 1
96 "zOther" Y4 lightpink lightpink pattern1 1
97 "Read In" Y0 lightgoldenrod lightgoldenrod pattern1 1
98 "Setup" Y1 lightyellow lightyellow pattern2 1
101 foreach {label yData fg bg stipple bd} $attributes {
102 $graph element create $yData \
113 Blt_Crosshairs $graph
114 Blt_ActiveLegend $graph
115 Blt_ClosestPoint $graph
117 $graph marker bind all <B2-Motion> {
118 set coords [%W invtransform %x %y]
119 catch { %W marker configure [%W marker get current] -coords $coords }
122 $graph marker bind all <Enter> {
123 set marker [%W marker get current]
124 catch { %W marker configure $marker -bg green}
127 $graph marker bind all <Leave> {
128 set marker [%W marker get current]
129 catch { %W marker configure $marker -bg ""}