Skip to content

charton API


charton API / @chart-on/ui / index / IndicatorSettingsContext

Interface: IndicatorSettingsContext ​

Defined in: ui/src/indicator-settings.ts:248

What IndicatorSettingsOptions.headerControl gets for an indicator's settings panel.

Properties ​

chart ​

readonly chart: Chart

Defined in: ui/src/indicator-settings.ts:249


host ​

readonly host: HTMLElement

Defined in: ui/src/indicator-settings.ts:251

The element the panel opens in, for dialogs of the control's own.


indicator ​

readonly indicator: Indicator

Defined in: ui/src/indicator-settings.ts:252


type ​

readonly type: string

Defined in: ui/src/indicator-settings.ts:254

The indicator's definition id.

Methods ​

setStyle() ​

setStyle(values): boolean

Defined in: ui/src/indicator-settings.ts:263

Fill inputs and plot styles in, applied live like an edit: Ok keeps them, Cancel puts the indicator back. Fields the panel does not show, or would refuse (such as a number out of range or an unknown choice), are left out. Returns whether any field was filled in; false once the panel has closed.

Parameters ​

values ​

FormValues

Returns ​

boolean


style() ​

style(): FormValues

Defined in: ui/src/indicator-settings.ts:256

The inputs and plot styles, by form input id, with the values the panel shows now.

Returns ​

FormValues