Class
ChordModifier

Represents the state of the modifier keys (SHIFT, CTRL, and ALT) in a Chord.

Definition

Namespace:Telerik.WinControls.Keyboard

Assembly:Telerik.WinControls.dll

Syntax:

cs-api-definition
[TypeConverter(typeof(ChordModifierConverter))]
public class ChordModifier : IComparable, INotifyPropertyChanged

Inheritance: objectChordModifier

Implements: IComparableINotifyPropertyChanged

Constructors

ChordModifier()

Initializes a new instance of the ChordModifier class with default settings.

Declaration

cs-api-definition
public ChordModifier()

ChordModifier(ChordModifier)

Initializes a new instance of the ChordModifier using data provided by another instance.

Declaration

cs-api-definition
public ChordModifier(ChordModifier chordModifier)

Parameters

chordModifier

ChordModifier

ChordModifier(Keys)

Initializes a new instance of the ChordModifier using data provided by Keys input.

Declaration

cs-api-definition
public ChordModifier(Keys pressedKey)

Parameters

pressedKey

Keys

ChordModifier(bool, bool, bool)

Initializes a new instance of the ChordModifier using explicit setting for every property.

Declaration

cs-api-definition
public ChordModifier(bool altModifier, bool controlModifier, bool shiftModifier)

Parameters

altModifier

bool

controlModifier

bool

shiftModifier

bool

Properties

AltModifier

Gets a value indicating if the ALT modifier key is in a pressed state.

Declaration

cs-api-definition
public bool AltModifier { get; set; }

Property Value

bool

ControlModifier

Gets a value indicating if the CTRL modifier key is in a pressed state.

Declaration

cs-api-definition
public bool ControlModifier { get; set; }

Property Value

bool

IsEmpty

Gets a value indicating if any of the modifier keys (SHIFT, CTRL, and ALT) is in a pressed state.

Declaration

cs-api-definition
public bool IsEmpty { get; }

Property Value

bool

ShiftModifier

Gets a value indicating if the SHIFT modifier key is in a pressed state.

Declaration

cs-api-definition
public bool ShiftModifier { get; set; }

Property Value

bool

Methods

Clear()

Removes all data from the ChordModifier.

Declaration

cs-api-definition
public void Clear()

CompareTo(object)

Compares this instance to a specified object or ChordModifier and returns an indication of their relative values.

Declaration

cs-api-definition
public int CompareTo(object obj)

Parameters

obj

object

An object to compare, or a null reference (Nothing in Visual Basic).

Returns

int

A signed number indicating the relative values of this instance and value.

Return Value

Description

Less than zero

This instance is less than value.

Zero

This instance is equal to value.

Greater than zero

This instance is greater than value.

-or-

value is a null reference (Nothing in Visual Basic).

Collapse imageExceptions

Implements IComparable.CompareTo(object)

GetModifiers(ChordModifier, Keys)

Updates a ChordModifier instance based on a Keys input value

Declaration

cs-api-definition
public static ChordModifier GetModifiers(ChordModifier tempModifier, Keys pressedKey)

Parameters

tempModifier

ChordModifier

ChordModifier instance to update

pressedKey

Keys

Keys input value

Returns

ChordModifier

ChordModifier instance with updated states

GetModifiers(Keys)

Creates new ChordModifier instance based on a Keys input value

Declaration

cs-api-definition
public static ChordModifier GetModifiers(Keys pressedKey)

Parameters

pressedKey

Keys

Keys input value

Returns

ChordModifier

ChordModifier instance

OnNotifyPropertyChanged(PropertyChangedEventArgs)

Declaration

cs-api-definition
protected virtual void OnNotifyPropertyChanged(PropertyChangedEventArgs e)

Parameters

e

PropertyChangedEventArgs

OnNotifyPropertyChanged(string)

Raises the PropertyChanged event

Declaration

cs-api-definition
protected virtual void OnNotifyPropertyChanged(string propertyName)

Parameters

propertyName

string

The name of the property

Events

PropertyChanged

Notifies clients that a property value has changed.

Declaration

cs-api-definition
[Browsable(false)]
public event PropertyChangedEventHandler PropertyChanged

Event Value

PropertyChangedEventHandler

Implements INotifyPropertyChanged.PropertyChanged