Slider 100% SVG
New version runing with Firefox 1.5, Opera 9 and Batik 1.6
Design and script are separated.
Script is load on begin
Design is load on request and removed after use.
You can create your design, save it in SVG or SVGZ files.
In main SVG, for using slider, you have to
1) load script with
<script xlink:href="js/slider.js"/> manage tool
<script xlink:href="js/slider.js"/> emulate getURL() and parseXML()
2) reserve at the end place for design with <g id="messages" transform="translate(100,50)"></g> by example
3) put gradients used by tool in <defs> section
4) call it with
add_slider("svg/slider.svg","messages","Change opacity\nof rectangle",0,1, num_slider);
in order: file for design, name of group where put fragment, string for text, value for minimum, value for maximum, number for using
5) create function to use result in main SVG as this
( svgdoc must be name for SVGDocument and name of group +"_use_slider" name of function )
In SVG design, this function is called when you close window with
Function slider_tape allow using Enter and Escape keys to close window.
Three lines of text can be used with "invite0", "invite1", "invite2" as id.
You have to keep id for objects in design or modify script.
When slider window is closed, value choosed is give to main SVG.