To declare the new routines, edit the file $DSTOOL_USER/userlib/user_panels.c. In the declarations section, declare the handler routine and the initialization routine.
extern Menu_item example_handler(); extern int example_init();
In the structure definition section, add a line for the new menu item:
struct User_Def USR_PANELS[] = { {"Example", example_handler, example_init} };
The string ``Example'' is the word which will appear on the Command Window Panels menu. If the example_init() procedure is not needed then that entry may be replaced with NULL. To install multiple custom routines, the structure definition section can contain multiple entries. For example:
struct User_Def USR_PANELS[] = { {"Custom1...", custom1_handler, NULL}, {"Example", example_handler, example_init}, {"Debug...", debug_handler, debug_init} };
These are all the changes which need to be made to the user_panels.c file.