MyWebUniversity.com Home Page
 



Darwin Mac OS X man pages main menu
menuhook(3X)                                                    menuhook(3X)



NAME
       menuhook - set hooks for automatic invocation by applications

SYNOPSIS
       ##include <>
       int setiteminit(MENU *menu, void (*func)(MENU *));
       void (*)(MENU *) iteminit(const MENU *menu);
       int setitemterm(MENU *menu, void (*func)(MENU *));
       void (*)(MENU *) itemterm(const MENU *menu);
       int setmenuinit(MENU *menu, void (*func)(MENU *));
       void (*)(MENU *) menuinit(const MENU *menu);
       int setmenuterm(MENU *menu, void (*func)(MENU *));
       void (*)(MENU *) menuterm(const MENU *menu);

DESCRIPTION
       These  functions make it possible to set hook functions to be called at
       various points in the automatic processing  of  input  event  codes  by
       menudriver.

       The  function  setiteminit sets a hook to be called at menu-post time
       and each time the selected item changes (after the change).   iteminit
       returns  the  current  item init hook, if any (NUL if there is no such
       hook).

       The function setitemterm sets a hook to be called at menu-unpost time
       and each time the selected item changes (before the change).  itemterm
       returns the current item term hook, if any (NUL if there  is  no  such
       hook).

       The  function  setmenuinit sets a hook to be called at menu-post time
       and just after the top row on the  menu  changes  once  it  is  posted.
       menuinit  returns the current menu init hook, if any (NUL if there is
       no such hook).

       The function setmenuterm sets a hook to be called at menu-unpost time
       and  just  before  the  top  row on the menu changes once it is posted.
       menuterm returns the current menu term hook, if any (NUL if there  is
       no such hook).

RETURN VALUE
       Routines  that  return  pointers  return NUL on error.  Other routines
       return one of the following:

       EOK The routine succeeded.

       ESYSTEMEROR
            System error occurred (see errno).

SEE ALSO
       curses(3X), menu(3X).

NOTES
       The  header  file  <>  automatically  includes  the  header  file
       <>.

PORTABILITY
       These  routines  emulate the System V menu library.  They were not sup-
       ported on Version 7 or BSD versions.

AUTHORS
       Juergen Pfeifer.  Manual pages and adaptation for new curses by Eric S.
       Raymond.



                                                                 menuhook(3X)
Darwin Mac OS X man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™