Windows Presentation Foundation (WPF) provides a powerful API with the help of which applications can get input from various devices such as mouse, keyboard, and touch panels. In this chapter, we will discuss the following types of input which can be handled in WPF applications −
|Sr. No.||Inputs & Description|
There are different types of mouse inputs such as MouseDown, MouseEnter, MouseLeave, etc.
There are many types of keyboard inputs such as KeyDown, KeyUp, TextInput, etc.
|3||ContextMenu or RoutedCommands
RoutedCommands enable input handling at a more semantic level. These are actually simple instructions as New, Open, Copy, Cut, and Save.
Windows 7 and its higher versions have the ability to receive input from multiple touchsensitive devices. WPF applications can also handle touch input as other input, such as the mouse or keyboard, by raising events when a touch occurs.