## org.gnu.gtk
Class CheckMenuItem

    java.lang.Object
      org.gnu.glib.Struct
          org.gnu.glib.GObject
              org.gnu.gtk.GtkObject
                  org.gnu.gtk.Widget
                      org.gnu.gtk.Container
                          org.gnu.gtk.Bin
                              org.gnu.gtk.Item
                                  org.gnu.gtk.MenuItem
                                      org.gnu.gtk.CheckMenuItem

Direct Known Subclasses:
  RadioMenuItem

public class CheckMenuItem
extends MenuItem

The CheckMenuItem is a menu item that maintains the state of a boolean value in addition to the MenuItem's usual role of activating applicaiton code.

A check box indicating the state of boolean value is displayed on the left side of the MenuItem. Activating the MenuItem toggles this value.

Constructor Summary
`CheckMenuItem()` Create a new CheckMenuItem
`CheckMenuItem(org.gnu.glib.Handle handle)` Construct a CheckMenuItem using a handle to a native resource.
`CheckMenuItem(java.lang.String label, boolean hasMnemonic)` Create a new CheckMenuItem with the given label.

Method Summary
`void` `addListener(CheckMenuItemListener listener)` Register an object to handle dialog events.
`boolean` `getActive()` Returns whether the CheckMenuItem is active.
`static CheckMenuItem` `getCheckMenuItem(org.gnu.glib.Handle handle)` Internal static factory method to be used by Java-Gnome only.
`boolean` `getDrawAsRadio()` Gets whether the CheckMenuItem will be drawn as a radio control.
`java.lang.Class` `getEventListenerClass(java.lang.String signal)`
`EventType` `getEventType(java.lang.String signal)`
`boolean` `getInconsistent()` Returns whether the CheckMenuItem is in the "inconsistent" state.
`static Type` `getType()` Retrieve the runtime type used by the GLib library.
`void` `removeListener(CheckMenuItemListener listener)` Removes a listener
`void` `setActive(boolean isActive)` Sets the active state of the CheckMenuItem's check box.
`void` `setDrawAsRadio(boolean drawAsRadio)` Sets whether the CheckMenuItem should be drawn as a radio control
`void` `setInconsistent(boolean isInconsistent)` This method will turn on a third state that indicates that the widget is in an inconsistent state.

Methods inherited from class org.gnu.gtk.MenuItem
`addListener, emitActivate, emitDeselect, getMenuItem, removeListener, removeSubmenu, setLeftJustified, setRightJustified, setSubmenu`

Methods inherited from class org.gnu.gtk.Item
`addListener, deselect, removeListener, select, toggle`

Methods inherited from class org.gnu.gtk.Bin
`getChild`

Methods inherited from class org.gnu.gtk.Container
`add, addListener, getBorderWidth, getChildren, getResizeMode, remove, removeListener, resizeChildren, setBorderWidth, setResizeMode`

Methods inherited from class org.gnu.gtk.Widget

`activate, addAccelerator, addEvents, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, canActivateAccel, createContext, createLayout, draw, drawArea, drawArea, finish, getAccessible, getColormap, getContext, getData, getDisplay, getDragData, getExtensionEvents, getModifierStyle, getName, getParent, getParentWindow, getPointer, getRootWindow, getScreen, getSensitive, getStyle, getToplevel, getWidget, getWindow, grabDefault, grabFocus, hasFocus, hasScreen, hide, hideAll, highlight, highlight, intersect, isAncestor, makeWidget, modifyStyle, popColormap, pushColormap, realize, removeAccelerator, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, reparent, setBackgroundColor, setBaseColor, setColormap, setDoubleBuffered, setDragDestination, setDragIcon, setDragIconPixbuf, setDragIconStock, setDragSource, setEvents, setExtensionEvents, setFont, setForegroundColor, setMinimumSize, setName, setNoDragDestination, setNoDragSource, setSensitive, setTextColor, shapeCombineMask, show, showAll, unHighlight, unHighlight`

Methods inherited from class org.gnu.gtk.GtkObject
`destroy, sink`

Methods inherited from class org.gnu.glib.GObject

`addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addListener, collect, freezeNotify, getBooleanProperty, getData, getDoubleProperty, getFloatProperty, getGObjectFromHandle, getIntProperty, getJavaObjectProperty, getLongProperty, getPixbufProperty, getProperty, getStringProperty, hasProperty, notify, removeEventHandler, removeListener, setBooleanProperty, setData, setDoubleProperty, setFloatProperty, setIntProperty, setJavaObjectProperty, setLongProperty, setPixbufProperty, setProperty, setStringProperty, thawNotify`

Methods inherited from class org.gnu.glib.Struct
`equals, getHandle, getNullHandle, hashCode`

Methods inherited from class java.lang.Object
`getClass, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### CheckMenuItem

    public CheckMenuItem()

  Create a new CheckMenuItem

### CheckMenuItem

    public CheckMenuItem(org.gnu.glib.Handle handle)

  Construct a CheckMenuItem using a handle to a native resource.

### CheckMenuItem

    public CheckMenuItem(java.lang.String label,
                         boolean hasMnemonic)

  Create a new CheckMenuItem with the given label.

Parameters:
  `label` - The label to display for this CheckMenuItem.

Method Detail

### getCheckMenuItem

    public static CheckMenuItem getCheckMenuItem(org.gnu.glib.Handle handle)

  Internal static factory method to be used by Java-Gnome only.

### setActive

    public void setActive(boolean isActive)

  Sets the active state of the CheckMenuItem's check box.

  Parameters:
    `isActive` - true if the check box is checked.

### getActive

    public boolean getActive()

  Returns whether the CheckMenuItem is active.

  Returns:
    true if the check box is active.

### setInconsistent

    public void setInconsistent(boolean isInconsistent)

  This method will turn on a third state that indicates that the widget is in an inconsistent state.

  Parameters:
    `isInconsistent` - true to display an "inconsistent" third state.

### getInconsistent

    public boolean getInconsistent()

  Returns whether the CheckMenuItem is in the "inconsistent" state.

  Returns:
    true if the check box is inconsistent.

### setDrawAsRadio

    public void setDrawAsRadio(boolean drawAsRadio)

  Sets whether the CheckMenuItem should be drawn as a radio control

  Parameters:
    `drawAsRadio` -

### getDrawAsRadio

    public boolean getDrawAsRadio()

  Gets whether the CheckMenuItem will be drawn as a radio control.

### getType

    public static Type getType()

  Retrieve the runtime type used by the GLib library.

### addListener

    public void addListener(CheckMenuItemListener listener)

  Register an object to handle dialog events.

  See Also:
    `CheckMenuItemListener`

### removeListener

    public void removeListener(CheckMenuItemListener listener)

  Removes a listener

  See Also:
    `addListener(CheckMenuItemListener)`

### getEventListenerClass

    public java.lang.Class getEventListenerClass(java.lang.String signal)

  Overrides:
    `getEventListenerClass` in class `MenuItem`

### getEventType

    public EventType getEventType(java.lang.String signal)

  Overrides:
    `getEventType` in class `MenuItem`