We've historically used CefSharp.Wpf + Touch keyboard sample to open the tablet keyboard on a WPF Kiosk that wraps CEF Sharp. Since it is using CefSharp.Wpf - we are facing the relatively common GPU rendering issues on certain devices, as well as disappointment with the performance. Switching to CefSharp.Wpf.HwndHost works to solve our GPU issues, but doesn't reliably trigger the touch keyboard.
How can I trigger the Windows 10 touch keyboard? (OSK / TabTip.exe)
Things that don't work:
disable-usb-keyboard-detectdoes not by itself produce reliable SIP activationCefSharp.Wpf.HwndHostby itself does not produce reliable SIP activation, but does sometimes work and does produce correct SIP type for numeric et al.CefSharp.Wpfdoes not produce any SIP activation (in box), and produces GPU artifacts and performance issues on many machinesCefSharp.Wpf+ Touch keyboard sample does produce reliable SIP activation, but does not control SIP keyboard type (e.g.: numeric pad not shown on<input type="number") and still suffers from GPU and performance issues
You can use the same
IInputPane2interface to trigger the touch keyboard.CefSharp.Wpf.HwndHostrequires use ofIRenderProcessMessageHandlerto receive focus changes, since theVirtualKeyboardRequestedevent is specific toCefSharp.Wpf.Since the
IRenderProcessMessageHandler.OnFocusedNodeChangedevent fires on a fairly high frequency and in cases where no OSK is desired, it is required to filter and debounce the event. It is trivial to do this using Rx.Net. A full example can be found on Github.Project:
net6.0-windows10.0.19041<PackageReference Include="CefSharp.Wpf.HwndHost" Version="98.1.210" /><PackageReference Include="System.Reactive" Version="5.0.0" />Program.cs:
MainWindow.xaml.cs:
Error checking is elided for expository purposes.
General considerations:
BorderStyle