Class KeyGestureExt
KeyGestureExt class is an extension of KeyGesture class. This class contains implementation for supporting multiple key gestures additionally.
Inheritance
Namespace: Syncfusion.Windows.Edit
Assembly: Syncfusion.Edit.Wpf.dll
Syntax
public class KeyGestureExt : KeyGesture
Constructors
KeyGestureExt(List<Key>, ModifierKeys)
Initializes a new instance of the KeyGestureExt class.
Declaration
public KeyGestureExt(List<Key> keys, ModifierKeys modifiers)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.List<System.Windows.Input.Key> | keys | Specifies the collection of Keys for multiple Key KeyGesture. Keys should be given in the order they have to be matched. |
System.Windows.Input.ModifierKeys | modifiers | Specifies the Modifier key. |
KeyGestureExt(Key)
Initializes a new instance of the KeyGestureExt class.
Declaration
public KeyGestureExt(Key key)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Input.Key | key | specifies the key in a KeyGesture |
KeyGestureExt(Key, ModifierKeys)
Initializes a new instance of the KeyGestureExt class.
Declaration
public KeyGestureExt(Key key, ModifierKeys modfiers)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Input.Key | key | Specifies the key in a KeyGesture |
System.Windows.Input.ModifierKeys | modfiers | Specifies the modifier key |
Properties
KeyCollection
Gets or sets the Keys collection for key gesture.
Declaration
public List<Key> KeyCollection { get; set; }
Property Value
Type |
---|
System.Collections.Generic.List<System.Windows.Input.Key> |
Remarks
Keys should be given in the order in which they have to be matched.
Methods
Matches(Object, InputEventArgs)
Overridden method of KeyGesture class used to match the KeyGestures.
Declaration
public override bool Matches(object targetElement, InputEventArgs inputEventArgs)
Parameters
Type | Name | Description |
---|---|---|
System.Object | targetElement | Specifies the element on which the KeyGesture is set. |
System.Windows.Input.InputEventArgs | inputEventArgs | Specifies the KeyEventArgs containing information related to the key pressed and modifiers. |
Returns
Type | Description |
---|---|
System.Boolean | returns true if the key gestures match else returns false. |