ArrangementSelectionState

ArrangementSelectionState

The selection state of the track arrangement area.

To access the ArrangementSelectionState object,

  • use SV.getArrangement().getSelection() in JavaScript
  • use SV:getArrangement():getSelection() in Lua

Extends

Methods

clearAll() → {boolean}

Inherited From:

Unselects all object types supported by this selection state. Return true if the selection has changed.

Returns:
Type
boolean

clearGroups() → {boolean}

Inherited From:

Unselect all NoteGroupReference. Return true if the selection has changed.

Returns:
Type
boolean

getIndexInParent() → {number}

Inherited From:

Get index of the current object in its parent. In Lua, this index starts from 1. In JavaScript, this index starts from 0.

Returns:
Type
number

getParent() → {NestedObject|undefined}

Inherited From:

Get the parent NestedObject. Return undefined if the current object is not attached to a parent.

Returns:
Type
NestedObject | undefined

getSelectedGroups() → {array}

Inherited From:

Get an array of selected NoteGroupReference following the order of selection.

Returns:

an array of NoteGroupReference

Type
array

hasSelectedContent() → {boolean}

Inherited From:

Check if there's anything selected.

Returns:
Type
boolean

hasSelectedGroups() → {boolean}

Inherited From:

Check if there is at least one NoteGroupReference selected.

Returns:
Type
boolean

hasUnfinishedEdits() → {boolean}

Inherited From:

Check if there's any unfinished edit on the selected objects.

For example, this will return true if the user is dragging around a few notes/control points but has not yet released the mouse.

Returns:
Type
boolean

isMemoryManaged() → {boolean}

Inherited From:

Check whether or not the current object is memory managed (i.e. garbage collected by the script environment).

Returns:
Type
boolean

selectGroup(reference)

Inherited From:

Add a NoteGroupReference to the selection.

The argument must be part of the currently open project.

Parameters:
Name Type Description
reference NoteGroupReference

unselectGroup(reference) → {boolean}

Inherited From:

Unselect a NoteGroupReference. Return true if the selection has changed.

Parameters:
Name Type Description
reference NoteGroupReference
Returns:
Type
boolean