new Slider(options)
Slider stimulus.
Parameters:
Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object |
Properties
|
- Mixes In:
- Source:
- To Do:
-
- check that parameters are valid, e.g. ticks are an array of numbers, etc.
- readOnly
- style "slider"
- complete setters, for instance setTicks should change this._isCategorical
Extends
Members
(private) _applyStyle
Apply a particular style to the slider.
- Source:
(private) _buildSlider
Setup the PIXI components of the slider (bar, ticks, labels, marker, etc.).
- Source:
(private) _granularise
Calculate the rating once granularity has been taken into account.
- Source:
(private) _isHorizontal
Determine whether the slider is horizontal.
The slider is horizontal is its x-axis size is larger than its y-axis size.
- Source:
(private) _posToRating
Convert a [x,y] position, in pixel units, relative to the slider, into a rating.
- Source:
(private) _ratingToPos
Convert an array of ratings into an array of [x,y] positions (in Slider units, with 0 at the center of the Slider)
- Source:
(private) _updateIfNeeded
Update the stimulus, if necessary.
- Source:
(private) _updateMarker
Update the position of the marker if necessary.
- Source:
contains
Determine whether an object is inside the bounding box of the slider.
- Source:
- To Do:
-
- this is currently not implemented and always returns false
getRating
Get the current value of the rating.
- Source:
getRT
Get the response time of the most recent change to the rating.
- Source:
recordRating
Set the current rating.
Setting the rating does also change the visible position of the marker.
- Source:
reset
Reset the slider.
- Source:
setBold
Setter for the bold attribute.
- Source:
setItalic
Setter for the italic attribute.
- Source:
setMarkerPos
Setter for the markerPos attribute.
Setting markerPos changes the visible position of the marker to the specified rating but does not change the actual rating returned by the slider.
- Source:
setOpacity
Setter for the opacity attribute.
- Inherited From:
- Source:
setOri
Setter for the orientation attribute.
- Inherited From:
- Source:
setPos
Setter for the position attribute.
- Inherited From:
- Source:
setRating
Setter for the rating attribute.
Setting the rating does not change the visible position of the marker.
- Source:
setReadOnly
Setter for the readOnly attribute.
Read-only sliders are half-opaque and do not provide responses.
- Source:
setSize
Setter for the size attribute.
- Inherited From:
- Source:
(readonly) Shape :Symbol
Shape of the marker and of the ticks.
Type:
- Symbol
- Source:
(readonly) Style :Symbol
Styles.
Type:
- Symbol
- Source: