[Main]
Name=MenuTopRedef
Type=Function
Subtype=ROM Call
Header Files=menus.h
Definition=void MenuTopRedef (HANDLE ExecHandle, short Item, short ID);
See Also=menus.h/MenuBegin, menus.h/MenuGetTopRedef, menus.h/MenuTopSelect

[ROM Call]
Index=$3F

[Description]
Redefines a toolbox icon.

[Explanation]
MenuTopRedef redefines the icon in the toolbox <I>Item</I> (0 = first, 1 = second,
etc.), which belongs to the menu associated with the handle <I>ExecHandle</I>, to
the icon with index <I>Index</I>, i.e. to the icon associated with the submenu
with the given <I>ID</I>. The menu must have been started using
<A HREF="$$LINK(menus.h/MenuBegin)">MenuBegin</A> with the
<A HREF="$$LINK(menus.h/MenuBeginFlags)">MBF_REDEF</A> flag set.
This is used mainly in the Geometry application which has a toolbar menu with redefinable icons.
<I>ExecHandle</I> is a handle returned from the <A HREF="$$LINK(menus.h/MenuBegin)">MenuBegin</A> function,
not one returned from <A HREF="$$LINK(menus.h/MenuNew)">MenuNew</A>.
<BR><BR>
<B>Note:</B> Such menus cannot be
created using commands like <A HREF="$$LINK(menus.h/MenuNew)">MenuNew</A>, <A HREF="$$LINK(menus.h/MenuAddIcon)">MenuAddIcon</A>,
etc. The only way to make a such menu is to create an appropriate pre-filled static menu
structure, and to pass a pointer to such a structure to <A HREF="$$LINK(menus.h/MenuBegin)">MenuBegin</A>.
See <A HREF="$$LINK(menus.h/MenuPopup)">MenuPopup</A> for more info about menu structures.

[References]
Out=graph.h/CalcBitmapSize, graph.h/DrawChar, graph.h/DrawClipRect, graph.h/DrawFkey, graph.h/DrawLine, graph.h/DrawMultiLines, graph.h/DrawPix, graph.h/DrawStr, graph.h/DrawStrWidth, graph.h/FontSetSys, graph.h/PortRestore, graph.h/RestoreScrState, graph.h/SaveScrState, graph.h/ScrRect, graph.h/ScrRectFill, graph.h/ScrToWin, graph.h/SetCurAttr, graph.h/SetCurClip, mem.h/memset, statline.h/ST_eraseHelp, system.h/CU_cursorState, system.h/CU_restore, system.h/CU_stop, unknown.h/_ROM_CALL_41E, unknown.h/_ROM_CALL_420
