Class Index | File Index

Classes


Class Slider

abstract class epresenting generic slider
Defined in: raphaeltools.src.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
Slider(raphael, slider, params, lineAttrs)
Slider
Field Summary
Field Attributes Field Name and Description
 
dx
x dimension of slider [pixels]
 
dy
y dimension of slider [pixels]
 
gap
gap between end of the slider's line and the slider's circle when the circle is at extreme position
 
initial value
 
length span of getable values
 
line
 
raphael instance
 
actual slider (must have setX, setX, getY, setY methods)
 
value when the slider is at the very beginning
 
value when the slider is at the very end
 
extreme beginning value
 
extreme end value
 
x
x coordinate of left/upper end
 
y
y coordinate of left/upper end
Method Summary
Method Attributes Method Name and Description
<static>  
Slider.create(raphael, slider, params)
Creates new Slider object, for parameters meaning see Slider
 
Get current value from receiver
 
What to do when moving.
 
setVal(newVal)
Set new value to receiver
Class Detail
Slider(raphael, slider, params, lineAttrs)
Slider
Parameters:
{Raphael} raphael
raphael instance
{Raphael.el} slider Optional, Default: SliderCirc
actual slider (must have setX, setX, getY, setY methods)
{Object} params
parameters,see below
{float} params.x Optional, Default: 100.
x coordinate of left-top end
{float} params.y Optional, Default: 100.
y coordinate of left-top end
{float} params.dx Optional, Default: 100.
x dimension of slider [pixels]
{float} params.dy Optional, Default: 0.
y dimension of slider [pixels]
{float} params.val1 Optional, Default: 0.
value when the slider is at the very beginning
{float} params.val2 Optional, Default: 1.
value when the slider is at the very end
{float} params.val3 Optional, Default: val1
extreme beginning value
{float} params.val4 Optional, Default: val2
extreme end value
{float} params.initVal Optional, Default: (val1+val2)/2
initial value
{float} params.gap Optional, Default: 10.
gap between end of the slider's line and the slider's circle when the circle is at extreme position
{Object} lineAttrs Optional, Default: {}
attrs passed to slider's line
Field Detail
{float} dx
x dimension of slider [pixels]

{float} dy
y dimension of slider [pixels]

{float} gap
gap between end of the slider's line and the slider's circle when the circle is at extreme position

{float} initVal
initial value

{float} lenVals
length span of getable values

{Raphael.el} line
line

{Raphael} raphael
raphael instance

{Raphael.el} slider
actual slider (must have setX, setX, getY, setY methods)

{float} val1
value when the slider is at the very beginning

{float} val2
value when the slider is at the very end

{float} val3
extreme beginning value

{float} val4
extreme end value

{float} x
x coordinate of left/upper end

{float} y
y coordinate of left/upper end
Method Detail
<static> {Slider} Slider.create(raphael, slider, params)
Creates new Slider object, for parameters meaning see Slider
Parameters:
raphael
slider
params
Returns:
{Slider} new Slider object

{float} getVal()
Get current value from receiver
Returns:
{float} current value

onmove()
What to do when moving. Initially empty function, overwrite it by desired actions

setVal(newVal)
Set new value to receiver
Parameters:
{float} newVal
new value

Documentation generated by JsDoc Toolkit 2.4.0 on Wed Dec 12 2012 09:22:04 GMT+0100 (CET)