AbstractPlayerGui:
Filter:
crucial-library/Classes (extension) | Libraries > crucial > GuiClasses | Libraries > crucial > Players

AbstractPlayerGui
ExtensionExtension

base class for all Player guis

Description

This is the parent class for all gui classes of AbstractPlayer subclasses.

Usually the only method you need to implement in your subclass is guiBody

to the standard ObjectGui it adds these visual elements:

server boot controls play button stop button [ ] free button tempo control save button save as #path - post the path # - post the object as a compile string

Instance Methods

.gui

Arguments:

parent
bounds
... args

.background

Arguments:

b

.topGui

does synthConsole saveConsole does writeName does guiBody then shrinks the window to fit

Arguments:

parent
bounds
... args

.writeName

write the name of the object as a label. the color of the name label is different if the object has a path (was loaded from disk)

Arguments:

layout

.viewDidClose

.keyDownResponder

.saveConsole

standard save controls using SaveConsole. you can override this method in subclasses to customise.

Arguments:

layout

.synthConsole

standard play/record/etc. controls using SynthConsole. you can override this method in subclasses to customise.

Arguments:

layout

.durationString

returns a formatted string representing the minutes:seconds duration of the player

.durationGui

subclasses can call this to add a display of the duration of the player. it will update itself when the player changes and also when the Tempo (global) changes which affects the calculation of the total duration in seconds.

Arguments:

layout

.enableMIDI