Winwheel.js class reference: Pointer Guide
This small class contains properties for the pointer guide which is a line out from the center of the wheel to location where the prize pointer is specified in the code.
The pointer guide can be helpful during development to ensure that visual elements such as the prize pointer are located at the correct angle.
A Winwheel has only one property of the pointerGuide class.
Properties
| Name | Description | Default |
|---|---|---|
| display | By default the guide is not displayed. After wheel creation set Winwheel.pointerGuide.display = true; then call the Winwheel.draw(); function to have the guide rendered | false |
| strokeStyle | Basically the line colour of the pointerGuide. Can be any valid HTML5 stroke style. | red |
| lineWidth | The width of the pointer guide line. | 3 |
Methods
Other than the constructor the pointerGuide class has no methods as the Winwheel class takes care of drawing it on top of the wheel segments.
| Name | Description | Parameters |
|---|---|---|
| constructor | The constructor of the pointer guide class accepts single options parameter. Options wanting to set at time of construction must be specified in JSON format and can be included in the parameters passed to the Winwheel.js constructor. | options [JSON structure] |
| < Animation Class Reference | Helper Functions > |
