Skip to main content

noteMouseUp

since 1.2.3

Description​

This event is fired whenever the user releases the mouse after a mouse press on a note. This event is fired whenever a the user presses the mouse button on a note. This event is fired regardless of whether the mouse was released on a note. The parameter is null if the mouse was released somewhere beside the note. It is only fired if CoreSettings.includeNoteBounds was set to true because only then this hit detection can be done. A click on a note is considered if the note head or the note number on tabs are clicked as documented in the boundsLookup.

noteMouseUp: IEventEmitterOfT<Note | null>;

Examples​

const api = new alphaTab.AlphaTabApi(document.querySelector('#alphaTab'));
api.noteMouseUp.on((note) => {
api.playNote(note);
});