gtk.check_menu_item

Module for [CheckMenuItem] class

Types 3

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

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

CSS nodes

menuitem
├── check.left
╰── <child>

GtkCheckMenuItem has a main CSS node with name menuitem, and a subnode with name check, which gets the .left or .right style class.

Methods
GType _getGType() static nothrow
GType _gType() @property nothrow
CheckMenuItem self() nothrowReturns `this`, for use in `with` statements.
CheckMenuItemGidBuilder builder() static nothrowGet builder for [gtk.check_menu_item.CheckMenuItem] Returns: New builder object
bool active() @property nothrow
void active(bool propval) @property nothrow
bool drawAsRadio() @property nothrow
void drawAsRadio(bool propval) @property nothrow
bool inconsistent() @property nothrow
void inconsistent(bool propval) @property nothrow
gtk.check_menu_item.CheckMenuItem newWithLabel(string label) static nothrowCreates a new #GtkCheckMenuItem with a label.
gtk.check_menu_item.CheckMenuItem newWithMnemonic(string label) static nothrowCreates a new #GtkCheckMenuItem containing a label. The label will be created using [gtk.label.Label.newWithMnemonic], so underscores in label indicate the mnemonic for the menu item.
bool getActive() nothrowReturns whether the check menu item is active. See gtk_check_menu_item_set_active (). Returns: true if the menu item is checked.
bool getDrawAsRadio() nothrowReturns whether check_menu_item looks like a #GtkRadioMenuItem Returns: Whether check_menu_item looks like a #GtkRadioMenuItem
bool getInconsistent() nothrowRetrieves the value set by [gtk.check_menu_item.CheckMenuItem.setInconsistent]. Returns: true if inconsistent
void setActive(bool isActive) nothrowSets the active state of the menu item’s check box.
void setDrawAsRadio(bool drawAsRadio) nothrowSets whether check_menu_item is drawn like a #GtkRadioMenuItem
void setInconsistent(bool setting) nothrowIf 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 ...
void toggled() nothrowEmits the #GtkCheckMenuItem::toggled signal.
gulong connectToggled(T)(T callback, Flag!"After" after = No.After) if (isCallable!T && is(ReturnType!T == void) && (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gtk.check_menu_item.CheckMenuItem))) && Parameters!T.length < 2) nothrowConnect to `Toggled` signal.
Constructors
this(void * ptr, Flag!"Take" take)
this()Creates a new #GtkCheckMenuItem. Returns: a new #GtkCheckMenuItem.

Fluent builder implementation template for gtk.check_menu_item.CheckMenuItem

Methods
T active(bool propval) nothrow
T drawAsRadio(bool propval) nothrow
T inconsistent(bool propval) nothrow
Methods
CheckMenuItem build() nothrowCreate object from builder. Returns: New object