Butz:
Filter:
Classes (extension) | Utilities

Butz : Object
ExtensionExtension

Dynamic list of buttons with actions
Source: Butz.sc

Description

Butz has a named list of actions, which it shows on a GUI as buttons. This is useful for opening multiple guis only when needed, such as several instruments and their GUIs, opening utilities like meters, custom scopes, mixers, guis for tests for setup parts (speakers), etc etc.

It shows the actions as buttons with given style, and updates dynamically when items are added.

Butz is a class-only singleton by design choice.

First code examples:

Class Methods

Butz.add(name, action)

add a named action

Arguments:

name

a Symbol

action

a function

Butz.remove(name)

remove an action by name

Arguments:

name

a Symbol

Butz.actions

the NamedList of actions

Butz.run(name)

Arguments:

name

run the action at that name

Butz.show

show the Butz window, making it if necessary

Butz.makeWin

make the window

Butz.numButz

Butz.numButz = value

set and get number of buttons to show

Butz.style

lookup and set style options for the butz window

Butz.w

the butz window

Butz.butz

the list of buttons

Butz.setButton(index)

Arguments:

index

set the button at index to show the name stored at that index

Butz.updateButtons

update the buttons

Inherited class methods

Undocumented class methods

Butz.addMiniMax

Butz.checkFontSize

Butz.clear

Butz.showButs(butsToShow, wait: 0.01)

Instance Methods

Inherited instance methods