Keyboard.IHandler

References
public interface Keyboard.IHandler
Handler for platforms to implement the Keyboard functionality.

Properties

Modifiers

#
Keys Modifiers { get; }
Gets the current modifier state for keys such as Keys.Control, Keys.Alt and Keys.Shift.
Remarks: This typically will only return a value for the current event, such as during a mouse or keyboard event.

SupportedLockKeys

#
IEnumerable<Keys> SupportedLockKeys { get; }
Gets an enumeration of all keys supported by the IsKeyLocked(Keys) method.

Methods

IsKeyLocked

#
bool IsKeyLocked(Keys key)
Determines if the specified key is in a locked state, such as the Keys.CapsLock, Keys.ScrollLock, Keys.NumberLock, or Keys.Insert key.
key (Keys)Key to determine the state.
true if the specified key is locked; otherwise, false.

Events

ModifiersChanged

#
event EventHandler<EventArgs> ModifiersChanged
Event to handle when the Modifiers or SupportedLockKeys state has changed
Remarks: Note that this event is long-lived, so if you subscribe to this event to an instance method of a control or short-lived object be sure to unsubscribe it otherwise that object will never be garbage collected.