---
name: "mitem_opts"
section: "3x"
platform: "macos"
package: "ncurses"
version: "79"
release: "macOS 26.5"
platforms: ["linux", "macos"]
url: "https://new.carta.tech/mitem_opts/3x"
---

# mitem\_opts(3x)

set and get menu item options

## NAME

**mitem\_opts** - set and get menu item options

## SYNOPSIS

**#include \<menu.h\>**\
 int set\_item\_opts(ITEM \*item, Item\_Options opts);\
 int item\_opts\_on(ITEM \*item, Item\_Options opts);\
 int item\_opts\_off(ITEM \*item, Item\_Options opts);\
 Item\_Options item\_opts(const ITEM \*item);\

## DESCRIPTION

The function **set\_item\_opts** sets all the given item's option bits (menu option bits may be logically-OR'ed together).

The function **item\_opts\_on** turns on the given option bits, and leaves others alone.

The function **item\_opts\_off** turns off the given option bits, and leaves others alone.

The function **item\_opts** returns the item's current option bits.

There is only one defined option bit mask, **O\_SELECTABLE**.  When this is on, the item may be selected during menu processing.  This option defaults to on.

## RETURN VALUE

Except for **item\_opts**, each routine returns one of the following:

- **E\_OK**

  The routine succeeded.

- **E\_SYSTEM\_ERROR**

  System error occurred (see **errno**).

## SEE ALSO

**curses**(3X), **menu**(3X).

## NOTES

The header file **\<menu.h\>** automatically includes the header file **\<curses.h\>**.

## PORTABILITY

These routines emulate the System V menu library.  They were not supported on Version 7 or BSD versions.

## AUTHORS

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