RadioGroup

Last updated 6 months ago

Represents an AXRadioGroup, providing utility methods.

API Overview

API Documentation

Functions

matches

Signature

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

Type

Function

Description

Checks if the provided axuielement is a RadioGroup.

Parameters

Returns

Fields

Signature

cp.ui.RadioGroup.optionCount <cp.prop: number; read-only>

Type

Field

Description

The number of options in the group.

Signature

cp.ui.RadioGroup.selectedOption <cp.prop: number>

Type

Field

Description

The currently selected option number.

Methods

isEnabled

Signature

cp.ui.RadioGroup:isEnabled()

Type

Method

Description

Checks if the RadioGroup is enabled.

Parameters

Returns

isShowing

Signature

cp.ui.RadioGroup:isShowing() -> boolean

Type

Method

Description

Checks if the RadioGroup is visible.

Parameters

Returns

new

Signature

cp.ui.RadioGroup.new(parent, finderFn[, cached]) -> RadioGroup

Type

Method

Description

Creates a new RadioGroup.

Parameters

Returns

Signature

cp.ui.RadioGroup:nextOption() -> self

Type

Method

Description

Selects the next option in the group. Cycles from the last to the first option.

Parameters

Returns

parent

Signature

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

Type

Method

Description

Returns the parent object.

Parameters

Returns

Signature

cp.ui.RadioGroup:previousOption() -> self

Type

Method

Description

Selects the previous option in the group. Cycles from the first to the last item.

Parameters

Returns

snapshot

Signature

`cp.ui.RadioGroup: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

UI

Signature

cp.ui.RadioGroup:UI() -> axuielement

Type

Method

Description

Returns the axuielement for the RadioGroup, or nil if not currently visible.

Parameters

Returns