14

We started creating a WPF touch application in Windows 8 and recently migrated to Windows 10. One feature we implemented is opening the Windows Keyboard when a TextBox receives focus. In Windows 8, it was possible to dock the keyboard to the bottom by setting the registry setting EdgeTargetDockedState and starting the TabTip process:

     string path =  @"C:\Program Files\Common Files\Microsoft Shared\ink\TabTip.exe";
     var info = new ProcessStartInfo(path);
     info.WindowStyle = ProcessWindowStyle.Maximized;
     var p = new Process();
     p.StartInfo = info;
     p.Start();

The Windows 10 keyboard however doesn't seem to have the same dock behavior as in Windows 8. The keyboard now overlays any maximized window which hides the bottom part of any application. Only not-maximized windows are resized to fit the remaining space.

I've checked the following links, but found no solution:

Can the Windows 10 keyboard be docked programmatically for a maximized window?

Community
  • 1
  • 1
Bruno V
  • 1,721
  • 1
  • 14
  • 32
  • Have you found a solution? – nicruo Feb 24 '16 at 10:34
  • As far as I know, the keyboard in Windows 10 cannot be docked when the window is maximized. I have asked in the Microsoft link where this feature can be officially requested, but have not received a satisfactory answer. If this won't be implemented, I guess I'll have to look at 'almost maximizing' the window and then opening the keyboard (which seems like a very ugly solution). – Bruno V Feb 25 '16 at 08:57

2 Answers2

4

I open-sourced my project to automate everything concerning TabTip integration in WPF app.

You can get it on nuget, and after that all you need is a simple config in your apps startup logic:

TabTipAutomation.BindTo<TextBox>();

You can bind TabTip automation logic to any UIElement. Virtual Keyboard will open when any such element will get focus, and it will close when element will lose focus. Not only that, but TabTipAutomation will move UIElement (or Window) into view, so that TabTip will not block focused element.

For more info refer to the project site.

To clarify: If you will be using this package TabTip will not be docked, but your UI will be in view, which i guess is what you wanted to achieve.

Max
  • 310
  • 3
  • 7
  • Thanks @Макс Федотов, I didn't end up using your project but I picked and pulled out the pieces that I needed and this helped me get past the issue I was facing. – BigHeadCreations Nov 03 '16 at 09:32
  • This is unprofessional code: private const string TabTipExecPath = @"C:\Program Files\Common Files\microsoft shared\ink\TabTip.exe"; private const string TabTipRegistryKeyName = @"HKEY_CURRENT_USER\Software\Microsoft\TabletTip\1.7"; Hardcoded values is a bad practice and can be incompatible with ANY windows updates. – Vincent Jan 30 '20 at 10:14
1

Check this article: http://www.codeproject.com/Tips/1120263/Virtual-Keyboard-TabTip-integration-in-WPF-on-Win

Virtual Keyboard will open when any such element will get focus, and it will close when element will lose focus.

tadej
  • 701
  • 1
  • 5
  • 22
  • 4
    While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. – Roman Marusyk Aug 24 '16 at 10:45