Slider

Slider Module.

API Overview

API Documentation

Functions

matches

Signature

cp.ui.Slider.matches(element) -> boolean

Type

Function

Description

Checks if the provided hs._asm.axuielement is a Slider.

Parameters

Returns

Constructors

new

Signature

cp.ui.Slider.new(parent, finderFn) -> cp.ui.Slider

Type

Constructor

Description

Creates a new Slider

Parameters

Returns

Methods

app

Signature

cp.ui.Slider:app() -> App

Type

Method

Description

Returns the app instance.

Parameters

Returns

decrement

Signature

cp.ui.Slider:decrement() -> self

Type

Method

Description

Decrements the slider by one step.

Parameters

Returns

Signature

cp.ui.Slider:getMaxValue() -> number

Type

Method

Description

Gets the maximum value of the slider.

Parameters

Returns

Signature

cp.ui.Slider:getMinValue() -> number

Type

Method

Description

Gets the minimum value of the slider.

Parameters

Returns

getValue

Signature

cp.ui.Slider:getValue() -> number

Type

Method

Description

Gets the value of the slider.

Parameters

Returns

increment

Signature

cp.ui.Slider:increment() -> self

Type

Method

Description

Increments the slider by one step.

Parameters

Returns

isEnabled

Signature

cp.ui.Slider:isEnabled() -> boolean

Type

Method

Description

Is the slider enabled?

Parameters

Returns

Signature

cp.ui.Slider:loadLayout(layout) -> none

Type

Method

Description

Loads a Slider layout.

Parameters

Returns

parent

Signature

cp.ui.Slider:parent() -> table

Type

Method

Description

The parent object.

Parameters

Returns

Signature

cp.ui.Slider:saveLayout() -> table

Type

Method

Description

Saves the current Slider layout to a table.

Parameters

Returns

setValue

Signature

cp.ui.Slider:setValue(value) -> self

Type

Method

Description

Sets the value of the slider.

Parameters

Returns

Signature

cp.ui.Slider:shiftValue(value) -> self

Type

Method

Description

Shifts the value of the slider.

Parameters

Returns

snapshot

Signature

`cp.ui.Slider:snapshot([path]) -> hs.image

nil` </span>

Type

Method

Description

Takes a snapshot of the UI in its current state as a PNG and returns it.

Parameters