StaticText

Last updated 8 months ago

Static Text Module.

API Overview

API Documentation

Functions

matches

Signature

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

Type

Function

Description

Checks if the element is a Static Text element.

Parameters

Returns

Methods

app

Signature

cp.ui.StaticText:app() -> table

Type

Method

Description

Returns the app object.

Parameters

Returns

clear

Signature

cp.ui.StaticText:clear() -> self

Type

Method

Description

Clears the value of a Static Text box.

Parameters

Returns

isEnabled

Signature

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

Type

Method

Description

Is the Static Text box enabled?

Parameters

Returns

Signature

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

Type

Method

Description

Loads a Static Text layout.

Parameters

Returns

new

Signature

cp.ui.StaticText.new(parent, finderFn[, convertFn]) -> StaticText

Type

Method

Description

Creates a new StaticText. They have a parent and a finder function.

Parameters

Returns

parent

Signature

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

Type

Method

Description

Returns the parent object.

Parameters

Returns

Signature

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

Type

Method

Description

Saves the current Static Text layout to a table.

Parameters

Returns

snapshot

Signature

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