将Windows 7屏幕键盘集成到WPF应用程序中 [英] Incorporating the Windows 7 onscreen keyboard into a WPF app

查看:110
本文介绍了将Windows 7屏幕键盘集成到WPF应用程序中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Windows 7具有一个非常好的触摸屏屏幕键盘程序/控件.我有一个最初为XP编写的触摸屏应用程序,并将在XP上部署.是否可以将此键盘直接合并到我的应用程序中,而不是使用自定义控件将其合并到我的应用程序中?我找不到关于它的编程信息,因此任何链接都将非常有帮助.具体来说,我需要:

Windows 7 has a really nice onscreen keyboard program/control for touchscreens. I have a touchscreen app that was originally written for, and will be deployed on, XP. Is it possible to incorporate this keyboard directly into my app, rather than me using a custom control? I can find no programmatic information about it, so any links would be very helpful. Specifically, I'd need:

  1. 要能够在已安装.NET 3.5 sp1的XP计算机上使用键盘.
  2. 要能够在Windows 7上隐藏本机键盘,因为我已经将触摸屏键盘集成到了UI中,因此不需要其他人来弄乱UI.

此本机键盘具有两个吸引人的方面.首先,它会自动本地化为客户的语言(尽管应用程序的其余部分需要修改),其次,它似乎并没有遭受触摸滞后"的困扰,因为操作系统试图弄清楚我是否我正在做手势,因为我很清楚地在键盘上打字.

This native keyboard has two attractive aspects to it. First off, it's automatically localized to the customer's language (though the rest of the app will need modification), and second off, it doesn't seem to suffer from 'touch lag' as the OS tries to figure out whether or not I'm doing a gesture, because I'm clearly typing on a keyboard.

该应用程序基于WPF,这意味着可以轻松地与基于Windows 7的控件集成.

The app is WPF based, which should mean easy integration with Windows 7 based controls.

我真的很喜欢XP,但是这不是必需的.不过,在Win7中使用键盘的功能似乎应该是可能的,甚至是正确的使用方式.

I'd really like the XP thing, but it's not a requirement. The ability to use the keyboard in Win7, though, seems like it should be possible and even the right way to do it.

推荐答案

我发现的最好的东西是:

The best thing I've found is this:

它在WPF中使用了互操作性,但效果确实很好.

It's using an interop out of WPF, but seems to work really well.

我希望我是真正编写它的人,但是我所做的只是找到了它.

I wish I was the one who actually wrote it, but all I did was find it...

这篇关于将Windows 7屏幕键盘集成到WPF应用程序中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆