Logo FSBarV1_Archived

ConfigPanel Module

Configurator side panel — renders UI and handles input.

Functions and values

Function or value Description

buildPanel config panelState windowWidth windowHeight presetNames activePresetName

Full Usage: buildPanel config panelState windowWidth windowHeight presetNames activePresetName

Parameters:
    config : VizConfig
    panelState : ConfigPanelState
    windowWidth : float32
    windowHeight : float32
    presetNames : string list
    activePresetName : string option

Returns: Element list

Build scene elements for the panel given current config and panel state. Returns empty list when panel is closed.

config : VizConfig
panelState : ConfigPanelState
windowWidth : float32
windowHeight : float32
presetNames : string list
activePresetName : string option
Returns: Element list

handleInput event config panelState windowWidth windowHeight

Full Usage: handleInput event config panelState windowWidth windowHeight

Parameters:
Returns: ConfigPanelInputResult

Handle a mouse/keyboard event within the panel. Returns updated panel state, optional updated VizConfig, and optional host action.

event : InputEvent
config : VizConfig
panelState : ConfigPanelState
windowWidth : float32
windowHeight : float32
Returns: ConfigPanelInputResult

hitTest x y panelState windowWidth

Full Usage: hitTest x y panelState windowWidth

Parameters:
Returns: bool

Test whether a screen-space point falls within the panel bounds.

x : float32
y : float32
panelState : ConfigPanelState
windowWidth : float32
Returns: bool

initialState

Full Usage: initialState

Returns: ConfigPanelState

Creates the initial (closed) panel state.

Returns: ConfigPanelState

panelWidth

Full Usage: panelWidth

Returns: float32

Fixed panel width in pixels.

Returns: float32

toggle panelState

Full Usage: toggle panelState

Parameters:
Returns: ConfigPanelState

Toggle the panel open/closed.

panelState : ConfigPanelState
Returns: ConfigPanelState

Type something to start searching.