A newer version of Max is available. Click here to access the latest version of this document.

live.menu

Pop-up menu

Description

The live.menu object can be used to display text associated with incoming numbers and provide a general user interface. Item numbering starts from zero (0).

Arguments

None.

Messages

bang Sends the current item out the outlets.
int item-index [int]
An integer specifies a menu item to be displayed, and causes the live.menu object to display that item and output information about its index and the symbol associated with that menu index. Menu item numbering starts at 0.
float item-index [float]
Converted to int.
assign assign-input [float]
The word assign, followed by a floating point value, causes that value to be stored and displayed and sent out the live.menu object's outlet. If the Parameter Visibility attribute is set to Stored Only, the assign message will not add the new value to the Live application’s undo chain.
init Restore and output the initial value.
(mouse) Clicking with the mouse lets you select a menu item to be displayed and outputs information about its index and the symbol associated with that menu index.
outputvalue Sends the current value out the outlet.
set item index [float]
The word set, followed by a number, specifies a menu item to be displayed by the live.menu object without triggering any output.
setsymbol menu item [list]
The word setsymbol, followed by a message, selects a menu item to be displayed by name without triggering any output.
symbol menu item [list]
The word symbol, followed by a message, selects a menu item to be displayed by name. If the item is found, the menu item is displayed and information about its index and the symbol associated with that menu index.
rawfloat input-value [float]
A raw normalized value (between 0. and 1.) received in the inlet is converted to a real value, stored, displayed by the live.menu object, and the current item is sent out the outlets.

Attributes

Name Type g/s Description
active int
def.:1
Toggles the object's active mode. When the active attribute is set to 0, the mouse action does not cause output and the inactive colors are used. The default is 1 (on).
activebgcolor float Sets the background color off displayed when active attribute is set to 1.
bordercolor float Sets the display color for the live.menu object's border in RGBA format.
focusbordercolor float Sets the border color in RGBA format to be used when the live.menu has the focus.
hltcolor float Sets the highlight color in RGBA format to be used when you select an item with the mouse.
pictures symbol Sets the paths of any pictures used when the usepicture attribute is set to 1. Bitmap images such as PNG or vectorized images (SVG) can be used.
textcolor float Sets the display color for the live.menu object's text in RGBA format.
tricolor float Sets the triangle color in RGBA format.
usepicture int
def.:0
Toggles the use of the pictures instead of text display. Note that you need to provide enough pictures by setting the pictures attribute properly.

Information about attributes available for Parameter-aware objects

Information for box attributes common to all objects

Output

anything: Out middle outlet: The text of the selected menu item is sent out as a message.
float: Out right outlet: When an output is triggered, a raw normalized value (between 0. and 1.) is sent out this outlet.
int: Out left outlet: The number of the selected menu item is sent out. Menu items are numbered beginning with 0.

Examples

See Also

Name Description
live.tab A user interface tab/multiple button object
umenu Pop-up menu, to display and send commands