\Hazaar\View\Widgets
Gauge

Gauge widget class

Tags

Since

1.1

Summary
Methods Properties Constants
cap
max
min
val
No constants
Properties
Inherited
$element
$element
Inherited
$name
$name
Inherited
$script
$script
Methods
__construct()
__construct($name, $params = Array ( ) )

Initialise an Menu widget

Parameters

$namestring

The name (ID) of the widget to create.

$paramsarray

Optional additional parameters

animationDuration()
animationDuration($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets jqxGauge’s animation duration [ms].

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
border()
border($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s border.

Possible Values:

  • ‘size’-specifies the size of the border. Border’s size can be set in percentage or in pixels
  • ‘visible’-indicates if the border will be visible
  • ‘style’-sets border style (color and thickness)
  • ‘showGradient’ – whether a gradient background will be used

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
cap()
cap($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s cap.

Possible Values:

  • ‘size’ – specifies the gauge’s size. This property can be set as percentage or in pixels
  • ‘visible’ – indicates whether the cap will be visible
  • ‘style’ – specifies the gauge’s cap styles. Here you can set it’s fill or stroke colors

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
caption()
caption($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s caption.

Possible Values:

  • ‘value’ – specifies the text
  • ‘position’ – specifies the caption position. There four different positions – top, bottom, left and right. You can customize the position using the offset property described bellow
  • ‘offset’ – array with two number elements. The first one indicates the left offset and the second one the top offset
  • ‘visible’ – indicates whether the caption will be visible

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
colorScheme()
colorScheme($value) : Hazaar\\jqWidgets\\Gauge

Sets the gauge’s color pallete. jqxGauge suppports 11 color schemes from ‘scheme01’ to ‘scheme11’.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
easing()
easing($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets jqxGauge’s animation easing.

Possible easings are: ‘linear’, ‘easeOutBack’, ‘easeInQuad’, ‘easeInOutCirc’, ‘easeInOutSine’, ‘easeOutCubic’.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
endAngle()
endAngle($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets gauge’s endAngle. This property specifies the end of the gauge’s scale and is measured in degrees.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
labels()
labels($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s labels.

Possible Values:

  • ‘distance’ – specifies the labels distance from the gauge’s center. This value could be set in percents (‘0%’ – ’100%’) or using pixels. This property is with lower priority than the position property
  • ‘position’ – specifies the gauge’s labels position. Possible values for this property are ‘inside’, ‘outside’ and ‘none’ (if you want to use the distance property). If it’s value is inside the labels are going to be shown inside the scale otherwise they will be shown outside. This property is with higher priority than the distance property
  • ‘interval’ – specifies labels’s frequency
  • ‘offset’ – specifies labels’s offset. This property is array with two elements. The first one is the left offset and the second one is the top offset
  • ‘style’ – specifies the gauge’s pointer style. Here you can set it’s fill or stroke color
  • ‘formatValue’ – callback used for formatting the label. This function accepts a single parameter which the user can format and return to the labels renderer
  • ‘visible’ – indicates whether the labels will be visible

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
max()
max($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets jqxGauge’s max value.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
min()
min($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets gauge’s minimum value.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
onValueChanged()
onValueChanged($code) : \\Hazaar\\Widgets\\Gauge

The event is is triggered when the gauge’s value is changed.

Tags

Since

1.1

Parameters

$codestring

The JavaScript code to execute when the event is triggered

Returns

\\Hazaar\\Widgets\\Gauge
onValueChanging()
onValueChanging($code) : \\Hazaar\\Widgets\\Gauge

The event is is triggered when the gauge’s value is changing.

Tags

Since

1.1

Parameters

$codestring

The JavaScript code to execute when the event is triggered

Returns

\\Hazaar\\Widgets\\Gauge
pointer()
pointer($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s pointer.

Possible Values:

  • ‘pointerType’ – specifies the pointer type. Possible values for this property are – ‘default’ and ‘rectangle’. If it’s value is ‘default’ the pointer will be arrow otherwise it’ll be rectangle
  • ‘style’ – specifies the gauge’s pointer style. Here you can set it’s fill or stroke color
  • ‘width’ – specifies pointer’s width. This property can be set in percents (‘0%’ – ’100%’) or in pixels
  • ‘length’ – specifies pointer’s length. This property can be set in percents (‘0%’ – ’100%’) or in pixels
  • ‘visible’ – indicates whether the pointer will be visible

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
radius()
radius($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets gauge’s radius. This property accepts size in pixels and percentage.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
ranges()
ranges($value) : \\Hazaar\\Widgets\\Gauge

This property is array of objects. Each object is different range. The range is colored area with specified size.

Possible Values:

  • ‘startValue’-the value from which the range will start
  • ‘endValue’-the value where the current range will end
  • ‘startWidth’-the width of the range in it’s start
  • ‘endWidth’-the end width of the range
  • ‘startDistance [optional]’-this property is measured in pixels or percentage. It indicates the distance from the gauge’s outer boundary to the start of the range
  • ‘endDistance [optional]’-this property is measured in pixels or percentage. It indicates the distance from the gauge’s outer boundary to the end of the range
  • ‘style’-this property is object containing style information for the range. It accepts properties like ‘fill’, ‘stroke’, etc.

Tags

Since

1.1

Parameters

$valuearray

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
showRanges()
showRanges($value) : Hazaar\\jqWidgets\\Gauge

This property indicates whether the gauge’s ranges will be visible.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
startAngle()
startAngle($value) : Hazaar\\jqWidgets\\Gauge

Sets or gets gauge’s startAngle. This property specifies the beggining of the gauge’s scale and is measured in degrees.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
style()
style($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s style.

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
ticksDistance()
ticksDistance($value) : Hazaar\\jqWidgets\\Gauge

Sets and gets the ticks position. This property can be specified using percents (between ’0%’ and ’100%’) or using pixels. If the ticksRadius is ’0%’ this will position the ticks in the outer border of the gauge and if it’s ’100%’ ticks will be positioned near the center.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
ticksMajor()
ticksMajor($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s major ticks.

Possible Values:

  • ‘size’-specifies the length of the tick. This property is measured in pixels or percentage
  • ‘interval’-specifies the ticks frequency. With interval equals to 5 each fifth value of the gauge will have a major tick
  • ‘visible’-indicates if the major ticks will be visible
  • ‘style’-sets ticks style (color and thickness)

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
ticksMinor()
ticksMinor($value) : \\Hazaar\\Widgets\\Gauge

Sets or gets the gauge’s properties for it’s minor ticks.

Possible Values:

  • ‘size’-specifies the length of the tick. This property can be set in pixels or in percentag
  • ‘interval’-specifies the ticks frequency. With interval equals to 5 each fifth value of the gauge will have a minor tick
  • ‘visible’-indicates if the minor ticks will be visible
  • ‘style’-sets ticks style (color and thickness)

Tags

Since

1.1

Parameters

$valueobject

The value to set

Returns

\\Hazaar\\Widgets\\Gauge
value()
value($value = null) : Hazaar\\jqWidgets\\Gauge

Sets or gets gauge’s value.

Parameters

$value

No description

Returns

\Hazaar\View\Widgets\Hazaar\\jqWidgets\\Gauge
Inherited
val()
val($value = null) : string

Sets or gets the value.

Parameters

$valuestring

The value to set

Returns

string
Inherited
width()
width($value) : \Hazaar\View\Widgets\Widget

Specifies the width of the widget in pixels.

Parameters

$valuemixed

The width value. Either an integer or string (with px suffix);

Returns

\Hazaar\View\Widgets\Widget

A reference to the current object.