Programming Guide



sm_menu_create

Defines a menu at runtime

int sm_menu_create(int mem_location, char *script, char *menu);

mem_location
The memory location in which to load this menu, one of the following constants:
MNL_APPLIC
MNL_SCREEN
MNL_FIELD

script
The name of a memory-resident script to contain the menu. The script can be one previously loaded into memory at mem_location by sm_mnscript_load; otherwise, Panther creates a script in memory with the name that you supply.

menu
The name of the menu to create. The menu name must be unique in script.

Returns

Description

sm_menu_create defines a menu and loads it into memory as part of the specified script. After you create this menu, you can set its properties and create items for it through sm_menu_change and sm_mnitem_create, respectively. Like other menus that are loaded into memory, you can attach this menu to an application component—screen or widget—and make it available for display through sm_menu_install.