2 <BODY BGCOLOR="#99ccbb" TEXT="#000000" LINK="#4060b0" VLINK="#000080" ALINK="#ff4040">
4 <STRONG>menu_attributes</STRONG> - color and attribute control for menus
9 <STRONG>#include</STRONG> <STRONG><menu.h></STRONG>
10 int set_menu_fore(MENU *menu, chtype attr);
11 chtype menu_fore(const MENU *menu);
12 int set_menu_back(MENU *menu, chtype attr);
13 chtype menu_back(const MENU *menu);
14 int set_menu_grey(MENU *menu, chtype attr);
15 chtype menu_grey(const MENU *menu);
16 int set_menu_pad(MENU *menu, int pad);
17 int menu_pad(const MENU *menu);
21 <H2>DESCRIPTION</H2><PRE>
22 The function <STRONG>set_menu_fore</STRONG> sets the foreground attribute
23 of <EM>menu</EM>. This is the highlight used for selected menu
24 items. <STRONG>menu_fore</STRONG> returns the foreground attribute. The
25 default is <STRONG>A_STANDOUT</STRONG>.
27 The function <STRONG>set_menu_back</STRONG> sets the background attribute
28 of <EM>menu</EM>. This is the highlight used for selectable (but
29 not currently selected) menu items. The function
30 <STRONG>menu_back</STRONG> returns the background attribute. The default
31 is <STRONG>A_NORMAL</STRONG>.
33 The function <STRONG>set_menu_grey</STRONG> sets the grey attribute of
34 <EM>menu</EM>. This is the highlight used for un-selectable menu
35 items in menus that permit more than one selection. The
36 function <STRONG>menu_grey</STRONG> returns the grey attribute. The
37 default is <STRONG>A_UNDERLINE</STRONG>.
39 The function <STRONG>set_menu_pad</STRONG> sets the character used to fill
40 the space between the name and description parts of a menu
41 item. <STRONG>menu_pad</STRONG> returns the given menu's pad character.
42 The default is a blank.
46 <H2>RETURN VALUE</H2><PRE>
47 These routines return one of the following:
49 <STRONG>E_OK</STRONG> The routine succeeded.
51 <STRONG>E_SYSTEM_ERROR</STRONG>
52 System error occurred (see <STRONG>errno</STRONG>).
54 <STRONG>E_BAD_ARGUMENT</STRONG>
55 Routine detected an incorrect or out-of-range argu-
60 <H2>SEE ALSO</H2><PRE>
61 <STRONG><A HREF="ncurses.3x.html">curses(3X)</A></STRONG> and 3X pages whose names begin "menu_" for
62 detailed descriptions of the entry points.
64 The header file <STRONG><menu.h></STRONG> automatically includes the header
65 file <STRONG><curses.h></STRONG>.
69 <H2>PORTABILITY</H2><PRE>
70 These routines emulate the System V menu library. They
71 were not supported on Version 7 or BSD versions.
76 Juergen Pfeifer. Manual pages and adaptation for new
77 curses by Eric S. Raymond.