#!/users/mgd/packages/swarm/blt2.3/bin/bltwish
#!../bltwish

source bltDemo.tcl

image create photo bgTexture -file ./bitmaps/buckskin.gif

option add *Graph.Tile			bgTexture
option add *Label.Tile			bgTexture
option add *Frame.Tile			bgTexture
option add *Htext.Tile			bgTexture
option add *TileOffset			0
option add *HighlightThickness		0
option add *takeFocus			1
option add *Element.ScaleSymbols	yes
option add *Element.Smooth		natural
option add *activeLine.Color		yellow4
option add *activeLine.Fill		yellow
option add *activeLine.LineWidth	0
option add *Element.Pixels		3
option add *Graph.halo			7i

set visual [winfo screenvisual .] 
if { $visual != "staticgray" } {
    option add *print.background yellow
    option add *quit.background red
}

proc FormatLabel { w value } {
    return $value
}

set graph .graph

graph $graph -title "A Simple XY Graph" 
$graph xaxis configure \
	-loose no \
	-title "X Axis Label"
$graph yaxis configure \
	-title "Y Axis Label" 
$graph legend configure \
	-activerelief sunken \
	-background ""

vector x(250000) y(250000)
x seq 1.0
y random
$graph element create line3 -ydata y -xdata x -symbol triangle \
    -color green4 -fill green2 -linewidth 0 -outlinewidth 1 -pixels 4

$graph configure 
table . .graph 0,0  -fill both

wm min . 0 0

Blt_ZoomStack $graph
Blt_Crosshairs $graph
Blt_ActiveLegend $graph
Blt_ClosestPoint $graph

