gtk3-0.14.2: Binding to the Gtk+ 3 graphical user interface library

Maintainergtk2hs-users@lists.sourceforge.net
Stabilityprovisional
Portabilityportable (depends on GHC)
Safe HaskellNone
LanguageHaskell98

Graphics.UI.Gtk.MenuComboToolbar.CheckMenuItem

Contents

Description

A menu item with a check box

Synopsis

Detail

A CheckMenuItem is a menu item that maintains the state of a boolean value in addition to a MenuItems usual role in activating application code.

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

Class Hierarchy

| GObject
| +----Object
| +----Widget
| +----Container
| +----Bin
| +----Item
| +----MenuItem
| +----CheckMenuItem
| +----RadioMenuItem

Types

Constructors

checkMenuItemNewWithLabel Source

Arguments

:: GlibString string 
=> string

label - the string to use for the label.

-> IO CheckMenuItem 

Creates a new CheckMenuItem with a label.

checkMenuItemNewWithMnemonic Source

Arguments

:: GlibString string 
=> string

label - The text of the button, with an underscore in front of the mnemonic character

-> IO CheckMenuItem 

Creates a new CheckMenuItem containing a label. The label will be created using labelNewWithMnemonic, so underscores in label indicate the mnemonic for the menu item.

Methods

checkMenuItemSetActive :: CheckMenuItemClass self => self -> Bool -> IO () Source

Sets the active state of the menu item's check box.

checkMenuItemGetActive :: CheckMenuItemClass self => self -> IO Bool Source

Returns whether the check menu item is active. See checkMenuItemSetActive.

checkMenuItemEmitToggled :: CheckMenuItemClass self => self -> IO () Source

Emits the toggled signal.

checkMenuItemSetInconsistent :: CheckMenuItemClass self => self -> Bool -> IO () Source

If the user has selected a range of elements (such as some text or spreadsheet cells) that are affected by a boolean setting, and the current values in that range are inconsistent, you may want to display the check in an "in between" state. This function turns on "in between" display. Normally you would turn off the inconsistent state again if the user explicitly selects a setting. This has to be done manually, checkMenuItemSetInconsistent only affects visual appearance, it doesn't affect the semantics of the widget.

checkMenuItemGetInconsistent :: CheckMenuItemClass self => self -> IO Bool Source

Query if the menu check is drawn as inconsistent (inbetween). See checkMenuItemSetInconsistent.

checkMenuItemGetDrawAsRadio :: CheckMenuItemClass self => self -> IO Bool Source

Returns whether the menu item is drawn like a RadioMenuItem.

  • Available since Gtk+ version 2.4

checkMenuItemSetDrawAsRadio :: CheckMenuItemClass self => self -> Bool -> IO () Source

Sets whether the menu item is drawn like a RadioMenuItem.

  • Available since Gtk+ version 2.4

Attributes

checkMenuItemActive :: CheckMenuItemClass self => Attr self Bool Source

Whether the menu item is checked.

Default value: False

checkMenuItemInconsistent :: CheckMenuItemClass self => Attr self Bool Source

Whether to display an "inconsistent" state.

Default value: False

checkMenuItemDrawAsRadio :: CheckMenuItemClass self => Attr self Bool Source

Whether the menu item looks like a radio menu item.

Default value: False

Signals

checkMenuItemToggled :: CheckMenuItemClass self => Signal self (IO ()) Source

This signal is emitted when the state of the check box is changed.