本文介绍了SurfaceKeyboard与Surface.Core和XNA的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试从SurfaceKeyboard捕获基于XNA的应用程序的输入,但无法确定从哪里开始。  我发现这个
但我没有知道如何直接调用Shell键盘API ..非常感谢教程,示例等的任何链接。

I've been trying to catch input from the SurfaceKeyboard for an XNA based application, but can't really figure out where to start.  I found thisarticle but I don't know how to call the Shell keyboard API directly..  any links to tutorials, examples, etc, would be hugely appreciated.

谢谢

推荐答案

如果您的问题是如何显示键盘,请看一下
SurfaceKeyboard类
。 您可能最感兴趣的是IsVisible,CenterX / CenterY,旋转和布局属性。 我想说,当你希望用户看到键盘时,第一步就是将SurfaceKeyboard.IsVisible设置为true。

If your question is how to display the keyboard, take a look at the SurfaceKeyboard class.  You'll probably be most interested in the IsVisible, CenterX/CenterY, Rotation, and Layout properties.  I'd say that the first step would be to set SurfaceKeyboard.IsVisible to true when you want the user to see the keyboard.

如果你已经尝试过这个并且没有看到键盘,也许问题是Surface Shell没有运行? 键盘由Shell托管,因此您必须运行Shell才能使键盘可见。

If you've tried this and aren't seeing the keyboard, perhaps the problem is that the Surface Shell is not running?  The keyboard is hosted by the Shell, so you have to have Shell running for the keyboard to be visible.


这篇关于SurfaceKeyboard与Surface.Core和XNA的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-27 00:26