[]
        
(Showing Draft Content)

C1.Win.Input.C1ToggleSwitch

C1ToggleSwitch Class

Represents a check editor that uses a movable bar to edit Boolean values.

Namespace: C1.Win.Input
Assembly: C1.Win.Input.8.dll
Syntax
[DefaultBindingProperty("Value")]
[ToolboxBitmap(typeof(C1ToggleSwitch), "C1ToggleSwitch.png")]
public class C1ToggleSwitch : C1InputControl, IDropTarget, ISynchronizeInvoke, IWin32Window, IBindableComponent, IComponent, IDisposable, IView, ISupportUia, ISupportInitialize, IUiaToggleButton, IUiaToggleProvider

Constructors

Name Description
C1ToggleSwitch()

Initializes a new instance of the C1ToggleSwitch class.

Properties

Name Description
BarWidth

Gets or sets the width of the switch bar.

DefaultSize
LabelDisplayMode

Gets or sets the display mode to represent the states of the control.

LabelPosition

Gets or sets the position of the text or icons used to display the status of the control.

OffIcon

Gets or sets the icon displayed when the state is Off.

OffText

Gets or sets the text displayed when the state is Off.

OnIcon

Gets or sets the icon displayed when the state is On.

OnText

Gets or sets the text displayed when the state is On.

Styles

Gets or sets the C1ToggleSwitch styles.

Text

This property is not supported by the C1ToggleSwitch class. Use OnText and OffText properties.

ThumbWidth

Gets or sets the width of thumb.

Value

Gets or sets a value of the C1ToggleSwitch control.

Methods

Name Description
ApplyStyle()

Applies the style to control view.

CreateUiaItem(UiaItem)

Creates UI Automation object of this control.

Dispose(bool)

Releases the unmanaged resources used by the C1InputControl control.

OnClick(EventArgs)

Raises the Click event.

OnGotFocus(EventArgs)

Raises the GotFocus event.

OnKeyDown(KeyEventArgs)

Raises the KeyDown event.

OnKeyUp(KeyEventArgs)

Raises the KeyUp event.

OnMouseUp(MouseEventArgs)

Raises the MouseUp event.

OnToggled(EventArgs)

Raises the Toggled event.

Toggle()

Inverts the state of the ToggleSwitch control.

Events

Name Description
Toggled

Occurs when the control's state is changed.