Class HardwareKey
Hardware key: Defines a key stroke for which to be listened
Inherited Members
Namespace: Forms9Patch
Assembly: Forms9Patch.dll
Syntax
public class HardwareKey : BindableObject, INotifyPropertyChanged, IDynamicResourceHandler, IEquatable<HardwareKey>
Constructors
HardwareKey(String, HardwareKeyModifierKeys, String)
Initializes a new instance of the HardwareKey class.
Declaration
public HardwareKey(string keyInput, HardwareKeyModifierKeys modifierKeys = HardwareKeyModifierKeys.None, string discoverableTitle = null)
Parameters
Type | Name | Description |
---|---|---|
String | keyInput | KeyInput. |
HardwareKeyModifierKeys | modifierKeys | Modifier keys. |
String | discoverableTitle | Discoverable title. |
Fields
BackspaceDeleteKeyInput
The backspace delete key HardwareKey.KeyInput.
Declaration
public const string BackspaceDeleteKeyInput = "⌫"
Field Value
Type | Description |
---|---|
String |
ClearKeyInput
The clear key HardwareKey.KeyInput.
Declaration
public const string ClearKeyInput = "⌧"
Field Value
Type | Description |
---|---|
String |
DiscoverableTitleProperty
Backing store for the DiscoverableTitle property
Declaration
public static readonly BindableProperty DiscoverableTitleProperty
Field Value
Type | Description |
---|---|
BindableProperty |
DownArrowKeyInput
Down arrow key HardwareKey.KeyInput
Declaration
public const string DownArrowKeyInput = "↓"
Field Value
Type | Description |
---|---|
String |
EndKeyInput
The end key HardwareKey.KeyInput.
Declaration
public const string EndKeyInput = "⇨"
Field Value
Type | Description |
---|---|
String |
EnterReturnKeyInput
The enter return key HardwareKey.KeyInput.
Declaration
public const string EnterReturnKeyInput = "⏎"
Field Value
Type | Description |
---|---|
String |
EscapeKeyInput
Escape key HardwareKey.KeyInput
Declaration
public const string EscapeKeyInput = "␛"
Field Value
Type | Description |
---|---|
String |
F10KeyInput
The f10 key HardwareKey.KeyInput.
Declaration
public const string F10KeyInput = "⑩"
Field Value
Type | Description |
---|---|
String |
F11KeyInput
The f11 key HardwareKey.KeyInput.
Declaration
public const string F11KeyInput = "⑪"
Field Value
Type | Description |
---|---|
String |
F12KeyInput
The f12 key HardwareKey.KeyInput.
Declaration
public const string F12KeyInput = "⑫"
Field Value
Type | Description |
---|---|
String |
F1KeyInput
The f1 key HardwareKey.KeyInput.
Declaration
public const string F1KeyInput = "①"
Field Value
Type | Description |
---|---|
String |
F2KeyInput
The f2 key HardwareKey.KeyInput.
Declaration
public const string F2KeyInput = "②"
Field Value
Type | Description |
---|---|
String |
F3KeyInput
The f3 key HardwareKey.KeyInput.
Declaration
public const string F3KeyInput = "③"
Field Value
Type | Description |
---|---|
String |
F4KeyInput
The f4 key HardwareKey.KeyInput.
Declaration
public const string F4KeyInput = "④"
Field Value
Type | Description |
---|---|
String |
F5KeyInput
The f5 key HardwareKey.KeyInput.
Declaration
public const string F5KeyInput = "⑤"
Field Value
Type | Description |
---|---|
String |
F6KeyInput
The f6 key HardwareKey.KeyInput.
Declaration
public const string F6KeyInput = "⑥"
Field Value
Type | Description |
---|---|
String |
F7KeyInput
The f7 key HardwareKey.KeyInput.
Declaration
public const string F7KeyInput = "⑦"
Field Value
Type | Description |
---|---|
String |
F8KeyInput
The f8 key HardwareKey.KeyInput.
Declaration
public const string F8KeyInput = "⑧"
Field Value
Type | Description |
---|---|
String |
F9KeyInput
The f9 key HardwareKey.KeyInput.
Declaration
public const string F9KeyInput = "⑨"
Field Value
Type | Description |
---|---|
String |
ForwardDeleteKeyInput
The forward delete key HardwareKey.KeyInput.
Declaration
public const string ForwardDeleteKeyInput = "⌦"
Field Value
Type | Description |
---|---|
String |
HomeKeyInput
The home key HardwareKey.KeyInput.
Declaration
public const string HomeKeyInput = "⇦"
Field Value
Type | Description |
---|---|
String |
InsertKeyInput
The insert key HardwareKey.KeyInput.
Declaration
public const string InsertKeyInput = "⤹"
Field Value
Type | Description |
---|---|
String |
KeyInputProperty
Backing store for the KeyInput property
Declaration
public static readonly BindableProperty KeyInputProperty
Field Value
Type | Description |
---|---|
BindableProperty |
LeftArrowKeyInput
Left arrow key HardwareKey.KeyInput
Declaration
public const string LeftArrowKeyInput = "←"
Field Value
Type | Description |
---|---|
String |
ModifierKeysProperty
Backing store for the ModifierKeys property
Declaration
public static readonly BindableProperty ModifierKeysProperty
Field Value
Type | Description |
---|---|
BindableProperty |
PageDownKeyInput
The page down key HardwareKey.KeyInput.
Declaration
public const string PageDownKeyInput = "⇩"
Field Value
Type | Description |
---|---|
String |
PageUpKeyInput
The page up key HardwareKey.KeyInput.
Declaration
public const string PageUpKeyInput = "⇧"
Field Value
Type | Description |
---|---|
String |
RightArrowKeyInput
Right arrow key HardwareKey.KeyInput
Declaration
public const string RightArrowKeyInput = "→"
Field Value
Type | Description |
---|---|
String |
TabKeyInput
The tab key HardwareKey.KeyInput.
Declaration
public const string TabKeyInput = "⇥"
Field Value
Type | Description |
---|---|
String |
UpArrowKeyInput
Up arrow key HardwareKey.KeyInput
Declaration
public const string UpArrowKeyInput = "↑"
Field Value
Type | Description |
---|---|
String |
Properties
DiscoverableTitle
The text shown, during a modifier key long press, indicating that this key is one that is available with this key press
Declaration
public string DiscoverableTitle { get; set; }
Property Value
Type | Description |
---|---|
String | The discoverable title. |
KeyInput
A case sensitive string representing the key pressed.
Declaration
public string KeyInput { get; set; }
Property Value
Type | Description |
---|---|
String | The input. |
ModifierKeys
Flags representing which (if any) modifier keys occompany the pressed key
Declaration
public HardwareKeyModifierKeys ModifierKeys { get; set; }
Property Value
Type | Description |
---|---|
HardwareKeyModifierKeys | The modifier keys. |
Methods
Equals(HardwareKey)
Determines whether the specified HardwareKey is equal to the current HardwareKey.
Declaration
public bool Equals(HardwareKey other)
Parameters
Type | Name | Description |
---|---|---|
HardwareKey | other | The HardwareKey to compare with the current HardwareKey. |
Returns
Type | Description |
---|---|
Boolean |
|
Equals(Object)
Determines whether the specified Object is equal to the current HardwareKey.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
Object | obj | The Object to compare with the current HardwareKey. |
Returns
Type | Description |
---|---|
Boolean |
|
Overrides
GetHashCode()
Serves as a hash function for a HardwareKey object.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
Int32 | A hash code for this instance that is suitable for use in hashing algorithms and data structures such as a hash table. |
Overrides
ToString()
Returns a String that represents the current HardwareKey.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
String | A String that represents the current HardwareKey. |
Overrides
Operators
Equality(HardwareKey, HardwareKey)
Determines whether a specified instance of HardwareKey is equal to another specified HardwareKey.
Declaration
public static bool operator ==(HardwareKey a, HardwareKey b)
Parameters
Type | Name | Description |
---|---|---|
HardwareKey | a | The first HardwareKey to compare. |
HardwareKey | b | The second HardwareKey to compare. |
Returns
Type | Description |
---|---|
Boolean |
|
Inequality(HardwareKey, HardwareKey)
Determines whether a specified instance of HardwareKey is not equal to another specified HardwareKey.
Declaration
public static bool operator !=(HardwareKey a, HardwareKey b)
Parameters
Type | Name | Description |
---|---|---|
HardwareKey | a | The first HardwareKey to compare. |
HardwareKey | b | The second HardwareKey to compare. |
Returns
Type | Description |
---|---|
Boolean |
|