Interface IUISwitch
A component that represents a changeable switch.
Inherited Members
Namespace: DevToys.Api
Assembly: DevToys.Api.dll
Syntax
public interface IUISwitch : IUIElement
Properties
IsOn
Gets the current state of the switch.
Declaration
bool IsOn { get; }
Property Value
Type | Description |
---|---|
bool |
OffText
Gets the text to display when the IsOn is false. Default is "Off".
Declaration
string? OffText { get; }
Property Value
Type | Description |
---|---|
string |
OnText
Gets the text to display when the IsOn is true. Default is "On".
Declaration
string? OnText { get; }
Property Value
Type | Description |
---|---|
string |
Events
IsOnChanged
Raised when IsOn is changed.
Declaration
event EventHandler? IsOnChanged
Event Type
Type | Description |
---|---|
EventHandler |
OffTextChanged
Raised when OffText is changed.
Declaration
event EventHandler? OffTextChanged
Event Type
Type | Description |
---|---|
EventHandler |
OnTextChanged
Raised when OnText is changed.
Declaration
event EventHandler? OnTextChanged
Event Type
Type | Description |
---|---|
EventHandler |