1mitem_userptr(3X) mitem_userptr(3X)
2
3
4
6 mitem_userptr - associate application data with a menu item
7
9 #include <menu.h>
10 int set_item_userptr(ITEM *item, void *userptr);
11 void *item_userptr(const ITEM *item);
12
14 Every menu item has a field that can be used to hold application-spe‐
15 cific data (that is, the menu-driver code leaves it alone). These
16 functions get and set that field.
17
19 The function item_userptr returns a pointer (possibly NULL). It does
20 not set errno.
21
22 The set_item_userptr always returns E_OK (success).
23
25 curses(3X), menu(3X).
26
28 The header file <menu.h> automatically includes the header file
29 <curses.h>.
30
32 These routines emulate the System V menu library. They were not sup‐
33 ported on Version 7 or BSD versions.
34
35 The user pointer is a void pointer. We chose not to leave it as a char
36 pointer for SVr4 compatibility.
37
39 Juergen Pfeifer. Manual pages and adaptation for new curses by Eric S.
40 Raymond.
41
42
43
44 mitem_userptr(3X)