Table of Contents

Class CheckBox

Namespace
Terminal.Gui
Assembly
Terminal.Gui.dll

The CheckBoxView shows an on/off toggle that the user can set

public class CheckBox : View, IDisposable, ISupportInitializeNotification, ISupportInitialize
Inheritance
CheckBox
Implements
Inherited Members

Constructors

CheckBox()

Initializes a new instance of CheckBox based on the given text, using Computed layout.

CheckBox(ustring, bool)

Initializes a new instance of CheckBox based on the given text, using Computed layout.

CheckBox(int, int, ustring)

Initializes a new instance of CheckBox using Absolute layout.

CheckBox(int, int, ustring, bool)

Initializes a new instance of CheckBox using Absolute layout.

Properties

Checked

The state of the CheckBox

Methods

MouseEvent(MouseEvent)

Method invoked when a mouse event is generated

OnEnter(View)

Method invoked when a view gets focus.

OnToggled(bool)

Called when the Checked property changes. Invokes the Toggled event.

PositionCursor()

Positions the cursor in the right position based on the currently focused view in the chain.

ProcessHotKey(KeyEvent)

This method can be overwritten by view that want to provide accelerator functionality (Alt-key for example).

ProcessKey(KeyEvent)

If the view is focused, gives the view a chance to process the keystroke.

UpdateTextFormatterText()

Can be overridden if the Text has different format than the default.

Events

Toggled

Toggled event, raised when the CheckBox is toggled.