Class RadToggleButtonElement
Represents a toggle button element. The toggle button supports two or three states depending on the IsThreeState property.
The RadToggleButton class is a simple wrapper for the RadToggleButtonElement class. All UI and logic functionality is implemented in the RadToggleButtonElement class. The RadToggleButton acts to transfer events to and from its corresponding RadToggleButtonElement instance. The latter can be nested in other telerik controls.
Inheritance
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.UI.dll
Syntax
public class RadToggleButtonElement : RadButtonElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IComponent, IDisposable, IBindableComponent, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IButtonControl, IImageElement
Constructors
RadToggleButtonElement()
Declaration
public RadToggleButtonElement()
Fields
CheckedRoutedEvent
Indeterminate
ToggleStateChangingRoutedEvent
ToggleStateProperty
Unchecked
Properties
CheckState
Gets or sets the System.Windows.Forms.CheckState. CheckState enumeration defines the following values: Unchecked, Checked, and Indeterminate.
Declaration
public CheckState CheckState { get; set; }
Property Value
System.Windows.Forms.CheckState
|
IsChecked
Gets or sets a value indicating whether the button is checked.
Declaration
public bool IsChecked { get; set; }
Property Value
System.Boolean
|
IsThreeState
Gets or sets a value indicating whether the toggle button has three or two states.
Declaration
public bool IsThreeState { get; set; }
Property Value
System.Boolean
|
ReadOnly
Gets or sets a value indicating whether the toggle button element is read only.
Declaration
public bool ReadOnly { get; set; }
Property Value
System.Boolean
|
ToggleState
Gets or sets the ToggleState. Toggle state enumeration defines the following values: Off, Indeterminate, and On.
Declaration
[RadPropertyDefaultValue("ToggleState", typeof(RadToggleButtonElement))]
public ToggleState ToggleState { get; set; }
Property Value
ToggleState
|
Methods
CreateChildElements()
Declaration
protected override void CreateChildElements()
Overrides
GetXPVisualStyle()
Declaration
public override VisualStyleElement GetXPVisualStyle()
Returns
System.Windows.Forms.VisualStyles.VisualStyleElement
|
Overrides
OnCheckStateChanged(EventArgs)
Raises the StateChanged event.
Declaration
protected virtual void OnCheckStateChanged(EventArgs e)
Parameters
System.EventArgs
e
|
OnCheckStateChanging(CheckStateChangingEventArgs)
Raises the CheckStateChanging event.
Declaration
protected virtual void OnCheckStateChanging(CheckStateChangingEventArgs e)
Parameters
CheckStateChangingEventArgs
e
|
OnClick(EventArgs)
Declaration
protected override void OnClick(EventArgs e)
Parameters
System.EventArgs
e
|
Overrides
OnIsCheckedChanged(EventArgs)
Raises the IsCheckedChanged event.
Declaration
protected virtual void OnIsCheckedChanged(EventArgs e)
Parameters
System.EventArgs
e
|
OnToggle()
Declaration
protected virtual void OnToggle()
OnToggleStateChanged(StateChangedEventArgs)
Raises the StateChanged event.
Declaration
protected virtual void OnToggleStateChanged(StateChangedEventArgs e)
Parameters
StateChangedEventArgs
e
|
OnToggleStateChanging(StateChangingEventArgs)
Raises the StateChanging event.
Declaration
protected virtual void OnToggleStateChanging(StateChangingEventArgs e)
Parameters
StateChangingEventArgs
e
|
SetToggleState(ToggleState)
Events
CheckStateChanged
Occurs when the elements's check state changes.
Declaration
public event EventHandler CheckStateChanged
Event Type
System.EventHandler
|
CheckStateChanging
Occurs before the elements's check state changes.
Declaration
public event CheckStateChangingEventHandler CheckStateChanging
Event Type
CheckStateChangingEventHandler
|
ToggleStateChanged
Occurs when the elements's state changes.
Declaration
public event StateChangedEventHandler ToggleStateChanged
Event Type
StateChangedEventHandler
|
ToggleStateChanging
Occurs before the elements's state changes.
Declaration
public event StateChangingEventHandler ToggleStateChanging
Event Type
StateChangingEventHandler
|