A comprehensive collection of C# WPF (Windows Presentation Foundation) sample applications demonstrating the customizable layouts, styling, touch-screen interactions, and developer APIs of the MindFusion.Keyboard for WPF control.
Touch-Screen On-Screen Input: MindFusion.Keyboard provides WPF applications with a highly programmable virtual keyboard component. It is designed for touch-screen monitors, medical equipment, industrial kiosks, point-of-sale (POS) systems, and embedded Windows systems where physical keyboards are unavailable.
All sample projects in this repository are pre-configured to reference the official MindFusion.Keyboard.Wpf NuGet package directly rather than referencing local files. This enables automatic package restore and seamless out-of-the-box building under both .NET Framework 4.8 and modern .NET 8.0+.
- Custom Layouts & Keys: Create any keyboard layout with a custom number of keys, labels, special symbols, and custom actions.
- Touch & Kiosk Friendly: Fully optimized for high-performance touch inputs and kiosk interaction styles.
- Color Themes & Styles: Support for 10 built-in color themes, standard styles, fully custom control templates, and image-based key graphics.
- Automatic Focus Popups: Automatically trigger the on-screen keyboard as a popup when input controls (like text boxes) receive focus.
- Standalone Emulation: Use the control as a standalone floating OS keyboard that sends keystrokes to any active external application window on the system.
- Layout Rings: Group multiple layouts together to let users cycle through them sequentially (e.g. switching between languages or numeric modes) with a single key.
This repository includes 8 specialized virtual keyboard sample projects:
- 🩺 MedicalKeyboard — A custom medical-themed keyboard illustrating custom key layout loading and unique styling for special keys using WPF Data Triggers on the
VirtualKeyproperty. - ⚙️ Common API — Shows developer API features, such as sending programmatic key strokes from code, auto-filling keyboard layouts, and automatically releasing modifier keys (Shift, Ctrl, Alt).
- 🔄 Layout Ring — Demonstrates how to configure a layout ring, which allows a specialized
LayoutRingKeyon the keyboard to cycle through a list of custom layouts (showing the next layout's image or text label). - ⌨️ Layouts — Explores the standard, extended, and fully custom layouts. Shows how to define a keyboard with any number of keys and layout structures.
- 🔢 Numpad View — Dynamically switches the layout to render just a clean, compact numeric pad when focus is on numerical-only input fields, reverting to the full keyboard for standard text fields.
- 🎯 Popup Keyboard — Shows how to display the virtual keyboard automatically inside a popup window when the application starts or when specific text areas are focused.
- 🖥️ Standalone Keyboard — Demonstrates utilizing the control as a background standalone OS-level keyboard, sending keystrokes directly to whatever external document or application currently has system focus.
- 🎨 Styles — Showcases the 10 built-in predefined color themes, default styling, advanced custom styling, and a layout where keys are represented entirely by custom images.
- IDE: Visual Studio 2022, 2026 or newer.
- Framework: .NET Framework 4.8 or .NET 8.0+ SDK/Runtime.
- Package Manager: NuGet (integrated natively into Visual Studio).
- Clone the Repository:
git clone https://github.com/MindFusionComponents/wpf-keyboard-samples.git cd wpf-keyboard-samples - Open a Sample:
- Navigate to any sample folder (e.g.,
MedicalKeyboard,NumpadView, orPopupKeyboard). - Double-click the
.slnor.csprojfile to open it in Visual Studio.
- Navigate to any sample folder (e.g.,
- Restore NuGet Packages:
- When you build or debug the project, Visual Studio will automatically restore the missing
MindFusion.Keyboard.Wpfpackage and its dependencies.
- When you build or debug the project, Visual Studio will automatically restore the missing
- Run:
- Press
F5or click Start in Visual Studio to compile and run the sample!
- Press
- These samples are designed to work with MindFusion.Keyboard for WPF.
- For product documentation, licensing, or evaluation licenses, visit the MindFusion Official Website and WPF Virtual Keyboard Product Page.