CtkCheckButton

CtkCheckButton — Create widgets with a discrete toggle button

Functions

Types and Values

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── CtkWidget
            ╰── CtkContainer
                ╰── CtkBin
                    ╰── CtkButton
                        ╰── CtkToggleButton
                            ╰── CtkCheckButton
                                ╰── CtkRadioButton

Implemented Interfaces

CtkCheckButton implements AtkImplementorIface, CtkBuildable, CtkActionable and CtkActivatable.

Includes

#include <ctk/ctk.h>

Description

A CtkCheckButton places a discrete CtkToggleButton next to a widget, (usually a CtkLabel). See the section on CtkToggleButton widgets for more information about toggle/check buttons.

The important signal ( “toggled” ) is also inherited from CtkToggleButton.

CSS nodes

1
2
3
checkbutton
├── check
╰── <child>

A CtkCheckButton with indicator (see ctk_toggle_button_set_mode()) has a main CSS node with name checkbutton and a subnode with name check.

1
2
3
button.check
├── check
╰── <child>

A CtkCheckButton without indicator changes the name of its main node to button and adds a .check style class to it. The subnode is invisible in this case.

Functions

ctk_check_button_new ()

CtkWidget *
ctk_check_button_new (void);

Creates a new CtkCheckButton.

Returns

a CtkWidget.


ctk_check_button_new_with_label ()

CtkWidget *
ctk_check_button_new_with_label (const gchar *label);

Creates a new CtkCheckButton with a CtkLabel to the right of it.

Parameters

label

the text for the check button.

 

Returns

a CtkWidget.


ctk_check_button_new_with_mnemonic ()

CtkWidget *
ctk_check_button_new_with_mnemonic (const gchar *label);

Creates a new CtkCheckButton containing a label. The label will be created using ctk_label_new_with_mnemonic(), so underscores in label indicate the mnemonic for the check button.

Parameters

label

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

 

Returns

a new CtkCheckButton

Types and Values

struct CtkCheckButton

struct CtkCheckButton;

See Also

CtkCheckMenuItem, CtkButton, CtkToggleButton, CtkRadioButton