[Contents] [Index] [Help] [Retrace] [Browse <] [Browse >]


    NAME
        SetMenuStrip -- Attach a menu strip to a window.

    SYNOPSIS
        Success = SetMenuStrip( window, menu )
        D0                      A0      A1

        bool setmenustrip( struct window *, struct menu * );

    FUNCTION
        Attaches the menu strip to the window.  After calling this routine,
        if the user presses the menu button, this specified menu strip
        will be displayed and accessible by the user.

        Menus with zero menu items are not allowed.

        NOTE:  You should always design your menu strip changes to be a
        two-way operation, where for every menu strip you add to your
        window you should always plan to clear that strip sometime.  Even
        in the simplest case, where you will have just one menu strip for
        the lifetime of your window, you should always clear the menu strip
        before closing the window.  If you already have a menu strip attached
        to this window, the correct procedure for changing to a new menu
        strip involves calling clearmenustrip() to clear the old first.

        The sequence of events should be:
        - openwindow()
        - zero or more iterations of:
        - SetMenuStrip()
        - clearmenustrip()
        - closewindow()

    INPUTS
        window = pointer to a window structure
        menu = pointer to the first menu in the menu strip

    RESULT
        TRUE if there were no problems.  TRUE always, since this routine
        will wait until it is OK to proceed.

    BUGS

    SEE ALSO
        clearmenustrip(), resetmenustrip()